Skip to content

Commit 9610d8b

Browse files
committed
Merge remote-tracking branch 'origin/main' into feat/operator-service
2 parents 6ae235e + 816ec99 commit 9610d8b

File tree

14 files changed

+1480
-48
lines changed

14 files changed

+1480
-48
lines changed

.github/workflows/generate_prs.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ jobs:
5151
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
5252
with:
5353
persist-credentials: false
54-
- uses: cachix/install-nix-action@17fe5fb4a23ad6cbbe47d6b3f359611ad276644c # v31.4.0
54+
- uses: cachix/install-nix-action@f0fe604f8a612776892427721526b4c7cfb23aba # v31.4.1
5555
- name: Install Ansible
5656
env:
5757
DEBIAN_FRONTEND: noninteractive

.github/workflows/pr_pre-commit.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ on:
66

77
env:
88
HADOLINT_VERSION: "v2.12.0"
9-
PYTHON_VERSION: "3.12"
9+
PYTHON_VERSION: "3.13"
1010

1111
permissions: {}
1212

@@ -18,7 +18,7 @@ jobs:
1818
with:
1919
persist-credentials: false
2020
fetch-depth: 0
21-
- uses: stackabletech/actions/run-pre-commit@9aae2d1c14239021bfa33c041010f6fb7adec815 # v0.8.2
21+
- uses: stackabletech/actions/run-pre-commit@4483641a7e24057bd2ba51cb4c3f2f0010ad21b7 # v0.8.4
2222
with:
2323
python-version: ${{ env.PYTHON_VERSION }}
2424
hadolint: ${{ env.HADOLINT_VERSION }}

.pre-commit-config.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,14 +15,14 @@ repos:
1515
- id: detect-private-key
1616

1717
- repo: https://github.com/adrienverge/yamllint
18-
rev: 81e9f98ffd059efe8aa9c1b1a42e5cce61b640c6 # 1.35.1
18+
rev: 79a6b2b1392eaf49cdd32ac4f14be1a809bbd8f7 # 1.37.1
1919
hooks:
2020
- id: yamllint
2121
types: [text]
2222
files: \.(yml|yaml)(\.j2)*$
2323

2424
- repo: https://github.com/igorshubovych/markdownlint-cli
25-
rev: 586c3ea3f51230da42bab657c6a32e9e66c364f0 # 0.44.0
25+
rev: 192ad822316c3a22fb3d3cc8aa6eafa0b8488360 # 0.45.0
2626
hooks:
2727
- id: markdownlint
2828
types: [text]
@@ -38,7 +38,7 @@ repos:
3838
# If you do not, you will need to delete the cached ruff binary shown in the
3939
# error message
4040
- repo: https://github.com/astral-sh/ruff-pre-commit
41-
rev: 2c8dce6094fa2b4b668e74f694ca63ceffd38614 # 0.9.9
41+
rev: 0b19ef1fd6ad680ed7752d6daba883ce1265a6de # 0.12.2
4242
hooks:
4343
# Run the linter.
4444
- id: ruff

README.adoc

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,7 @@ To remove files or directories that already exist in the target repositories the
2929

3030
Anything that is listed here will be deleted from the target repositories.
3131

32-
NOTE: Deletion is the last step that is performed, so if there is an overlap between files existing in the template folder and this setting, the files would not be rolled out, since they'd get deleted before creting the pull request.
33-
32+
NOTE: Deletion is the last step that is performed, so if there is an overlap between files existing in the template folder and this setting, the files would not be rolled out, since they'd get deleted before creating the pull request.
3433

3534
=== Configuration
3635

config/versions.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
# IMPORTANT
33
# If you change the Rust toolchain version here, make sure to also change
44
# docker-images/ubi8-rust-builder/Dockerfile & docker-images/ubi9-rust-builder/Dockerfile
5-
rust_version: 1.85.0
5+
rust_version: 1.87.0
66

77
# This nightly version is only used for cargo fmt invocations, because we use nightly-only
88
# rustfmt config options in rustfmt.toml. The version should be kept in line with the version
@@ -22,11 +22,11 @@ hadolint_version: v2.12.0
2222
# IMPORTANT
2323
# If you change the Python version here, make sure to also change it in
2424
# .github/workflows/pr_pre-commit.yml
25-
python_version: 3.12
25+
python_version: 3.13
2626

