Update .gitignore #8
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Deploy Docker Image | ||
on: | ||
push: | ||
branches: | ||
- main | ||
workflow_run: | ||
workflows: [ "Run Tests" ] | ||
branches: [ main ] | ||
types: | ||
- completed | ||
jobs: | ||
docker: | ||
name: Build and Push Docker Images | ||
runs-on: ubuntu-latest | ||
needs: [ci] # Docker image should be built after CI jobs are successful. | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v3 | ||
- name: Set up Docker Buildx | ||
uses: docker/setup-buildx-action@v2 | ||
- name: Log in to Docker Hub | ||
uses: docker/login-action@v2 | ||
with: | ||
username: ${{ secrets.DOCKER_HUB_USERNAME }} | ||
password: ${{ secrets.DOCKER_HUB_ACCESS_TOKEN }} | ||
- name: Build and push Docker images using Docker Compose | ||
run: | | ||
docker-compose build | ||
docker-compose push |