Skip to content

Commit

Permalink
Fix scorecard version in Scorecard Docker images (#1480)
Browse files Browse the repository at this point in the history
Co-authored-by: Azeem Shaikh <[email protected]>
  • Loading branch information
azeemshaikh38 and azeemsgoogle authored Jan 14, 2022
1 parent 361fbd0 commit b6272c7
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 20 deletions.
30 changes: 10 additions & 20 deletions cloudbuild/scorecard-tag.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,23 +12,13 @@
# See the License for the specific language governing permissions and
# limitations under the License.

build:
images:
- gcr.io/openssf/scorecard:$TAG_NAME
options: {}
steps:
- args:
- build
- -t
- gcr.io/openssf/scorecard:$TAG_NAME
- .
name: gcr.io/cloud-builders/docker
description: scorecard build based on tag
github:
name: scorecard
owner: ossf
push:
tag: .*
name: scorecard-tag
tags:
- v*
steps:
- id: 'Get Git history'
name: 'gcr.io/cloud-builders/git'
args: ['fetch', '--unshallow', '--tags', 'origin', '$COMMIT_SHA']
- name: 'gcr.io/cloud-builders/docker'
args: ['build', '.',
'-t', 'gcr.io/openssf/scorecard:stable',
'-t', 'gcr.io/openssf/scorecard:$TAG_NAME',
'-f', 'Dockerfile']
images: ['gcr.io/openssf/scorecard']
3 changes: 3 additions & 0 deletions cloudbuild/scorecard.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@
# limitations under the License.

steps:
- id: 'Get Git history'
name: 'gcr.io/cloud-builders/git'
args: ['fetch', '--unshallow', '--tags', 'origin', '$COMMIT_SHA']
- name: 'gcr.io/cloud-builders/docker'
args: ['build', '.',
'-t', 'gcr.io/openssf/scorecard:latest',
Expand Down

0 comments on commit b6272c7

Please sign in to comment.