Refactor service deployment + upload Compose files to the server #178
No reviewers
Labels
No labels
Blocked
Existing Service
Infrastructure Issue
Refactor
Security Hardening
Security Issue
Service Idea
Service Removal
Upgrade service
No milestone
No project
No assignees
4 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: data.coop/ansible#178
Loading…
Reference in a new issue
No description provided.
Delete branch "compose-files"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
As discussed with @valberg, we should upload the Compose files to the server in order to make things like upgrading services easier. To make this possible, and make things consistent, I've also converted single container services into compose stacks.
I have further refactored the service deployment logic to eliminate code duplication as much as possible, as many services follow the same pattern (create volume folder, upload Compose file, deploy service). Some services have additional tasks that can be included as pre-deployment tasks or post-deployment tasks with a file.
Closes #80.
Move Compose stacks into Compose files and upload them to the serverto WIP: Move Compose stacks into Compose files and upload them to the serverThe
docker-compose
module in ansible uses docker compose v1. We should use theshell
module to run the docker compose plugin (v2) using something like this https://stackoverflow.com/a/62453786WIP: Move Compose stacks into Compose files and upload them to the serverto Move Compose stacks into Compose files and upload them to the serverMove Compose stacks into Compose files and upload them to the serverto WIP: Move Compose stacks into Compose files and upload them to the serverWIP: Move Compose stacks into Compose files and upload them to the serverto Refactor service deployment + upload Compose files to the serverI have tested this in Vagrant. I have tested a full provisioning, and then I have tested deployment of a single service, with and without pre-/post-deployment tasks.
All tests finished with success.
Nice work @samsapti (as always!)
NICE! 🚀
@ -140,3 +134,3 @@
vhs_website:
file: websites/vhs.data.coop.yaml
domain: vhs.data.coop
volume_folder: "{{ volume_website_folder }}/vhs"
hvad bruges det her til?
Til
docker-compose.yml
🙂