aboutsummaryrefslogtreecommitdiff
path: root/.github/workflows/main-branch.yml
blob: d8584cbbd8e9b9f030ffa8fa3a9b2f7639686f05 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
name: Push image to dockerhub
on:
  push:
    branches:
      - main
jobs:
  build-and-push:
    name: Build the docker container image and push it to dockerhub
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - uses: docker/login-action@v3
        with:
          username: ${{ secrets.DOCKERHUB_USERNAME }}
          password: ${{ secrets.DOCKERHUB_TOKEN }}
      - uses: docker/build-push-action@v5
        with:
          push: true
          tags: ${{ secrets.DOCKERHUB_USERNAME }}/pico-web-server:latest