2727
# This Nix version is used in the operators pre-commit workflow as they require
2828
# Nix to run some checks. Check for new versions here:
2929
# https://github.com/NixOS/nix/tags
3030
# Usually the latest version should just work and as such the version here can
3131
# be bumped without any constraints.
32-
nix_pkg_manager_version: 2.28.3
32+
nix_pkg_manager_version: 2.30.0

template/.github/workflows/build.yml.j2

Lines changed: 23 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -42,18 +42,18 @@ jobs:
4242
RUSTC_BOOTSTRAP: 1
4343
steps:
4444
- name: Install host dependencies
45-
uses: awalsh128/cache-apt-pkgs-action@5902b33ae29014e6ca012c5d8025d4346556bd40 # v1.4.3
45+
uses: awalsh128/cache-apt-pkgs-action@4c82c3ccdc1344ee11e9775dbdbdf43aa8a5614e # v1.5.1
4646
with:
4747
packages: protobuf-compiler krb5-user libkrb5-dev libclang-dev liblzma-dev libssl-dev pkg-config apt-transport-https
4848
version: ubuntu-latest
4949
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
5050
with:
5151
persist-credentials: false
5252
submodules: recursive
53-
- uses: dtolnay/rust-toolchain@56f84321dbccf38fb67ce29ab63e4754056677e0
53+
- uses: dtolnay/rust-toolchain@b3b07ba8b418998c39fb20f53e8b695cdcc8de1b
5454
with:
5555
toolchain: ${{ env.RUST_TOOLCHAIN_VERSION }}
56-
- uses: Swatinem/rust-cache@9d47c6ad4b02e050fd481d890b2ea34778fd09d6 # v2.7.8
56+
- uses: Swatinem/rust-cache@98c8021b550208e191a6a3145459bfc9fb29c4c0 # v2.8.0
5757
with:
5858
key: udeps
5959
cache-all-crates: "true"
@@ -114,7 +114,7 @@ jobs:
114114
with:
115115
persist-credentials: false
116116
submodules: recursive
117-
- uses: EmbarkStudios/cargo-deny-action@34899fc7ba81ca6268d5947a7a16b4649013fea1 # v2.0.11
117+
- uses: EmbarkStudios/cargo-deny-action@30f817c6f72275c6d54dc744fbca09ebc958599f # v2.0.12
118118
with:
119119
command: check ${{ matrix.checks }}
120120

