chore: temporarily override deploy.yml to rebuild 1.0.0 image without latest tag
Deploy Telegram Bot / build-and-push (push) Successful in 22s
Deploy Telegram Bot / build-and-push (push) Successful in 22s
This commit is contained in:
@@ -3,7 +3,7 @@ name: Deploy Telegram Bot
|
|||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches:
|
branches:
|
||||||
- main
|
- fix-1.0.0-image
|
||||||
|
|
||||||
env:
|
env:
|
||||||
VERSION: 1.0.0
|
VERSION: 1.0.0
|
||||||
@@ -30,7 +30,6 @@ jobs:
|
|||||||
file: src/GmRelay.Bot/Dockerfile
|
file: src/GmRelay.Bot/Dockerfile
|
||||||
push: true
|
push: true
|
||||||
tags: |
|
tags: |
|
||||||
git.codeanddice.ru/toutsu/gmrelay-bot:latest
|
|
||||||
git.codeanddice.ru/toutsu/gmrelay-bot:${{ env.VERSION }}
|
git.codeanddice.ru/toutsu/gmrelay-bot:${{ env.VERSION }}
|
||||||
labels: |
|
labels: |
|
||||||
org.opencontainers.image.source=https://git.codeanddice.ru/${{ gitea.repository }}
|
org.opencontainers.image.source=https://git.codeanddice.ru/${{ gitea.repository }}
|
||||||
@@ -42,32 +41,7 @@ jobs:
|
|||||||
file: src/GmRelay.Web/Dockerfile
|
file: src/GmRelay.Web/Dockerfile
|
||||||
push: true
|
push: true
|
||||||
tags: |
|
tags: |
|
||||||
git.codeanddice.ru/toutsu/gmrelay-web:latest
|
|
||||||
git.codeanddice.ru/toutsu/gmrelay-web:${{ env.VERSION }}
|
git.codeanddice.ru/toutsu/gmrelay-web:${{ env.VERSION }}
|
||||||
labels: |
|
labels: |
|
||||||
org.opencontainers.image.source=https://git.codeanddice.ru/${{ gitea.repository }}
|
org.opencontainers.image.source=https://git.codeanddice.ru/${{ gitea.repository }}
|
||||||
|
|
||||||
# ЧАСТЬ 2: Запускаем эти образы на самом сервере
|
|
||||||
deploy:
|
|
||||||
needs: build-and-push
|
|
||||||
runs-on: ubuntu-latest # Тот же локальный раннер
|
|
||||||
steps:
|
|
||||||
- name: Checkout repository
|
|
||||||
uses: actions/checkout@v4
|
|
||||||
|
|
||||||
- name: Create .env file with secrets
|
|
||||||
run: |
|
|
||||||
echo "TELEGRAM_BOT_TOKEN=${{ secrets.TELEGRAM_BOT_TOKEN }}" > .env
|
|
||||||
echo "POSTGRES_PASSWORD=${{ secrets.POSTGRES_PASSWORD }}" >> .env
|
|
||||||
echo "TELEGRAM_BOT_USERNAME=${{ secrets.TELEGRAM_BOT_USERNAME }}" >> .env
|
|
||||||
|
|
||||||
- name: Deploy Containers
|
|
||||||
run: |
|
|
||||||
# Авторизуемся локальным докером в нашей Gitea
|
|
||||||
docker login git.codeanddice.ru/ -u toutsu -p ${{ secrets.GIT_TOKEN }}
|
|
||||||
|
|
||||||
# Pull гарантирует, что мы получили нужную версию.
|
|
||||||
docker compose pull bot web
|
|
||||||
|
|
||||||
# Запускаем! Флаг -d оставит их работать в фоне.
|
|
||||||
docker compose up -d
|
|
||||||
Reference in New Issue
Block a user