Skip to content

Commit b7d896e

Browse files
committed
chore: Generated commit to update templated files since the last template run up to stackabletech/operator-templating@1f730e7
Reference-to: stackabletech/operator-templating@1f730e7 (Part of stackabletech/issues#716)
1 parent 41f4203 commit b7d896e

10 files changed

Lines changed: 52 additions & 24 deletions

File tree

.github/workflows/build.yaml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ jobs:
4848

4949
- name: Check for changed files
5050
id: check
51-
uses: stackabletech/actions/detect-changes@9848c5593dff4793aacba240116a648c02f20fa4 # v0.13.1
51+
uses: stackabletech/actions/detect-changes@ac6f1d3b87f68826b9a5838d13864ef8e88dcf40 # v0.14.0
5252
with:
5353
patterns: |
5454
- '.github/workflows/build.yaml'
@@ -166,7 +166,7 @@ jobs:
166166

167167
- name: Build Container Image
168168
id: build
169-
uses: stackabletech/actions/build-container-image@9848c5593dff4793aacba240116a648c02f20fa4 # v0.13.1
169+
uses: stackabletech/actions/build-container-image@ac6f1d3b87f68826b9a5838d13864ef8e88dcf40 # v0.14.0
170170
with:
171171
image-name: ${{ env.OPERATOR_NAME }}
172172
image-index-manifest-tag: ${{ steps.version.outputs.OPERATOR_VERSION }}
@@ -175,7 +175,7 @@ jobs:
175175

176176
- name: Publish Container Image
177177
if: ${{ !github.event.pull_request.head.repo.fork }}
178-
uses: stackabletech/actions/publish-image@9848c5593dff4793aacba240116a648c02f20fa4 # v0.13.1
178+
uses: stackabletech/actions/publish-image@ac6f1d3b87f68826b9a5838d13864ef8e88dcf40 # v0.14.0
179179
with:
180180
image-registry-uri: oci.stackable.tech
181181
image-registry-username: robot$sdp+github-action-build
@@ -203,7 +203,7 @@ jobs:
203203
persist-credentials: false
204204

205205
- name: Publish and Sign Image Index
206-
uses: stackabletech/actions/publish-image-index-manifest@9848c5593dff4793aacba240116a648c02f20fa4 # v0.13.1
206+
uses: stackabletech/actions/publish-image-index-manifest@ac6f1d3b87f68826b9a5838d13864ef8e88dcf40 # v0.14.0
207207
with:
208208
image-registry-uri: oci.stackable.tech
209209
image-registry-username: robot$sdp+github-action-build
@@ -230,7 +230,7 @@ jobs:
230230
submodules: recursive
231231

232232
- name: Package, Publish, and Sign Helm Chart
233-
uses: stackabletech/actions/publish-helm-chart@9848c5593dff4793aacba240116a648c02f20fa4 # v0.13.1
233+
uses: stackabletech/actions/publish-helm-chart@ac6f1d3b87f68826b9a5838d13864ef8e88dcf40 # v0.14.0
234234
with:
235235
chart-registry-uri: oci.stackable.tech
236236
chart-registry-username: robot$sdp-charts+github-action-build
@@ -260,7 +260,7 @@ jobs:
260260
runs-on: ubuntu-latest
261261
steps:
262262
- name: Run OpenShift Preflight Check
263-
uses: stackabletech/actions/run-openshift-preflight@9848c5593dff4793aacba240116a648c02f20fa4 # v0.13.1
263+
uses: stackabletech/actions/run-openshift-preflight@ac6f1d3b87f68826b9a5838d13864ef8e88dcf40 # v0.14.0
264264
with:
265265
image-index-uri: oci.stackable.tech/sdp/${{ env.OPERATOR_NAME }}:${{ needs.build-container-image.outputs.operator-version }}
266266
image-architecture: ${{ matrix.arch }}
@@ -300,7 +300,7 @@ jobs:
300300
persist-credentials: false
301301

302302
- name: Send Notification
303-
uses: stackabletech/actions/send-slack-notification@9848c5593dff4793aacba240116a648c02f20fa4 # v0.13.1
303+
uses: stackabletech/actions/send-slack-notification@ac6f1d3b87f68826b9a5838d13864ef8e88dcf40 # v0.14.0
304304
with:
305305
publish-helm-chart-result: ${{ needs.publish-helm-chart.result }}
306306
publish-manifests-result: ${{ needs.publish-index-manifest.result }}

.github/workflows/integration-test.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ jobs:
4141
# TODO: Enable the scheduled runs which hard-code what profile to use
4242
- name: Run Integration Test
4343
id: test
44-
uses: stackabletech/actions/run-integration-test@9848c5593dff4793aacba240116a648c02f20fa4 # v0.13.1
44+
uses: stackabletech/actions/run-integration-test@ac6f1d3b87f68826b9a5838d13864ef8e88dcf40 # v0.14.0
4545
with:
4646
replicated-api-token: ${{ secrets.REPLICATED_API_TOKEN }}
4747
test-mode-input: ${{ inputs.test-mode-input }}
@@ -51,7 +51,7 @@ jobs:
5151

5252
- name: Send Notification
5353
if: ${{ failure() || github.run_attempt > 1 }}
54-
uses: stackabletech/actions/send-slack-notification@9848c5593dff4793aacba240116a648c02f20fa4 # v0.13.1
54+
uses: stackabletech/actions/send-slack-notification@ac6f1d3b87f68826b9a5838d13864ef8e88dcf40 # v0.14.0
5555
with:
5656
slack-token: ${{ secrets.SLACK_INTEGRATION_TEST_TOKEN }}
5757
failed-tests: ${{ steps.test.outputs.failed-tests }}

.github/workflows/pr_pre-commit.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ jobs:
2727
persist-credentials: false
2828
submodules: recursive
2929
fetch-depth: 0
30-
- uses: stackabletech/actions/run-pre-commit@9848c5593dff4793aacba240116a648c02f20fa4 # v0.13.1
30+
- uses: stackabletech/actions/run-pre-commit@ac6f1d3b87f68826b9a5838d13864ef8e88dcf40 # v0.14.0
3131
with:
3232
python-version: ${{ env.PYTHON_VERSION }}
3333
rust: ${{ env.RUST_TOOLCHAIN_VERSION }}

Makefile

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,3 +76,9 @@ run-dev: check-nix check-kubernetes
7676

7777
stop-dev: check-nix check-kubernetes
7878
nix run --extra-experimental-features "nix-command flakes" -f. tilt -- down
79+
80+
helm-install:
81+
helm install \
82+
--values deploy/helm/${OPERATOR_NAME}/values.yaml \
83+
--values deploy/helm/${OPERATOR_NAME}/values/$(OCI_REGISTRY_HOSTNAME).yaml \
84+
${OPERATOR_NAME} deploy/helm/${OPERATOR_NAME}

Tiltfile

Lines changed: 12 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,19 @@
1-
# If tilt_options.json exists read it and load the default_registry value from it
1+
# Load the metadata first, so that we immediately get access to the operator name
2+
meta = read_json('nix/meta.json')
3+
operator_name = meta['operator']['name']
4+
5+
# If tilt_options.json exists read it and load the default_registry and default_repository value from it
26
settings = read_json('tilt_options.json', default={})
3-
registry = settings.get('default_registry', 'oci.stackable.tech/sandbox')
7+
registry = settings.get('default_registry', 'oci.stackable.tech')
8+
repository = settings.get('default_repository', registry + '/' + 'sdp')
9+
operator_image_name = repository + '/' + operator_name
410

5-
# Configure default registry either read from config file above, or with default value of "oci.stackable.tech/sandbox"
11+
# Configure default registry either read from config file above, or with default value of "oci.stackable.tech"
612
default_registry(registry)
713

8-
meta = read_json('nix/meta.json')
9-
operator_name = meta['operator']['name']
10-
1114
custom_build(
12-
registry + '/' + operator_name,
13-
'make regenerate-nix && nix-build . -A docker --argstr dockerName "${EXPECTED_REGISTRY}/' + operator_name + '" && ./result/load-image | docker load',
15+
operator_image_name,
16+
'make regenerate-nix && nix-build . -A docker --argstr dockerName "' + operator_image_name + '" && ./result/load-image | docker load',
1417
deps=['rust', 'Cargo.toml', 'Cargo.lock', 'default.nix', "nix", 'build.rs', 'vendor'],
1518
ignore=['*.~undo-tree~'],
1619
# ignore=['result*', 'Cargo.nix', 'target', *.yaml],
@@ -28,7 +31,7 @@ k8s_kind('DaemonSet', image_json_path='{.spec.template.metadata.annotations.inte
2831
# supported by helm(set).
2932
helm_values = settings.get('helm_values', None)
3033

31-
helm_override_image_repository = 'image.repository=' + registry + '/' + operator_name
34+
helm_override_image_repository = 'image.repository=' + repository
3235

3336
k8s_yaml(helm(
3437
'deploy/helm/' + operator_name,

deny.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,9 @@ ignore = [
1818
# https://rustsec.org/advisories/RUSTSEC-2023-0071
1919
# "rsa" crate: Marvin Attack: potential key recovery through timing sidechannel
2020
#
21-
# No patch is yet available, however work is underway to migrate to a fully constant-time implementation
22-
# So we need to accept this, as of SDP 25.3 we are not using the rsa crate to create certificates used in production
23-
# setups.
21+
# No patch is yet available, however work is underway to migrate to a fully constant-time implementation.
22+
# So we need to accept this, as of SDP 26.3 we are "only" using the crate to create private +
23+
# public key pairs used by webhooks, such as conversion or mutating webhooks.
2424
#
2525
# https://github.com/RustCrypto/RSA/issues/19 is the tracking issue
2626
"RUSTSEC-2023-0071",

deploy/helm/commons-operator/.helmignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@
66
# Patterns to ignore when building packages.
77
# This supports shell glob matching, relative path matching, and
88
# negation (prefixed with !). Only one pattern per line.
9+
# Ignore the file itself
10+
.helmignore
911
.DS_Store
1012
# Common VCS dirs
1113
.git/
@@ -26,3 +28,5 @@
2628
.idea/
2729
*.tmproj
2830
.vscode/
31+
# Partial, unmerged, registry-specific values files
32+
values/

deploy/helm/commons-operator/templates/_helpers.tpl

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -77,3 +77,10 @@ Labels for Kubernetes objects created by helm test
7777
{{- define "operator.testLabels" -}}
7878
helm.sh/test: {{ include "operator.chart" . }}
7979
{{- end }}
80+
81+
{{/*
82+
Build the full container image reference.
83+
*/}}
84+
{{- define "operator.image" -}}
85+
{{- printf "%s/%s:%s" .Values.image.repository .Chart.Name (.Values.image.tag | default .Chart.AppVersion) -}}
86+
{{- end }}

deploy/helm/commons-operator/templates/deployment.yaml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ spec:
1515
template:
1616
metadata:
1717
annotations:
18-
internal.stackable.tech/image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
18+
internal.stackable.tech/image: {{ include "operator.image" . }}
1919
checksum/config: {{ include (print $.Template.BasePath "/configmap.yaml") . | sha256sum }}
2020
{{- with .Values.podAnnotations }}
2121
{{- toYaml . | nindent 8 }}
@@ -37,7 +37,7 @@ spec:
3737
- name: {{ include "operator.appname" . }}
3838
securityContext:
3939
{{- toYaml .Values.securityContext | nindent 12 }}
40-
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
40+
image: {{ include "operator.image" . }}
4141
imagePullPolicy: {{ .Values.image.pullPolicy }}
4242
resources:
4343
{{- toYaml .Values.resources | nindent 12 }}
@@ -70,6 +70,10 @@ spec:
7070
- name: OPERATOR_SERVICE_NAME
7171
value: {{ include "operator.fullname" . }}
7272

73+
# The image repository, like "oci.stackable.tech/sdp"
74+
- name: IMAGE_REPOSITORY
75+
value: {{ .Values.image.repository }}
76+
7377
# Operators need to know the node name they are running on, to e.g. discover the
7478
# Kubernetes domain name from the kubelet API.
7579
- name: KUBERNETES_NODE_NAME
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
---
2+
# Values overlay for chart packages published to oci.stackable.tech.
3+
image:
4+
repository: oci.stackable.tech/sdp

0 commit comments

Comments
 (0)