diff --git a/testdata/images/bundles/test-operator/v1.0.0/manifests/script.configmap.yaml b/testdata/images/bundles/test-operator/v1.0.0/manifests/script.configmap.yaml new file mode 100644 index 000000000..a0404835a --- /dev/null +++ b/testdata/images/bundles/test-operator/v1.0.0/manifests/script.configmap.yaml @@ -0,0 +1,11 @@ +apiVersion: v1 +kind: ConfigMap +metadata: + name: httpd-script +data: + httpd.sh: | + #!/bin/sh + echo true > /var/www/started + echo true > /var/www/ready + echo true > /var/www/live + exec httpd -f -h /var/www -p 80 diff --git a/testdata/images/bundles/test-operator/v1.0.0/manifests/testoperator.clusterserviceversion.yaml b/testdata/images/bundles/test-operator/v1.0.0/manifests/testoperator.clusterserviceversion.yaml index 4cb49d5fe..ae6fadca9 100644 --- a/testdata/images/bundles/test-operator/v1.0.0/manifests/testoperator.clusterserviceversion.yaml +++ b/testdata/images/bundles/test-operator/v1.0.0/manifests/testoperator.clusterserviceversion.yaml @@ -56,16 +56,40 @@ spec: app: olme2etest spec: terminationGracePeriodSeconds: 0 + volumes: + - name: scripts + configMap: + name: httpd-script + defaultMode: 0755 containers: - - name: busybox + - name: busybox-httpd-container image: busybox:1.36 - command: - - 'sleep' - - '1000' - securityContext: - runAsUser: 1000 - runAsNonRoot: true - serviceAccountName: simple-bundle-manager + command: ["/scripts/httpd.sh"] + ports: + - containerPort: 80 + volumeMounts: + - name: scripts + mountPath: /scripts + readOnly: true + startupProbe: + httpGet: + path: /started + port: 80 + failureThreshold: 30 + periodSeconds: 10 + livenessProbe: + httpGet: + path: /live + port: 80 + failureThreshold: 1 + periodSeconds: 2 + readinessProbe: + httpGet: + path: /ready + port: 80 + initialDelaySeconds: 1 + periodSeconds: 1 + serviceAccountName: simple-bundle-manager clusterPermissions: - rules: - apiGroups: diff --git a/testdata/images/bundles/test-operator/v1.2.0/manifests/script.configmap.yaml b/testdata/images/bundles/test-operator/v1.2.0/manifests/script.configmap.yaml new file mode 100644 index 000000000..6270e4ad7 --- /dev/null +++ b/testdata/images/bundles/test-operator/v1.2.0/manifests/script.configmap.yaml @@ -0,0 +1,12 @@ +apiVersion: v1 +kind: ConfigMap +metadata: + name: httpd-script +data: + httpd.sh: | + #!/bin/sh + echo "Version 1.2.0" + echo true > /var/www/started + echo true > /var/www/ready + echo true > /var/www/live + exec httpd -f -h /var/www -p 80 diff --git a/testdata/images/bundles/test-operator/v1.2.0/manifests/testoperator.clusterserviceversion.yaml b/testdata/images/bundles/test-operator/v1.2.0/manifests/testoperator.clusterserviceversion.yaml index 90621bc6d..6fc91adf3 100644 --- a/testdata/images/bundles/test-operator/v1.2.0/manifests/testoperator.clusterserviceversion.yaml +++ b/testdata/images/bundles/test-operator/v1.2.0/manifests/testoperator.clusterserviceversion.yaml @@ -56,15 +56,39 @@ spec: app: olme2etest spec: terminationGracePeriodSeconds: 0 + volumes: + - name: scripts + configMap: + name: httpd-script + defaultMode: 0755 containers: - - name: busybox + - name: busybox-httpd-container image: busybox:1.37 - command: - - 'sleep' - - '1000' - securityContext: - runAsUser: 1000 - runAsNonRoot: true + command: ["/scripts/httpd.sh"] + ports: + - containerPort: 80 + volumeMounts: + - name: scripts + mountPath: /scripts + readOnly: true + startupProbe: + httpGet: + path: /started + port: 80 + failureThreshold: 30 + periodSeconds: 10 + livenessProbe: + httpGet: + path: /live + port: 80 + failureThreshold: 1 + periodSeconds: 2 + readinessProbe: + httpGet: + path: /ready + port: 80 + initialDelaySeconds: 1 + periodSeconds: 1 serviceAccountName: simple-bundle-manager clusterPermissions: - rules: @@ -125,7 +149,7 @@ spec: verbs: - create - patch - serviceAccountName: simple-bundle-manager + serviceAccountName: simple-bundle-manager strategy: deployment installModes: - supported: false