MobMin / digital_atlas

A detailed overview of the digital and spiritual landscape for the countries of the world.
GNU General Public License v3.0
17 stars 5 forks source link

06-10-2024: Update Docker Compose from V1 to V2 #36

Closed michael-lins closed 6 days ago

michael-lins commented 1 month ago

Description

The Docker Compose was initially installed separated from the Docker cli itself, but since 2023 it was incorporated into Docker installation being present in Docker Desktop installations. Therefore, docker-compose should be replaced with docker compose and other minor changes could be checked and applied as needed.

Context

I got an error while setting up my Docker environment for the project, just noticed that the command called for the composer was using hyphen, so it was a matter of updating the docker/setup.sh file with proper command and it all ran smoothly.

Process

In order to reproduce the issue one should:

  1. Fork the repo
  2. Clone it locally
  3. Created the desired branch
  4. Make the docker/setup.sh file executable
  5. Execute the docker/setup.sh file
  6. See a command not found for docker-compose but also a successful message printed by the script.

Expected result

Project setup using docker and documentation updated regarding Docker Compose V2.

Current result

The docker/setup.sh presents a successful message but nothing is done by the script due to a docker-compose command not being found.

Possible Fix

A simple fix for the setup to work is to update the setup.sh replacing the hyphen for a space on the docker compose command. But all documentation should be checked afterwards.

For a permanent fix:

  1. Check Docker Compose website for reference (https://docs.docker.com/compose/migrate/)
  2. Check code for changes (./docker/setup.sh and maybe other files)
  3. Apply changes as required to comply with V2 version
  4. Update documentation accordingly
michael-lins commented 6 days ago

Closing this issue as Won't Fix. After checking other tasks I understood that this issue does not make sense as we are planning on migrating from docker to Laravel Sail.