Skip to content

Commit f17c9c7

Browse files
authored
Add a Docker build and test Action
1 parent 1114367 commit f17c9c7

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed

.github/workflows/docker-image.yml

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
name: Docker Image CI
2+
3+
on:
4+
push:
5+
branches: [ "master" ]
6+
pull_request:
7+
branches: [ "master" ]
8+
9+
jobs:
10+
11+
build-docker:
12+
13+
runs-on: ubuntu-latest
14+
15+
steps:
16+
- uses: actions/checkout@v3
17+
- name: Build the Debian Docker image
18+
run: docker build . --file Dockerfile --tag backup-utils-debian:$(date +%s)
19+
- name: Build the Alpine Docker image
20+
run: docker build . --file Dockerfile.alpine --tag backup-utils-alpine:$(date +%s)
21+
- name: Run tests in Debian Docker image
22+
run: docker run -it backup-utils-debian:$(date +%s) make test
23+
- name: Run tests in Alpine Docker image
24+
run: docker run -it backup-utils-alpine:$(date +%s) make test

0 commit comments

Comments
 (0)