Skip to content

Commit

Permalink
Add CircleCI workflow to push images automatically
Browse files Browse the repository at this point in the history
  • Loading branch information
kreamkorokke committed Nov 19, 2020
1 parent 68beacb commit c12751c
Showing 1 changed file with 18 additions and 2 deletions.
20 changes: 18 additions & 2 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,27 @@ jobs:
name: Run unit tests
command: |
make test
publish:
<<: *defaults
steps:
- run:
name: Login to gcr.io
command: |
gcloud auth activate-service-account --key-file <(echo "$PUSH_TO_GCR_STACKROX_HUB")
gcloud auth list
gcloud --quiet auth configure-docker
- checkout
- run:
name: Build and push image
command: make push

workflows:
build:
jobs:
- lint:
context: docker-io-pull
context: gcr-io-stackrox-hub-push
- test:
context: docker-io-pull
context: gcr-io-stackrox-hub-push
- publish:
context: gcr-io-stackrox-hub-push

0 comments on commit c12751c

Please sign in to comment.