@@ -126,7 +126,7 @@ jobs:
126126
with:
127127
persist-credentials: false
128128
submodules: recursive
129-
- uses: dtolnay/rust-toolchain@56f84321dbccf38fb67ce29ab63e4754056677e0
129+
- uses: dtolnay/rust-toolchain@b3b07ba8b418998c39fb20f53e8b695cdcc8de1b
130130
with:
131131
toolchain: ${{ env.RUST_NIGHTLY_TOOLCHAIN_VERSION }}
132132
components: rustfmt
@@ -139,19 +139,19 @@ jobs:
139139
runs-on: ubuntu-latest
140140
steps:
141141
- name: Install host dependencies
142-
uses: awalsh128/cache-apt-pkgs-action@5902b33ae29014e6ca012c5d8025d4346556bd40 # v1.4.3
142+
uses: awalsh128/cache-apt-pkgs-action@4c82c3ccdc1344ee11e9775dbdbdf43aa8a5614e # v1.5.1
143143
with:
144144
packages: protobuf-compiler krb5-user libkrb5-dev libclang-dev liblzma-dev libssl-dev pkg-config apt-transport-https
145145
version: ubuntu-latest
146146
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
147147
with:
148148
persist-credentials: false
149149
submodules: recursive
150-
- uses: dtolnay/rust-toolchain@56f84321dbccf38fb67ce29ab63e4754056677e0
150+
- uses: dtolnay/rust-toolchain@b3b07ba8b418998c39fb20f53e8b695cdcc8de1b
151151
with:
152152
toolchain: ${{ env.RUST_TOOLCHAIN_VERSION }}
153153
components: clippy
154-
- uses: Swatinem/rust-cache@9d47c6ad4b02e050fd481d890b2ea34778fd09d6 # v2.7.8
154+
- uses: Swatinem/rust-cache@98c8021b550208e191a6a3145459bfc9fb29c4c0 # v2.8.0
155155
with:
156156
key: clippy
157157
cache-all-crates: "true"
@@ -178,18 +178,18 @@ jobs:
178178
runs-on: ubuntu-latest
179179
steps:
180180
- name: Install host dependencies
181-
uses: awalsh128/cache-apt-pkgs-action@5902b33ae29014e6ca012c5d8025d4346556bd40 # v1.4.3
181+
uses: awalsh128/cache-apt-pkgs-action@4c82c3ccdc1344ee11e9775dbdbdf43aa8a5614e # v1.5.1
182182
with:
183183
packages: protobuf-compiler krb5-user libkrb5-dev libclang-dev liblzma-dev libssl-dev pkg-config apt-transport-https
184184
version: ubuntu-latest
185185
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
186186
with:
187187
submodules: recursive
188-
- uses: dtolnay/rust-toolchain@56f84321dbccf38fb67ce29ab63e4754056677e0
188+
- uses: dtolnay/rust-toolchain@b3b07ba8b418998c39fb20f53e8b695cdcc8de1b
189189
with:
190190
toolchain: ${{ env.RUST_TOOLCHAIN_VERSION }}
191191
components: rustfmt
192-
- uses: Swatinem/rust-cache@9d47c6ad4b02e050fd481d890b2ea34778fd09d6 # v2.7.8
192+
- uses: Swatinem/rust-cache@98c8021b550208e191a6a3145459bfc9fb29c4c0 # v2.8.0
193193
with:
194194
key: doc
195195
cache-all-crates: "true"
@@ -201,18 +201,18 @@ jobs:
201201
runs-on: ubuntu-latest
202202
steps:
203203
- name: Install host dependencies
204-
uses: awalsh128/cache-apt-pkgs-action@5902b33ae29014e6ca012c5d8025d4346556bd40 # v1.4.3
204+
uses: awalsh128/cache-apt-pkgs-action@4c82c3ccdc1344ee11e9775dbdbdf43aa8a5614e # v1.5.1
205205
with:
206206
packages: protobuf-compiler krb5-user libkrb5-dev libclang-dev liblzma-dev libssl-dev pkg-config apt-transport-https
207207
version: ubuntu-latest
208208
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
209209
with:
210210
persist-credentials: false
211211
submodules: recursive
212-
- uses: dtolnay/rust-toolchain@56f84321dbccf38fb67ce29ab63e4754056677e0
212+
- uses: dtolnay/rust-toolchain@b3b07ba8b418998c39fb20f53e8b695cdcc8de1b
213213
with:
214214
toolchain: ${{ env.RUST_TOOLCHAIN_VERSION }}
215-
- uses: Swatinem/rust-cache@9d47c6ad4b02e050fd481d890b2ea34778fd09d6 # v2.7.8
215+
- uses: Swatinem/rust-cache@98c8021b550208e191a6a3145459bfc9fb29c4c0 # v2.8.0
216216
with:
217217
key: test
218218
cache-all-crates: "true"
@@ -261,7 +261,7 @@ jobs:
261261
runs-on: ubuntu-latest
262262
steps:
263263
- name: Install host dependencies
264-
uses: awalsh128/cache-apt-pkgs-action@5902b33ae29014e6ca012c5d8025d4346556bd40 # v1.4.3
264+
uses: awalsh128/cache-apt-pkgs-action@4c82c3ccdc1344ee11e9775dbdbdf43aa8a5614e # v1.5.1
265265
with:
266266
packages: protobuf-compiler krb5-user libkrb5-dev libclang-dev liblzma-dev libssl-dev pkg-config apt-transport-https
267267
version: ubuntu-latest
@@ -274,10 +274,10 @@ jobs:
274274
with:
275275
version: v3.16.1
276276
- name: Set up cargo
277-
uses: dtolnay/rust-toolchain@56f84321dbccf38fb67ce29ab63e4754056677e0
277+
uses: dtolnay/rust-toolchain@b3b07ba8b418998c39fb20f53e8b695cdcc8de1b
278278
with:
279279
toolchain: ${{ env.RUST_TOOLCHAIN_VERSION }}
280-
- uses: Swatinem/rust-cache@9d47c6ad4b02e050fd481d890b2ea34778fd09d6 # v2.7.8
280+
- uses: Swatinem/rust-cache@98c8021b550208e191a6a3145459bfc9fb29c4c0 # v2.8.0
281281
with:
282282
key: charts
283283
cache-all-crates: "true"
@@ -332,16 +332,16 @@ jobs:
332332
IMAGE_TAG: ${{ steps.printtag.outputs.IMAGE_TAG }}
333333
steps:
334334
- name: Install host dependencies
335-
uses: awalsh128/cache-apt-pkgs-action@5902b33ae29014e6ca012c5d8025d4346556bd40 # v1.4.3
335+
uses: awalsh128/cache-apt-pkgs-action@4c82c3ccdc1344ee11e9775dbdbdf43aa8a5614e # v1.5.1
336336
with:
337337
packages: protobuf-compiler krb5-user libkrb5-dev libclang-dev liblzma-dev libssl-dev pkg-config apt-transport-https
338338
version: ${{ matrix.runner }}
339339
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
340340
with:
341341
persist-credentials: false
342342
submodules: recursive
343-
- uses: cachix/install-nix-action@17fe5fb4a23ad6cbbe47d6b3f359611ad276644c # v31.4.0
344-
- uses: dtolnay/rust-toolchain@56f84321dbccf38fb67ce29ab63e4754056677e0
343+
- uses: cachix/install-nix-action@f0fe604f8a612776892427721526b4c7cfb23aba # v31.4.1
344+
- uses: dtolnay/rust-toolchain@b3b07ba8b418998c39fb20f53e8b695cdcc8de1b
345345
with:
346346
toolchain: ${{ env.RUST_TOOLCHAIN_VERSION }}
347347
components: rustfmt
@@ -376,9 +376,9 @@ jobs:
376376

