Skip to content

Commit 49eaffe

Browse files
committed
add github actions workflow
1 parent c9c212a commit 49eaffe

File tree

1 file changed

+32
-0
lines changed

1 file changed

+32
-0
lines changed
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: Build and Push Scaphandre Docker Image
2+
3+
on:
4+
push:
5+
branches:
6+
- cerit-fork
7+
- gh-actions
8+
9+
env:
10+
IMAGE_NAME: "scaphandre/scaphandre"
11+
12+
permissions:
13+
packages: write
14+
contents: read
15+
16+
jobs:
17+
build-and-push:
18+
runs-on: ubuntu-latest
19+
20+
steps:
21+
- name: Checkout repository
22+
uses: actions/checkout@v4
23+
24+
- name: Log in to Docker registry
25+
run: echo "${{ secrets.REGISTRY_TOKEN }}" | docker login ${{ secrets.REGISTRY_URL }} -u "${{ secrets.REGISTRY_USERNAME }}" --password-stdin
26+
27+
- name: Build Docker image
28+
run: docker build -t ${{ secrets.REGISTRY_URL }}/${{ env.IMAGE_NAME }}:latest .
29+
30+
- name: Push Docker image
31+
run: docker push ${{ secrets.REGISTRY_URL }}/${{ env.IMAGE_NAME }}:latest
32+

0 commit comments

Comments
 (0)