1
0
mirror of https://github.com/siderolabs/kres.git synced 2026-02-05 09:45:35 +01:00

fix: fail pipeline on yq error

Fail pipeline if secrets cannot be used.

Signed-off-by: Noel Georgi <git@frezbo.dev>
This commit is contained in:
Noel Georgi
2024-04-20 22:11:38 +05:30
parent add13d7cb5
commit ebc009dce3
3 changed files with 8 additions and 7 deletions

View File

@@ -1,6 +1,6 @@
# THIS FILE WAS AUTOMATICALLY GENERATED, PLEASE DO NOT EDIT.
#
# Generated on 2024-04-11T10:57:07Z by kres bff9c81-dirty.
# Generated on 2024-04-20T16:39:33Z by kres add13d7.
name: default
concurrency:
@@ -45,6 +45,7 @@ jobs:
run: |
git fetch --prune --unshallow
- name: Set up Docker Buildx
id: setup-buildx
uses: docker/setup-buildx-action@v3
with:
driver: remote

View File

@@ -2,16 +2,16 @@
# THIS FILE WAS AUTOMATICALLY GENERATED, PLEASE DO NOT EDIT.
#
# Generated on 2024-03-20T16:05:33Z by kres c2d361c-dirty.
# Generated on 2024-04-20T16:39:33Z by kres add13d7.
ARG TOOLCHAIN
FROM ghcr.io/siderolabs/ca-certificates:v1.6.0 AS image-ca-certificates
FROM ghcr.io/siderolabs/ca-certificates:v1.7.0 AS image-ca-certificates
FROM ghcr.io/siderolabs/fhs:v1.6.0 AS image-fhs
FROM ghcr.io/siderolabs/fhs:v1.7.0 AS image-fhs
# runs markdownlint
FROM docker.io/node:21.7.1-alpine3.19 AS lint-markdown
FROM docker.io/node:21.7.3-alpine3.19 AS lint-markdown
WORKDIR /src
RUN npm i -g markdownlint-cli@0.39.0
RUN npm i sentences-per-line@0.2.1

View File

@@ -277,11 +277,11 @@ func SOPSSteps() []*Step {
return []*Step{
{
Name: "Mask secrets",
Run: "echo -e \"$(sops -d .secrets.yaml | yq '.secrets | to_entries[] | \"::add-mask::\" + .value')\"\n",
Run: "echo -e \"$(sops -d .secrets.yaml | yq -e '.secrets | to_entries[] | \"::add-mask::\" + .value')\"\n",
},
{
Name: "Set secrets for job",
Run: "sops -d .secrets.yaml | yq '.secrets | to_entries[] | .key + \"=\" + .value' >> \"$GITHUB_ENV\"\n",
Run: "sops -d .secrets.yaml | yq -e '.secrets | to_entries[] | .key + \"=\" + .value' >> \"$GITHUB_ENV\"\n",
},
}
}