docker image in deploy step

This commit is contained in:
2024-12-28 12:39:14 +09:00
parent 5f2da4bbba
commit ab9d401d68

View File

@@ -13,9 +13,11 @@ steps:
# Шаг 2: Обновление и запуск с помощью update.sh # Шаг 2: Обновление и запуск с помощью update.sh
- name: deploy_app - name: deploy_app
image: python:3.12 image: docker:24
environment: environment:
MYSQL_PASSWORD: touchh MYSQL_PASSWORD: touchh
volumes:
- /var/run/docker.sock:/var/run/docker.sock
commands: commands:
- chmod +x ./bin/update - chmod +x ./bin/update
- git branch --set-upstream-to=origin/PMSManager_refactor PMSManager_refactor || true - git branch --set-upstream-to=origin/PMSManager_refactor PMSManager_refactor || true
@@ -23,9 +25,11 @@ steps:
# Шаг 3: Миграция базы данных # Шаг 3: Миграция базы данных
- name: run_migrations - name: run_migrations
image: python:3.12 image: docker:24
environment: environment:
MYSQL_PASSWORD: touchh MYSQL_PASSWORD: touchh
volumes:
- /var/run/docker.sock:/var/run/docker.sock
commands: commands:
- chmod +x ./bin/cli - chmod +x ./bin/cli
- ./bin/cli migrate - ./bin/cli migrate
@@ -36,7 +40,7 @@ steps:
environment: environment:
MYSQL_PASSWORD: touchh MYSQL_PASSWORD: touchh
commands: commands:
- apk add --no-cache mariadb-client - apk add --no-cache mariadb-client mariadb-connector-c-dev gcc musl-dev pkgconfig
- pip install -r requirements.txt - pip install -r requirements.txt
- python manage.py test - python manage.py test