9
9
10
10
env :
11
11
GO_VERSION : 1.22
12
+ OPERATOR_SDK_VERSION : v1.37.0
12
13
IMG : ttl.sh/securesign/secure-sign-operator-${{github.run_number}}:1h
13
14
BUNDLE_IMG : ttl.sh/securesign/bundle-secure-sign-${{github.run_number}}:1h
14
15
CATALOG_IMG : ttl.sh/securesign/catalog-${{github.run_number}}:1h
@@ -205,7 +206,7 @@ jobs:
205
206
run : podman load -i /tmp/operator-oci.tar
206
207
207
208
- name : Install Cluster
208
- uses : ./.github/workflows/ actions/kind-cluster
209
+ uses : ./.github/actions/kind-cluster
209
210
with :
210
211
config : ./ci/config.yaml
211
212
prometheus : ' true'
@@ -286,7 +287,7 @@ jobs:
286
287
podman load -i /tmp/catalog-oci.tar
287
288
288
289
- name : Install Cluster
289
- uses : ./.github/workflows/ actions/kind-cluster
290
+ uses : ./.github/actions/kind-cluster
290
291
with :
291
292
config : ./ci/config.yaml
292
293
prometheus : ' true'
@@ -356,7 +357,7 @@ jobs:
356
357
run : podman load -i /tmp/operator-oci.tar
357
358
358
359
- name : Install Cluster
359
- uses : ./.github/workflows/ actions/kind-cluster
360
+ uses : ./.github/actions/kind-cluster
360
361
with :
361
362
config : ./ci/config.yaml
362
363
@@ -382,18 +383,17 @@ jobs:
382
383
383
384
test-e2e :
384
385
name : Execute securesign/sigstore-e2e
385
- runs-on : ubuntu-20.04
386
+ runs-on : ubuntu-latest
386
387
needs :
387
- - build-fbc
388
+ - build-operator
388
389
steps :
389
- - name : Free Disk Space (Ubuntu)
390
- uses : jlumbroso/free-disk-space@main
391
- with :
392
- tool-cache : true
393
390
- name : Checkout source
394
391
uses : actions/checkout@v4
392
+ - name : Checkout test source repository
393
+ uses : actions/checkout@v4
395
394
with :
396
395
repository : " securesign/sigstore-e2e"
396
+ path : e2e
397
397
398
398
- name : Install Go
399
399
uses : actions/setup-go@v5
@@ -421,35 +421,56 @@ jobs:
421
421
- name : Load images
422
422
run : |
423
423
podman load -i /tmp/operator-oci.tar
424
- podman load -i /tmp/bundle-oci.tar
425
- podman load -i /tmp/catalog-oci.tar
426
424
427
425
- name : Install Cluster
428
- uses : ./.github/workflows/actions/kind-cluster
426
+ id : kind
427
+ uses : ./.github/actions/kind-cluster
429
428
with :
430
429
config : ./ci/config.yaml
431
430
keycloak : ' true'
432
431
olm : ' true'
432
+ prometheus : ' true'
433
433
434
434
- name : Add service hosts to /etc/hosts
435
435
run : |
436
436
sudo echo "127.0.0.1 fulcio-server.local tuf.local rekor-server.local rekor-search-ui.local cli-server.local" | sudo tee -a /etc/hosts
437
437
438
- - name : Install operator
439
- run :
440
-
441
- - name : Run tests
438
+ - name : Deploy operator container
442
439
env :
443
- TEST_MANAGER_IMAGE : ${{ env.IMG }}
444
440
OPENSHIFT : false
445
- run : make install && go test ./test/e2e/... -tags=custom_install -p 1 -timeout 20m
441
+ run : make deploy
446
442
447
- - name : Archive test artifacts
448
- uses : actions/upload-artifact@v4
449
- if : always()
450
- with :
451
- name : test-custom-install
452
- path : test/**/k8s-dump-*.tar.gz
443
+ - name : Wait for operator to be ready
444
+ run : |
445
+ kubectl wait --for=condition=available deployment/rhtas-operator-controller-manager --timeout=120s -n openshift-rhtas-operator
446
+
447
+ - name : Install securesign
448
+ run : |
449
+ sed -i 's#https://your-oidc-issuer-url#${{ steps.kind.outputs.oidc_url }}#' config/samples/rhtas_v1alpha1_securesign.yaml
450
+ sed -i 's#rhtas.redhat.com/metrics: "true"#rhtas.redhat.com/metrics: "false"#' config/samples/rhtas_v1alpha1_securesign.yaml
451
+ kubectl create ns test
452
+ kubectl create -f config/samples/rhtas_v1alpha1_securesign.yaml -n test
453
+ sleep 1
454
+ kubectl wait --for=condition=Ready securesign/securesign-sample -n test
455
+
456
+ - name : Run tests
457
+ run : |
458
+ export SIGSTORE_OIDC_ISSUER=${{ steps.kind.outputs.oidc_url }}
459
+ export FULCIO_URL=$(kubectl get securesign -o jsonpath='{.items[0].status.fulcio.url}' -n test)
460
+ export REKOR_URL=$(kubectl get securesign -o jsonpath='{.items[0].status.rekor.url}' -n test)
461
+ export TUF_URL=$(kubectl get securesign -o jsonpath='{.items[0].status.tuf.url}' -n test)
462
+ export TSA_URL=$(kubectl get securesign -o jsonpath='{.items[0].status.tsa.url}' -n test)
463
+
464
+ export CLI_STRATEGY=cli_server
465
+ export CLI_SERVER_URL="http://cli-server.local"
466
+
467
+ cd e2e
468
+ go test -v ./test/...
469
+
470
+ - name : dump the logs of the operator
471
+ run : |
472
+ kubectl logs -n openshift-rhtas-operator deployment/rhtas-operator-controller-manager
473
+ if : failure()
453
474
454
475
test-eks :
455
476
name : Test EKS deployment
0 commit comments