New Update #276
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: CI/CD | |
on: | |
push: | |
branches: | |
- 'main' | |
jobs: | |
build: | |
runs-on: ubuntu-22.04 | |
steps: | |
# Build Docker image: | |
- uses: actions/checkout@v4 | |
- name: Build and tag image | |
run: | | |
docker build -t megoru/giveaway:latest . | |
# Login to Docker Hub: | |
- name: Docker login | |
uses: docker/login-action@v3 | |
with: | |
username: ${{ secrets.DOCKER_LOGIN }} | |
password: ${{ secrets.DOCKER_PASSWORD }} | |
# Push image to Docker Hub: | |
- name: Publish image | |
run: docker push megoru/giveaway:latest |