Skip to content

Commit e6fcd39

Browse files
Merge pull request #55703 from michaelryanpeter/osdocs-5181-osdk-add-osdk-version-to-common-attributes
OSDOCS#5181: Add OSDK version to common attributes and clean up
2 parents 5b96db1 + 20058ec commit e6fcd39

16 files changed

+15
-66
lines changed

_attributes/common-attributes.adoc

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -162,4 +162,8 @@ endif::[]
162162
//endif::[]
163163
// logical volume manager storage
164164
:lvms-first: Logical volume manager storage (LVM Storage)
165-
:lvms: LVM Storage
165+
:lvms: LVM Storage
166+
//Operator SDK version
167+
:osdk_ver: 1.25.4
168+
//Operator SDK version that shipped with the previous OCP 4.x release
169+
:osdk_ver_n1: 1.22.0
File renamed without changes.
File renamed without changes.
File renamed without changes.

modules/osdk-bundle-validate-run.adoc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ where:
3333

3434
<bundle_registry>:: Specifies the registry where the bundle is hosted, such as `quay.io/example`.
3535
<bundle_image_name>:: Specifies the name of the bundle image, such as `memcached-operator`.
36-
<tag>:: Specifies the tag of the bundle image, such as `v1.22.0`.
36+
<tag>:: Specifies the tag of the bundle image, such as `v{osdk_ver}`.
3737
+
3838
[NOTE]
3939
====
@@ -51,7 +51,7 @@ $ operator-sdk bundle validate \
5151
+
5252
where:
5353

54-
<bundle_dir_or_image>:: Specifies the local bundle directory or remote bundle image, such as `~/projects/memcached` or `quay.io/example/memcached-operator:v1.22`.
54+
<bundle_dir_or_image>:: Specifies the local bundle directory or remote bundle image, such as `~/projects/memcached` or `quay.io/example/memcached-operator:v{osdk_ver}`.
5555
<test_label>:: Specifies the name of the validator you want to run, such as `name=good-practices`.
5656
+
5757
.Example output

modules/osdk-installing-cli-linux-macos.adoc

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@
33
// * cli_reference/osdk/cli-osdk-install.adoc
44
// * operators/operator_sdk/osdk-installing-cli.adoc
55

6-
:osdk_ver: v1.25.4
7-
86
:_content-type: PROCEDURE
97
[id="osdk-installing-cli-linux-macos_{context}"]
108
= Installing the Operator SDK CLI
@@ -31,7 +29,7 @@ endif::[]
3129
+
3230
[source,terminal,subs="attributes+"]
3331
----
34-
$ tar xvf operator-sdk-{osdk_ver}-ocp-linux-x86_64.tar.gz
32+
$ tar xvf operator-sdk-v{osdk_ver}-ocp-linux-x86_64.tar.gz
3533
----
3634

3735
. Make the file executable:
@@ -70,7 +68,5 @@ $ operator-sdk version
7068
.Example output
7169
[source,terminal,subs="attributes+"]
7270
----
73-
operator-sdk version: "{osdk_ver}-ocp", ...
71+
operator-sdk version: "v{osdk_ver}-ocp", ...
7472
----
75-
76-
:!osdk_ver:

modules/osdk-scorecard-config.adoc

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,6 @@
22
//
33
// * operators/operator_sdk/osdk-scorecard.adoc
44

5-
:osdk_ver: v1.25.4
6-
75
[id="osdk-scorecard-config_{context}"]
86
= Scorecard configuration
97

@@ -28,14 +26,14 @@ metadata:
2826
stages:
2927
- parallel: true
3028
tests:
31-
- image: quay.io/operator-framework/scorecard-test:{osdk_ver}
29+
- image: quay.io/operator-framework/scorecard-test:v{osdk_ver}
3230
entrypoint:
3331
- scorecard-test
3432
- basic-check-spec
3533
labels:
3634
suite: basic
3735
test: basic-check-spec-test
38-
- image: quay.io/operator-framework/scorecard-test:{osdk_ver}
36+
- image: quay.io/operator-framework/scorecard-test:v{osdk_ver}
3937
entrypoint:
4038
- scorecard-test
4139
- olm-bundle-validation
@@ -61,4 +59,3 @@ following fields of the scorecard configuration file define the test as follows:
6159
|Scorecard-defined or custom labels that select which tests to run
6260
|===
6361

