Skip to content

Commit

Permalink
Boilerplate: Update to b0f8c3286cb9ec17059e7870e7fcb1a2049e16f0
Browse files Browse the repository at this point in the history
Conventions:
- openshift/golang-osd-operator: Update
- openshift/golang-osd-operator-osde2e: Update
---
openshift/boilerplate@b9d4e1e...b0f8c32

commit: af5c9d7871e141e9735fc578d7711e22ef9e73b2
author: Benson Ngoy
removes leading g before comparing short_hash to DEPLOYED_HASH

commit: 0ed6bd57140fc4e000a11dabc6a1f69c27884f62
author: Josh Branham
Exit early if skopeo binary not found

commit: de410f4b290b2e398864ba173ccbdc4de1dc2a26
author: red-hat-konflux[bot]
chore(deps): update konflux references

Signed-off-by: red-hat-konflux <126015336+red-hat-konflux[bot]@users.noreply.github.com>

commit: 13d1bbd579b6ef8067620f85a945837c96c90d59
author: Josh Branham
Cleanup srep-functional-team-aurora alias

commit: f42a693ac096a26d6a394264f2f253ab4486c26b
author: Luis Falcon
Removing michael shen from OWNER_ALIAS FILE as part of the leaver process

commit: 312bf1622014a0d8b1a65aa6c30c49ae87901608
author: Brady Pratt
pipelines/catalog-builder: change dockerfile default

the generated file is catalog.Dockerfile

Signed-off-by: Brady Pratt <bpratt@redhat.com>

commit: e06b60f89904733b05bd73260b3a7e33c9511215
author: Brady Pratt
pipelines/catalog-builder: add deprecated-base-image-check task

this is required by the EC checks

```
✕ [Violation] tasks.required_tasks_found
  ImageRef: quay.io/redhat-user-workloads/oeo-cicada-tenant/osd-example-operator-main/osd-example-operator-main/catalog@sha256:70cbca46b46d21b4aecfb39a92cc80287ac776255c8f3b21f4ea9bd226b99a7f
  Reason: Required task "deprecated-image-check" is missing
  Title: All required tasks were included in the pipeline
  Description: Ensure that the set of required tasks are included in the PipelineRun attestation. To exclude this rule add
  "tasks.required_tasks_found:deprecated-image-check" to the `exclude` section of the policy configuration.
  Solution: Make sure all required tasks are in the build pipeline. The required task list is contained as
  xref:ec-cli:ROOT:configuration.adoc#_data_sources[data] under the key 'required-tasks'.
```

Signed-off-by: Brady Pratt <bpratt@redhat.com>

commit: bdaaa877760d5a69430fced075388bf6bc000328
author: Brady Pratt
pipelines/bundle-builder: fix indentation

need to write up some tests for this...

Signed-off-by: Brady Pratt <bpratt@redhat.com>

commit: 259fb276f80207af9bd7627edf7cb7c1cc74a81f
author: Brady Pratt
pipelines/bundle-builder: add rpm-signature-scan

its a required task though I don't know how well it will operate on the
OLM bundle images

Signed-off-by: Brady Pratt <bpratt@redhat.com>

commit: f14cd9948f68e7d409854f89dd3e6d2b138dcbd0
author: red-hat-konflux[bot]
chore(deps): update konflux references to d091a9e

Signed-off-by: red-hat-konflux <126015336+red-hat-konflux[bot]@users.noreply.github.com>

commit: 5606e36c9b48805b9b732c90ae99e8461e49f8e0
author: red-hat-konflux[bot]
chore(deps): update konflux references

Signed-off-by: red-hat-konflux <126015336+red-hat-konflux[bot]@users.noreply.github.com>

commit: ee948b850dfab298bbbca1d008cfebb043fc3dee
author: Brady Pratt
pipelines/bundle-builder: swap from plus to minus

operator-sdk doesn't like the plus so use minus instead

