Skip to content

Commit 977718b

Browse files
committed
first trial pushing docker image to github container
1 parent ae50e95 commit 977718b

File tree

1 file changed

+34
-0
lines changed

1 file changed

+34
-0
lines changed
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
name: Build and Push Docker Image
2+
3+
on:
4+
push:
5+
branches:
6+
- main # or any branch you deploy from
7+
- fix_issue_GHCR
8+
jobs:
9+
build-and-push:
10+
runs-on: ubuntu-latest
11+
12+
permissions:
13+
contents: read
14+
packages: write # required for GHCR
15+
16+
steps:
17+
- name: Checkout code
18+
uses: actions/checkout@v4
19+
20+
- name: Log in to GitHub Container Registry
21+
uses: docker/login-action@v3
22+
with:
23+
registry: ghcr.io
24+
username: ${{ github.actor }}
25+
password: ${{ secrets.GITHUB_TOKEN }}
26+
27+
- name: Build Docker image
28+
run: |
29+
docker build -t ghcr.io/${{ github.repository_owner }}/nextflow-app:latest .
30+
31+
- name: Push Docker image
32+
run: |
33+
docker push ghcr.io/${{ github.repository_owner }}/nextflow-app:latest
34+

0 commit comments

Comments
 (0)