Skip to content

Commit

Permalink
Add Docker checks to GitHub Actions.
Browse files Browse the repository at this point in the history
  • Loading branch information
jamesiarmes committed May 8, 2024
1 parent d7008a8 commit 40a0f9f
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 1 deletion.
23 changes: 23 additions & 0 deletions .github/workflows/branch.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,3 +31,26 @@ jobs:
bundler-cache: true
- name: Run tests
run: bundle exec rspec

docker:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build the image
uses: docker/build-push-action@v5
with:
push: false
context: .
- name: Scan the image
uses: docker/scout-action@v1
with:
command: cves
# only-fixed: true
only-severities: critical,high
write-comment: true
2 changes: 1 addition & 1 deletion docker-compose.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
services:
web:
api:
build: .
volumes:
- .:/opt/app
Expand Down

0 comments on commit 40a0f9f

Please sign in to comment.