Signed-off-by: Brady Pratt <bpratt@redhat.com>

commit: 6b5d4401214543c0eb4783de221dc44d3c8ce7a4
author: Brady Pratt
pipelines/bundle-builder: add +g to sha

this will change the version to `0.2.1731576556+g0666347`

a `+` is usually used to append this metadata, not a `-`

```
time="2024-11-14T09:30:34Z" level=fatal msg="invalid command options: 0.2.1731576556-0666347 is not a valid semantic version: Numeric PreRelease version must not contain leading zeroes "0666347""
```

Signed-off-by: Brady Pratt <bpratt@redhat.com>

commit: f7b8bcfd73b30fc4953ec0c7d7eacf987e675cc3
author: Brady Pratt
pipelines/bundle-builder: set major/minor version

to 0.2.X

Signed-off-by: Brady Pratt <bpratt@redhat.com>

commit: 6cbbfdb933b33c1a887809a4c7b1b5c505eb9e59
author: Brady Pratt
write out additional-labels.txt

this is required by Konflux to pass validation. The labels get appended
to the OLM bundle dockerfile. Teams will need to update the description
field

Signed-off-by: Brady Pratt <bpratt@redhat.com>

commit: cf70616a2a57fc57de8b70f34a7b7f71d5d81e9f
author: red-hat-konflux[bot]
chore(deps): update konflux references

Signed-off-by: red-hat-konflux <126015336+red-hat-konflux[bot]@users.noreply.github.com>

commit: 40b5527c05cf167967087b062a5676d3ad77c658
author: red-hat-konflux[bot]
chore(deps): update konflux references

Signed-off-by: red-hat-konflux <126015336+red-hat-konflux[bot]@users.noreply.github.com>

commit: 733a1083d1a2808e95df139f828c72392b81233c
author: Brady Pratt
fix: add GOPATH to PATH

https://redhat-internal.slack.com/archives/CFJD1NZFT/p1731341694284609?thread_ts=1731337912.626849&cid=CFJD1NZFT

Signed-off-by: Brady Pratt <bpratt@redhat.com>

commit: 3629981d9035f8269857c9adf297183ab797fb95
author: red-hat-konflux[bot]
chore(deps): update konflux references to 0f7df2d

Signed-off-by: red-hat-konflux <126015336+red-hat-konflux[bot]@users.noreply.github.com>

commit: 6ea077df4ab51a9197ff0085df3b11d4f3eb1b9c
author: Brady Pratt
.tekton: add rpms-signature-scan task

it is required, EC checks are failing because it is missing

Signed-off-by: Brady Pratt <bpratt@redhat.com>

commit: 7df9cbf53c5db1bea727e2d2d799be3711d378ae
author: red-hat-konflux[bot]
chore(deps): update konflux references

Signed-off-by: red-hat-konflux <126015336+red-hat-konflux[bot]@users.noreply.github.com>

commit: 9d7b1c5ab9157b7a59ada1638f4eb346a5bd8f8c
author: Brady Pratt
fix: add .tekton to includePaths

this seems to be overidden from the extended renovate config and only
working on the pipelines/ directory

Signed-off-by: Brady Pratt <bpratt@redhat.com>

commit: a42cb70334ffc76978db3def12d15499594235cd
author: red-hat-konflux[bot]
chore(deps): update konflux references to 11b7f08

Signed-off-by: red-hat-konflux <126015336+red-hat-konflux[bot]@users.noreply.github.com>

commit: 3fc3d56c802fb69b272f4d1faa5a5a0eb957e133
author: red-hat-konflux[bot]
chore(deps): update konflux references

Signed-off-by: red-hat-konflux <126015336+red-hat-konflux[bot]@users.noreply.github.com>

commit: 89a937c9e2b0652856ce30615754225e8dfcddba
author: Brady Pratt
chore: rename renovate config

spelling err

