-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
issue 3: get docker release up and running (#4)
* change .release files to reference openbao instead of hashicorp and openbao instead of vault Signed-off-by: jessebot <[email protected]> * update Makefile - remove licensing, set openbao-helm to 0.4.0, and update registry to quay.io Signed-off-by: jessebot <[email protected]> * change another docker image reference to use quay.io/openbao Signed-off-by: jessebot <[email protected]> * change order of bats test to do teardown last Signed-off-by: jessebot <[email protected]> * add kubectl describe pod if something fails in the waiting process Signed-off-by: jessebot <[email protected]> * also check openbao-csi-provider pods if there is a failure; reduce timeout for kubectl wait commands to be 3 minutes instead of 5 Signed-off-by: jessebot <[email protected]> * clean up values for helm tests to work with new quay.io method, fix v in docker tag, make new lines for args consistent for helm install commands Signed-off-by: jessebot <[email protected]> * switch back to having registry_name in image_tag and comment out image_tag_latest as it's unused Signed-off-by: jessebot <[email protected]> * add -tls-skip-verify to the bootstrap tests Signed-off-by: jessebot <[email protected]> * update OPENBAO_CACERT to be VAULT_CACERT for testing Signed-off-by: jessebot <[email protected]> * update kind, bats, and node versions to be more current Signed-off-by: jessebot <[email protected]> * use ubi (non-arm) image for agent when running helm chart in bats tests for gha Signed-off-by: jessebot <[email protected]> * set a default timeout for integration-tests bats step to be 15 minutes Signed-off-by: jessebot <[email protected]> * update versions for actions checkout, upload-artifacts, download-artifacts, and helm/kind-action to latest Signed-off-by: jessebot <[email protected]> * update all the secret provider class yaml files to use vault as the provider this is until we can submit a PR to the upstream csi provider driver kubernetes-sigs repo to include openbao as a possible provider type Signed-off-by: jessebot <[email protected]> * remove license test and LICENSE related conditionals from bats testing Signed-off-by: jessebot <[email protected]> * fix comment for download-artifact step in tests gha Signed-off-by: jessebot <[email protected]> * add release workflow from openbao/openbao Signed-off-by: jessebot <[email protected]> * Apply suggestions from code review - downgrade actions/upload-artifact from 4.3.3 to 3.1.2 Signed-off-by: JesseBot <[email protected]> Signed-off-by: jessebot <[email protected]> * Update .github/workflows/build.yml - remove extra hyphen Signed-off-by: JesseBot <[email protected]> Signed-off-by: jessebot <[email protected]> --------- Signed-off-by: jessebot <[email protected]> Signed-off-by: JesseBot <[email protected]>
- Loading branch information
Showing
18 changed files
with
219 additions
and
116 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,137 @@ | ||
# Creates a GitHub Release. | ||
# Workflow is manually run. | ||
# Preselect branch or tag before running this workflow. | ||
name: release | ||
|
||
on: | ||
workflow_dispatch: | ||
inputs: | ||
# Defaults to publishing draft releases. | ||
# Review draft before formally releasing! | ||
draft: | ||
description: "Create a release draft" | ||
required: false | ||
default: true | ||
type: boolean | ||
prerelease: | ||
description: "Mark this release as a prerelease" | ||
required: false | ||
default: "auto" | ||
type: choice | ||
# auto follows semver. Prerelease versions are hyphenated with a label. ex. 0.0.0-alpha, 1.0.0-rc1 | ||
options: | ||
- auto | ||
- "true" | ||
- "false" | ||
make-latest: | ||
description: "Latest release" | ||
required: false | ||
default: true | ||
type: boolean | ||
|
||
permissions: | ||
contents: write | ||
id-token: write | ||
packages: write | ||
|
||
jobs: | ||
release: | ||
runs-on: self-hosted | ||
env: | ||
DOCKER_CLI_EXPERIMENTAL: "enabled" | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 # Required by GoRelease | ||
|
||
- name: Golang Setup | ||
uses: actions/setup-go@v5 | ||
with: | ||
go-version: stable | ||
check-latest: true | ||
|
||
- name: go-check | ||
run: go version | ||
|
||
# Supports Buildx | ||
- name: Qemu Setup | ||
uses: docker/setup-qemu-action@v3 | ||
|
||
- name: Buildx Setup | ||
uses: docker/setup-buildx-action@v3 | ||
|
||
- name: Cosign Install | ||
uses: sigstore/cosign-installer@v3 | ||
|
||
- name: GPG Import | ||
id: gpg-import | ||
uses: crazy-max/ghaction-import-gpg@v6 | ||
with: | ||
gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }} | ||
passphrase: ${{ secrets.GPG_PASSWORD }} | ||
|
||
- name: Cache Setup | ||
uses: actions/cache@v4 | ||
with: | ||
path: | | ||
./dist/** | ||
key: ${{ github.ref }} | ||
|
||
- name: "Docker Login: ghcr.io" | ||
if: startsWith(github.ref, 'refs/tags/') | ||
uses: docker/login-action@v3 | ||
with: | ||
registry: ghcr.io | ||
username: ${{ github.actor }} | ||
password: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- name: "Docker Login: docker.io" | ||
if: startsWith(github.ref, 'refs/tags/') | ||
uses: docker/login-action@v3 | ||
with: | ||
username: ${{ secrets.DOCKER_USERNAME }} | ||
password: ${{ secrets.DOCKER_TOKEN }} | ||
|
||
- name: "Docker Login: quay.io" | ||
if: startsWith(github.ref, 'refs/tags/') | ||
uses: docker/login-action@v3 | ||
with: | ||
registry: quay.io | ||
username: ${{ secrets.QUAY_USERNAME }} | ||
password: ${{ secrets.QUAY_TOKEN }} | ||
|
||
# Needed for nPFM | ||
- name: Create GPG Signing Key File | ||
if: startsWith(github.ref, 'refs/tags/') | ||
run: | | ||
GPG_KEY_FILE=/tmp/signing-key.gpg | ||
echo "${{ secrets.GPG_PRIVATE_KEY_BASE64 }}" | base64 -di > "${GPG_KEY_FILE}" | ||
echo "GPG_KEY_FILE=${GPG_KEY_FILE}" >> "${GITHUB_ENV}" | ||
env: | ||
GPG_TTY: /dev/ttys000 # Set the GPG_TTY to avoid issues with pinentry | ||
|
||
- name: "GoReleaser: Release" | ||
if: startsWith(github.ref, 'refs/tags/') | ||
uses: goreleaser/goreleaser-action@v5 | ||
with: | ||
distribution: goreleaser | ||
version: latest | ||
args: release --clean --timeout=60m --verbose --debug | ||
env: | ||
COSIGN_PASSWORD: ${{ secrets.COSIGN_PASSWORD }} | ||
COSIGN_PRIVATE_KEY: ${{ secrets.COSIGN_PRIVATE_KEY }} | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
GPG_FINGERPRINT: ${{ steps.gpg-import.outputs.fingerprint }} | ||
GPG_PASSWORD: ${{ secrets.GPG_PASSWORD }} | ||
GPG_PRIVATE_KEY: ${{ secrets.GPG_PRIVATE_KEY }} | ||
GITHUB_RELEASE_PRERELEASE: ${{ inputs.prerelease }} | ||
GITHUB_RELEASE_MAKE_LATEST: ${{ inputs.make-latest }} | ||
NFPM_DEFAULT_PASSPHRASE: ${{ secrets.GPG_PASSWORD }} | ||
|
||
- name: Remove GPG Signing Key File | ||
if: always() | ||
run: | | ||
if [ -n "${GPG_KEY_FILE}" ]; then | ||
rm -rf "${GPG_KEY_FILE}" | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
# Copyright (c) HashiCorp, Inc. | ||
# SPDX-License-Identifier: MPL-2.0 | ||
|
||
url_docker_registry_dockerhub = "https://registry.hub.docker.com/r/hashicorp/vault-csi-provider" | ||
url_license = "https://github.com/hashicorp/vault-csi-provider/blob/main/LICENSE" | ||
url_project_website = "https://www.vaultproject.io/docs/platform/k8s/csi" | ||
url_source_repository = "https://github.com/hashicorp/vault-csi-provider" | ||
url_docker_registry_dockerhub = "https://registry.hub.docker.com/r/openbao/openbao-csi-provider" | ||
url_license = "https://github.com/openbao/openbao-csi-provider/blob/main/LICENSE" | ||
url_project_website = "https://www.openbaoproject.io/docs/platform/k8s/csi" | ||
url_source_repository = "https://github.com/openbao/openbao-csi-provider" |
Oops, something went wrong.