Skip to content

Commit d31af04

Browse files
committed
feat: added CI pipeline build and push
1 parent b7738e3 commit d31af04

1 file changed

Lines changed: 26 additions & 0 deletions

File tree

.github/workflows/ci.yaml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches:
6+
- "*"
7+
8+
jobs:
9+
build-and-push:
10+
runs-on: ubuntu-latest
11+
steps:
12+
- name: Checkout code
13+
uses: actions/checkout@v3
14+
15+
- name: Login to DockerHub
16+
uses: docker/login-action@v3
17+
with:
18+
username: ${{ secrets.DOCKERHUB_USERNAME }}
19+
password: ${{ secrets.DOCKERHUB_TOKEN }}
20+
21+
- name: Build and push
22+
if: github.ref == 'refs/heads/main'
23+
uses: docker/build-push-action@v3
24+
with:
25+
push: true
26+
tags: ${{ secrets.DOCKERHUB_USERNAME }}/task-manager:${{ github.sha }}

0 commit comments

Comments
 (0)