Signed-off-by: Brady Pratt <bpratt@redhat.com>

commit: 6e98a4b9b3b2d82c1bf3f3304a2282a458934b82
author: red-hat-konflux
Red Hat Konflux purge bundle-builder Signed-off-by: red-hat-konflux <konflux@no-reply.konflux-ci.dev>

commit: 04c0439f8860545757f99abd3e6d461e12a349d1
author: red-hat-konflux
Red Hat Konflux purge catalog-builder Signed-off-by: red-hat-konflux <konflux@no-reply.konflux-ci.dev>

commit: 142de2d02479e688249a7b3dc051a65f9eb22f4d
author: Brady Pratt
chore: add rennovate config

to keep the tekton pipelines up to date

Signed-off-by: Brady Pratt <bpratt@redhat.com>

commit: d59b0b5120af2b7ee4dc16d1f159884ee63e0ced
author: Brady Pratt
golang-osd-operator-osde2e: swap image base on update

Signed-off-by: Brady Pratt <bpratt@redhat.com>

commit: 1bd491896cd36500e60be09789b615652bd06994
author: Brady Pratt
Revert "golang-osd-operator-osde2e: alter base image"

This reverts commit f37e720681da5a5ef768d8025eefc12a27860663.

commit: 319f56ac13aee991b1bd13136c4c473d6b793ca2
author: red-hat-konflux[bot]
chore(deps): update konflux references to 3be04ad

Signed-off-by: red-hat-konflux <126015336+red-hat-konflux[bot]@users.noreply.github.com>

commit: da663bd82b017a0caa96d65eef25582c210e0795
author: Brady Pratt
KONFLUX-3729: swap to new base image on update

operators should now start pointing to the konflux built base image, it
is public and can be pulled from Jenkins without issue; this swap will
be required when an operator begins onboarding onto konflux

Signed-off-by: Brady Pratt <bpratt@redhat.com>

commit: c608108dd6b09186400dc34e0cb89c0b1fc9ba88
author: Dustin Row
Symlink OWNERS_ALIASES and update BP Owners for more coverage

commit: 07bc19ce54b73298991228c6b81e484c653780b7
author: Brady Pratt
KONFLUX-3729: swap over image and rm build script

Signed-off-by: Brady Pratt <bpratt@redhat.com>

commit: 0f9606bf2726eea4d379cce05548ff65d5587b50
author: Brady Pratt
OWNERS: add self to reviewers

Signed-off-by: Brady Pratt <bpratt@redhat.com>

commit: 7452d63e3654df807f16f6eb1fc81b73290aa29a
author: Brady Pratt
fix: quotes preventing expansion

```
...
++ mktemp -d
+ BP_CLONE=/tmp/tmp.1P95PaSBNN
+ [[ -z '' ]]
+ git clone -b konflux-swapover git@github.com:jbpratt/boilerplate.git /tmp/tmp.1P95PaSBNN
Cloning into '/tmp/tmp.1P95PaSBNN'...
remote: Enumerating objects: 4473, done.
remote: Counting objects: 100% (792/792), done.
...
```

Signed-off-by: Brady Pratt <bpratt@redhat.com>

commit: 5b81904a97992638af306f4bd16ae4c72517ed97
author: Brady Pratt
fix: allow custom clone commands for updating

this was removed in f306247c32d68c82a446399e27c37e90b75fccfe and is
needed to clone a non-default branch of boilerplate

Signed-off-by: Brady Pratt <bpratt@redhat.com>
  • Loading branch information
