Skip to content

Commit

Permalink
Add test
Browse files Browse the repository at this point in the history
  • Loading branch information
rafaelbreno committed Sep 12, 2024
1 parent 27c52c6 commit 7c961a8
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 19 deletions.
27 changes: 9 additions & 18 deletions .github/workflows/image-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,42 +15,33 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Check out code
uses: actions/checkout@v5
uses: actions/checkout@v4

- name: get the build-args values
id: get-build-args
run: |
echo "$(make -s log | grep TAG)" >> "$GITHUB_ENV"
echo "$(make -s log | grep GOLANG_VERSION)" >> "$GITHUB_ENV"
- name: "Read secrets"
uses: rancher-eio/read-vault-secrets@main
with:
secrets: |
secret/data/github/repo/${{ github.repository }}/dockerhub/${{ github.repository_owner }}/credentials username | DOCKER_USERNAME ;
secret/data/github/repo/${{ github.repository }}/dockerhub/${{ github.repository_owner }}/credentials password | DOCKER_PASSWORD
#- name: "Read secrets"
#uses: rancher-eio/read-vault-secrets@main
#with:
#secrets: |
#secret/data/github/repo/${{ github.repository }}/dockerhub/${{ github.repository_owner }}/credentials username | DOCKER_USERNAME ;
#secret/data/github/repo/${{ github.repository }}/dockerhub/${{ github.repository_owner }}/credentials password | DOCKER_PASSWORD

- name: Login to Container Registry
uses: docker/login-action@v3
with:
username: ${{ env.DOCKER_USERNAME }}
password: ${{ env.DOCKER_PASSWORD }}
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_SECRET }}

- name: Build and push image
uses: rancher/ecm-distro-tools/actions/publish-image@master
with:
image: hardened-kubernetes
tag: ${{ github.event.release.tag_name }}
context: .
public-repo: rancher
public-username: ${{ env.DOCKER_USERNAME }}
public-password: ${{ env.DOCKER_PASSWORD }}
push-to-prime: false

push: true
tags: rancher/hardened-kubernetes:${{ github.event.release.tag_name }}
file: Dockerfile
platforms: linux/amd64,linux/arm64
build-args: |
TAG=${{ env.TAG }}
GO_IMAGE=rancher/hardened-build-base:${{ env.GOLANG_VERSION }}
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ SEVERITIES = HIGH,CRITICAL

UNAME_M = $(shell uname -m)

ORG ?= rancher
ORG ?= rafiusky
PKG ?= github.com/kubernetes/kubernetes
SRC ?= github.com/kubernetes/kubernetes
TAG ?= ${GITHUB_ACTION_TAG}
Expand Down

0 comments on commit 7c961a8

Please sign in to comment.