64-
:!osdk_ver:

modules/osdk-scorecard-output.adoc

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,6 @@
22
//
33
// * operators/operator_sdk/osdk-scorecard.adoc
44

5-
:osdk_ver: v1.25.4
6-
75
[id="osdk-scorecard-output_{context}"]
86
= Scorecard output
97

@@ -22,7 +20,7 @@ The `--output` flag for the `scorecard` command specifies the scorecard results
2220
"kind": "Test",
2321
"apiVersion": "scorecard.operatorframework.io/v1alpha3",
2422
"spec": {
25-
"image": "quay.io/operator-framework/scorecard-test:{osdk_ver}",
23+
"image": "quay.io/operator-framework/scorecard-test:v{osdk_ver}",
2624
"entrypoint": [
2725
"scorecard-test",
2826
"olm-bundle-validation"
@@ -53,7 +51,7 @@ The `--output` flag for the `scorecard` command specifies the scorecard results
5351
[source,text,subs="attributes+"]
5452
----
5553
--------------------------------------------------------------------------------
56-
Image: quay.io/operator-framework/scorecard-test:{osdk_ver}
54+
Image: quay.io/operator-framework/scorecard-test:v{osdk_ver}
5755
Entrypoint: [scorecard-test olm-bundle-validation]
5856
Labels:
5957
"suite":"olm"
@@ -74,5 +72,3 @@ Results:
7472
====
7573
The output format spec matches the link:https://pkg.go.dev/github.com/operator-framework/api/pkg/apis/scorecard/v1alpha3#Test[`Test`] type layout.
7674
====
77-
78-
:!osdk_ver:

modules/osdk-scorecard-parallel.adoc

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,6 @@
22
//
33
// * operators/operator_sdk/osdk-scorecard.adoc
44

5-
:osdk_ver: v1.25.4
6-
75
:_content-type: PROCEDURE
86
[id="osdk-scorecard-parallel_{context}"]
97
= Enabling parallel testing
@@ -30,14 +28,14 @@ stages:
3028
- entrypoint:
3129
- scorecard-test
3230
- basic-check-spec
33-
image: quay.io/operator-framework/scorecard-test:{osdk_ver}
31+
image: quay.io/operator-framework/scorecard-test:v{osdk_ver}
3432
labels:
3533
suite: basic
3634
test: basic-check-spec-test
3735
- entrypoint:
3836
- scorecard-test
3937
- olm-bundle-validation
40-
image: quay.io/operator-framework/scorecard-test:{osdk_ver}
38+
image: quay.io/operator-framework/scorecard-test:v{osdk_ver}
4139
labels:
4240
suite: olm
4341
test: olm-bundle-validation-test
@@ -46,4 +44,3 @@ stages:
4644
+
4745
All tests in a parallel stage are executed simultaneously, and scorecard waits for all of them to finish before proceding to the next stage. This can make your tests run much faster.
4846
49-
:!osdk_ver:

modules/osdk-updating-v1220-to-v1250.adoc

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -27,9 +27,6 @@ ifeval::["{context}" == "osdk-java-updating-projects"]
2727
:type: Java
2828
endif::[]
2929

30-
:osdk_ver: v1.25.4
31-
:osdk_ver_n1: v1.22.0
32-
3330
:_content-type: PROCEDURE
3431
[id="osdk-upgrading-projects_{context}"]
3532
= Updating {type}-based Operator projects for Operator SDK {osdk_ver}
@@ -312,9 +309,6 @@ $ go mod tidy
312309
----
313310
endif::[]
314311
315-
:!osdk_ver:
316-
:!osdk_ver_n1:
317-
318312
ifeval::["{context}" == "osdk-golang-updating-projects"]
319313
:!golang:
320314
:!type:

0 commit comments

Comments
 (0)