dustman9000 committed Nov 26, 2024
1 parent 8ab29e9 commit e9fda93
Show file tree
Hide file tree
Showing 13 changed files with 58 additions and 15 deletions.
2 changes: 1 addition & 1 deletion .ci-operator.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
build_root_image:
name: boilerplate
namespace: openshift
tag: image-v5.0.1
tag: image-v6.0.1
3 changes: 1 addition & 2 deletions OWNERS_ALIASES
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ aliases:
srep-functional-team-aurora:
- abyrne55
- dakotalongRH
- lnguyen1401
- joshbranham
- luis-falcon
- reedcort
srep-functional-team-fedramp:
Expand Down Expand Up @@ -74,7 +74,6 @@ aliases:
- Nikokolas3270
- theautoroboto
- bmeng
- mjlshen
- sam-nguyen7
- ravitri
- mmazur
Expand Down
2 changes: 1 addition & 1 deletion boilerplate/_data/backing-image-tag
Original file line number Diff line number Diff line change
@@ -1 +1 @@
image-v5.0.1
image-v6.0.1
2 changes: 1 addition & 1 deletion boilerplate/_data/last-boilerplate-commit
Original file line number Diff line number Diff line change
@@ -1 +1 @@
b9d4e1ee64a3df00201d6c0c82b83c2e84e553aa
b0f8c3286cb9ec17059e7870e7fcb1a2049e16f0
5 changes: 5 additions & 0 deletions boilerplate/_lib/common.sh
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,11 @@ image_exists_in_repo() {

local skopeo_stderr=$(mktemp)

if ! command -v skopeo &>/dev/null; then
echo "Failed to find the skopeo binary. If you are on Mac: brew install skopeo." >&2
exit 1
fi

output=$(skopeo inspect docker://${image_uri} 2>$skopeo_stderr)
rc=$?
# So we can delete the temp file right away...
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,9 @@ export REPLACE_FUNC=$(echo "$REPLACE_SPECNAME" | sed 's/ //g' )

mkdir -p $HARNESS_DIR

E2E_SUITE_BUILDER_IMAGE="registry.ci.openshift.org/openshift/release:rhel-8-release-golang-1.22-openshift-4.17"
if [[ -n ${KONFLUX_BUILDS} ]]; then
E2E_SUITE_BUILDER_IMAGE="brew.registry.redhat.io/rh-osbs/openshift-golang-builder:rhel_9_1.22"
fi

echo "# THIS FILE IS GENERATED BY BOILERPLATE. DO NOT EDIT.
FROM ${E2E_SUITE_BUILDER_IMAGE} as builder
FROM registry.ci.openshift.org/openshift/release:rhel-8-release-golang-1.22-openshift-4.17 as builder
WORKDIR /go/src/github.com/openshift/$OPERATOR_NAME/
COPY . .
RUN CGO_ENABLED=0 GOFLAGS=\"-mod=mod\" go test ./osde2e -v -c --tags=osde2e -o /harness.test
Expand Down
17 changes: 17 additions & 0 deletions boilerplate/openshift/golang-osd-operator-osde2e/update
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#!/usr/bin/env bash

set -e

source $CONVENTION_ROOT/_lib/common.sh

# No PRE
[[ "$1" == "PRE" ]] && exit 0

# Expect POST
[[ "$1" == "POST" ]] || err "Got a parameter I don't understand: '$1'. Did the infrastructure change?"

DOCKERFILE=osde2e/Dockerfile
if [[ -n ${KONFLUX_BUILDS} && -f "${DOCKERFILE}" ]]; then
E2E_SUITE_BUILDER_IMAGE="brew.registry.redhat.io/rh-osbs/openshift-golang-builder:rhel_8_1.22"
${SED?} -i "2s,.*,FROM $E2E_SUITE_BUILDER_IMAGE AS builder," "${DOCKERFILE}"
fi
3 changes: 1 addition & 2 deletions boilerplate/openshift/golang-osd-operator/OWNERS_ALIASES
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ aliases:
srep-functional-team-aurora:
- abyrne55
- dakotalongRH
- lnguyen1401
- joshbranham
- luis-falcon
- reedcort
srep-functional-team-fedramp:
Expand Down Expand Up @@ -74,7 +74,6 @@ aliases:
- Nikokolas3270
- theautoroboto
- bmeng
- mjlshen
- sam-nguyen7
- ravitri
- mmazur
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,11 @@ if [[ -z "$SKIP_SAAS_FILE_CHECKS" ]]; then

if [[ "$delete" == false ]]; then
short_hash=$(echo "$version" | cut -d- -f2)


# before comparing the short_hash to the deployment hash, remove the leading g added in https://issues.redhat.com/browse/OSD-13681
# short_hash should be 7 char long without the leading g.
[ ${#short_hash} -gt 7 ] && short_hash=${short_hash:1:7}

if [[ "$DEPLOYED_HASH" == "${short_hash}"* ]]; then
delete=true
fi
Expand Down
19 changes: 19 additions & 0 deletions boilerplate/openshift/golang-osd-operator/update
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,25 @@ if [[ -f ${REPO_ROOT}/.gitignore ]]; then
${SED?} -i "/Dockerfile.olm-registry/d" ${REPO_ROOT}/.gitignore
fi

OPERATOR_NAME=$(sed -n 's/.*OperatorName .*"\([^"]*\)".*/\1/p' "${REPO_ROOT}/config/config.go")

if [[ ! -f ${REPO_ROOT}/config/metadata/additional-labels.txt ]]; then
mkdir -p ${REPO_ROOT}/config/metadata
cat >${REPO_ROOT}/config/metadata/additional-labels.txt <<EOF
LABEL com.redhat.component="openshift-${OPERATOR_NAME}" \
io.k8s.description="..." \
description="..." \
distribution-scope="public" \
name="openshift/${OPERATOR_NAME}" \
url="https://github.com/openshift/${OPERATOR_NAME}" \
vendor="Red Hat, Inc." \
release="v0.0.0" \
version="v0.0.0"
EOF
fi

IMAGE_PULL_PATH="quay.io/redhat-services-prod/openshift/boilerplate:${LATEST_IMAGE_TAG}"

# Update Dockerfile builder image
DOCKERFILES=$(ls -1 $REPO_ROOT/build/Dockerfile*)
for file in $DOCKERFILES; do
Expand Down
5 changes: 4 additions & 1 deletion boilerplate/update
Original file line number Diff line number Diff line change
Expand Up @@ -104,10 +104,13 @@ EOF
if [ -z "$BOILERPLATE_GIT_REPO" ]; then
BOILERPLATE_GIT_REPO=git@github.com:openshift/boilerplate.git
fi
if [ -z "$BOILERPLATE_GIT_CLONE" ]; then
BOILERPLATE_GIT_CLONE="git clone"
fi
BP_CLONE="$(mktemp -d)"

if [[ -z "${BOILERPLATE_IN_CI}" ]]; then
git clone "${BOILERPLATE_GIT_REPO}" "${BP_CLONE}"
${BOILERPLATE_GIT_CLONE} "${BOILERPLATE_GIT_REPO}" "${BP_CLONE}"
else
# HACK: We can't get around safe.directory in CI, so just leverage cp instead of git
cp -rf /go/src/github.com/openshift/boilerplate/* "${BP_CLONE}"
Expand Down
2 changes: 1 addition & 1 deletion build/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM quay.io/app-sre/boilerplate:image-v5.0.1 AS builder
FROM quay.io/redhat-services-prod/openshift/boilerplate:image-v6.0.1 AS builder

WORKDIR /workdir
COPY go.mod go.mod
Expand Down
1 change: 1 addition & 0 deletions config/metadata/additional-labels.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
LABEL com.redhat.component="openshift-aws-vpce-operator" io.k8s.description="..." description="..." distribution-scope="public" name="openshift/aws-vpce-operator" url="https://github.com/openshift/aws-vpce-operator" vendor="Red Hat, Inc." release="v0.0.0" version="v0.0.0"

0 comments on commit e9fda93

Please sign in to comment.