Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Fix cron script issues related to docker version upgrade on new servers #1490

Merged
merged 3 commits into from
May 30, 2024

Conversation

dchiller
Copy link
Contributor

@dchiller dchiller commented May 30, 2024

As noted in this Docker documentation, when Docker compose specifications migrated from V1 to V2, the word separator in the default container name changed from an underscore to a hyphen. Our new servers, with their upgraded version of Docker, use the hyphen. Since the documentation suggests an underlying networking reason for this change, this PR implements it.

The relevant container name in the db_backup.sh script is changed (cantusdb_postgres_1 to cantusdb-postgres-1).

This PR also updates all docker-compose files in this repo to specify the container name (although our scripts now conform to this naming convention, it doesn't hurt to make it explicit).

The docker-compose command was also deprecated with the version of Docker server used on the new servers. This PR adjusts the manage.sh cron script to use docker compose rather than docker-compose.

Closes #1489.

A companion PR in the ansible set-up (https://github.com/dact-chant/ansible.cantus-db/pull/39) makes the analogous change in the docker-compose.yml template.

@dchiller dchiller changed the title Fix container names in DB backup cron job Fix cron script issues related to docker version upgrade on new servers May 30, 2024
@dchiller dchiller marked this pull request as ready for review May 30, 2024 12:16
@dchiller dchiller requested a review from lucasmarchd01 May 30, 2024 12:16
@dchiller dchiller merged commit e0b5a97 into DDMAL:develop May 30, 2024
@dchiller dchiller deleted the i1489-fix-backup-cron branch May 30, 2024 14:07
@dchiller dchiller mentioned this pull request Jun 4, 2024
27 tasks
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

DB backup cron job fails
2 participants