377377
# Recreate charts and publish charts and docker image.
378378
- name: Install cosign
379-
uses: sigstore/cosign-installer@3454372f43399081ed03b604cb2d021dabca52bb # v3.8.2
379+
uses: sigstore/cosign-installer@398d4b0eeef1380460a10c8013a76f728fb906ac # v3.9.1
380380
- name: Install syft
381-
uses: anchore/sbom-action/download-syft@e11c554f704a0b820cbf8c51673f6945e0731532 # v0.20.0
381+
uses: anchore/sbom-action/download-syft@cee1b8e05ae5b2593a75e197229729eabaa9f8ec # v0.20.2
382382
- name: Build Docker image and Helm chart
383383
run: |
384384
# Installing helm and yq on ubicloud-standard-8-arm only
@@ -421,7 +421,7 @@ jobs:
421421
OCI_REGISTRY_SDP_CHARTS_USERNAME: "robot$sdp-charts+github-action-build"
422422
steps:
423423
- name: Install cosign
424-
uses: sigstore/cosign-installer@3454372f43399081ed03b604cb2d021dabca52bb # v3.8.2
424+
uses: sigstore/cosign-installer@398d4b0eeef1380460a10c8013a76f728fb906ac # v3.9.1
425425
- name: Checkout
426426
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
427427
with:

template/.github/workflows/integration-test.yml

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ jobs:
8686

