Skip to content

Commit

Permalink
Add CI workflow to ensure docker image continues to build and run (#1366
Browse files Browse the repository at this point in the history
)
  • Loading branch information
rukai authored Nov 13, 2023
1 parent b8e4546 commit d9a6091
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions .github/workflows/docker.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
---
name: "docker"

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]

# Cancel already running jobs
concurrency:
group: docker_${{ github.head_ref }}
cancel-in-progress: true

jobs:
publish-image:
name: "Build docker image and run smoke test"
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Push image
run: |
# build image
docker build -t shotover:test .
# run image for 5 seconds and then send it SIGTERM, if it returns a nonzero exit code fail CI
timeout --preserve-status 5 docker run --mount type=bind,source="$(pwd)"/shotover-proxy/config,target=/config shotover:test

0 comments on commit d9a6091

Please sign in to comment.