Skip to content

remove redundant field in ChildrenGroupSerializer #1

remove redundant field in ChildrenGroupSerializer

remove redundant field in ChildrenGroupSerializer #1

Workflow file for this run

name: Lesya and Moa Deploy
on:
push:
branches:
- main
jobs:
build_bot_and_push_to_docker_hub:
name: Push bot Docker image to DockerHub
runs-on: ubuntu-latest
steps:
- name: Check out the repo
uses: actions/checkout@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Login to Docker
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Push to DockerHub
uses: docker/build-push-action@v4
with:
context: .
push: true
tags: ${{ secrets.DOCKER_USERNAME }}/lesya_and_moa:latest
run_bot_container:
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/main'
steps:
- name: Checkout repo
uses: actions/checkout@v3
- name: Copy docker-compose.yml
uses: appleboy/scp-action@v0.1.7
with:
host: ${{ secrets.HOST }}
username: ${{ secrets.USER }}
password: ${{ secrets.PASSWORD }}
source: "docker-compose.yml"
target: /root/lesya_and_moa
- name: Login to Docker
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
- name: Executing remote ssh commands to deploy
uses: appleboy/ssh-action@master
with:
host: ${{ secrets.HOST }}
username: ${{ secrets.USER }}
password: ${{ secrets.PASSWORD }}
script: |
cd /root/lesya_and_moa
sudo docker compose down
sudo docker system prune -f
sudo docker image prune -f
sudo docker compose up -d