8787
- name: Run Integration Test
8888
id: test
89-
uses: stackabletech/actions/run-integration-test@5901c3b1455488820c4be367531e07c3c3e82538 # v0.4.0
89+
uses: stackabletech/actions/run-integration-test@4483641a7e24057bd2ba51cb4c3f2f0010ad21b7 # v0.8.4
9090
with:
9191
test-platform: ${{ env.TEST_PLATFORM }}-${{ env.TEST_ARCHITECTURE }}
9292
test-run: ${{ env.TEST_RUN }}
@@ -117,3 +117,21 @@ jobs:
117117
}
118118
]
119119
}
120+
# TODO: Update to version 2.1.0. This could look something like the following.
121+
# The workflow is currently not in use, testing that the new version still works imposes effort.
122+
# So I left it as a future exercise, but saved the current state.
123+
#
124+
# uses: slackapi/slack-github-action@b0fa283ad8fea605de13dc3f449259339835fc52 # v2.1.0
125+
# with:
126+
# method: chat.postMessage
127+
# token: ${{ secrets.SLACK_INTEGRATION_TEST_TOKEN }}
128+
# payload: |
129+
# channel: "C07UYJYSMSN" # notifications-integration-tests
130+
# text: "Integration Test *${{ github.repository }}* failed"
131+
# attachments:
132+
# - pretext: "Started at ${{ steps.test.outputs.start-time }}, failed at ${{ steps.test.outputs.end-time }}"
133+
# color: "#aa0000"
134+
# actions:
135+
# - type: button
136+
# text: Go to integration test run
137+
# url: "${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}"

template/.pre-commit-config.yaml.j2

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ repos:
3636
# If you do not, you will need to delete the cached ruff binary shown in the
3737
# error message
3838
- repo: https://github.com/astral-sh/ruff-pre-commit
39-
rev: d19233b89771be2d89273f163f5edc5a39bbc34a # 0.11.12
39+
rev: 0b19ef1fd6ad680ed7752d6daba883ce1265a6de # 0.12.2
4040
hooks:
4141
# Run the linter.
4242
- id: ruff-check

template/.readme/partials/borrowed/footer.md.j2.j2

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ These are the operators that are currently part of the Stackable Data Platform:
3636
* [Stackable Operator for Apache Hive](https://github.com/stackabletech/hive-operator)
3737
* [Stackable Operator for Apache Kafka](https://github.com/stackabletech/kafka-operator)
3838
* [Stackable Operator for Apache NiFi](https://github.com/stackabletech/nifi-operator)
39+
* [Stackable Operator for OpenSearch](https://github.com/stackabletech/opensearch-operator)
3940
* [Stackable Operator for Apache Spark](https://github.com/stackabletech/spark-k8s-operator)
4041
* [Stackable Operator for Apache Superset](https://github.com/stackabletech/superset-operator)
4142
* [Stackable Operator for Trino](https://github.com/stackabletech/trino-operator)

template/deploy/helm/[[operator]]/templates/deployment.yaml.j2

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,17 +43,38 @@ spec:
4343
- mountPath: /etc/stackable/{{ include "operator.appname" . }}/config-spec
4444
name: config-spec
4545
env:
46+
# The following env vars are passed as clap (think CLI) arguments to the operator.
47+
# They are picked up by clap using the structs defied in the operator.
48+
# (which is turn pulls in https://github.com/stackabletech/operator-rs/blob/main/crates/stackable-operator/src/cli.rs)
49+
# You can read there about the expected values and purposes.
50+
51+
# Sometimes products need to know the operator image, e.g. the opa-bundle-builder OPA
52+
# sidecar uses the operator image.
4653
- name: OPERATOR_IMAGE
4754
# Tilt can use annotations as image paths, but not env variables
4855
valueFrom:
4956
fieldRef:
5057
fieldPath: metadata.annotations['internal.stackable.tech/image']
58+
59+
# Namespace the operator Pod is running in, e.g. used to construct the conversion
60+
# webhook endpoint.
5161
- name: OPERATOR_NAMESPACE
5262
valueFrom:
5363
fieldRef:
5464
fieldPath: metadata.namespace
65+
66+
# The name of the Kubernetes Service that point to the operator Pod, e.g. used to
67+
# construct the conversion webhook endpoint.
5568
- name: OPERATOR_SERVICE_NAME
5669
value: {{ include "operator.fullname" . }}
70+
71+
# Operators need to know the node name they are running on, to e.g. discover the
72+
# Kubernetes domain name from the kubelet API.
73+
- name: KUBERNETES_NODE_NAME
74+
valueFrom:
75+
fieldRef:
76+
fieldPath: spec.nodeName
77+
5778
{{- if .Values.kubernetesClusterDomain }}
5879
- name: KUBERNETES_CLUSTER_DOMAIN
5980
value: {{ .Values.kubernetesClusterDomain | quote }}

0 commit comments

Comments
 (0)