Update apps for docker compose plugin

This commit is contained in:
2024-12-21 14:39:13 +03:00
parent 22e09afd00
commit 98a1087e84
6 changed files with 7 additions and 49 deletions

View File

@@ -3,7 +3,7 @@ import shlex
import fabric
from invoke import task
SERVER_HOST_FILE = "ansible/hosts_prod"
SERVER_HOST_FILE = "hosts_prod"
DOKER_REGISTRY = "cr.yandex/crplfk0168i4o8kd7ade"
@@ -12,11 +12,6 @@ def deploy_gitea(context):
deploy("gitea", dirs=["data"])
@task(name="deploy:wiki")
def deploy_wiki(context):
deploy("wiki")
@task(name="deploy:keycloak")
def deploy_keykloak(context):
deploy("keycloak", compose_file="docker-compose.prod.yml", dirs=["data"])
@@ -56,7 +51,7 @@ def deploy(app_name: str, compose_file="docker-compose.yml", dirs=None):
c.run(f"mkdir -p {d}")
print("Up services")
c.run(
f"docker-compose --project-name {shlex.quote(app_name)} --env-file=.env.prod up --detach --remove-orphans"
f"docker compose --project-name {shlex.quote(app_name)} --env-file=.env.prod up --detach --remove-orphans"
)
c.run(
f"docker system prune --all --volumes --force"