File tree Expand file tree Collapse file tree 2 files changed +19
-6
lines changed Expand file tree Collapse file tree 2 files changed +19
-6
lines changed Original file line number Diff line number Diff line change 99# Dockerfile: https://github.com/GoogleCloudPlatform/marketplace-testrunner/blob/master/Dockerfile
1010FROM python:alpine
1111
12- RUN apk add curl patch
12+ RUN apk add curl patch bash
1313RUN pip3 install cram
14- RUN curl -L https://github.com/stern/stern/releases/download/v1.19.0/stern_1.19.0_linux_amd64.tar.gz | tar xz -C /tmp \
15- && mv /tmp/stern_1.19.0_linux_amd64/stern /usr/local/bin \
16- && curl -L https://storage.googleapis.com/kubernetes-release/release/v1.19.6/bin/linux/amd64/kubectl --output-dir /usr/local/bin -O \
14+ RUN curl -L https://storage.googleapis.com/kubernetes-release/release/v1.19.6/bin/linux/amd64/kubectl --output-dir /usr/local/bin -O \
1715 && chmod 755 /usr/local/bin/kubectl
1816
1917WORKDIR /opt
@@ -24,4 +22,4 @@ ENV NAMESPACE=test
2422# We don't use "kubectl logs" because we need to know to which container each
2523# logs comes from. Also, stern follows logs and never returns, so we do the
2624# pause trick.
27- CMD ["sh" , "-c" , "cram smoke-test.t || (stern -A -l app.kubernetes.io/name=jetstack-secure-gcm & (sleep 5; exit 1)) " ]
25+ CMD ["sh" , "-c" , "cram smoke-test.t" ]
Original file line number Diff line number Diff line change @@ -7,7 +7,22 @@ test suite. This image is used in a Job in data-test. mpdev verify detects the
77presence of this Job thanks to the annotation
88 " marketplace.cloud.google.com/verification: test"
99
10- First, let us create a self-signed Issuer and a Certificate. This is a good way
10+ Let's make sure the cert-manager API is actually ready. We do 2 >/ dev/ null due to
11+ the fact that this command outputs an unknown number of lines , which is
12+ something I don't know how to express in cram syntax.
13+
14+ $ timeout 5 m bash -c " until kubectl apply --dry-run=server -f- <<<$'kind: Issuer\n apiVersion: cert-manager.io/v1\n metadata:\n name: a\n spec:\n selfSigned: { } ' 2>/dev/null >&2; do sleep 10s; done"
15+ $ kubectl apply -- dry-run= server -f- << EOF
16+ > kind: Issuer
17+ > apiVersion: cert-manager. io/ v1
18+ > metadata:
19+ > name : a
20+ > spec:
21+ > selfSigned: {}
22+ > EOF
23+ issuer. cert-manager. io/ a created (server dry run )
24+
25+ Let us create a self-signed Issuer and a Certificate. This is a good way
1126to spot webhook misconfigurations.
1227
1328 $ kubectl apply -n $ {NAMESPACE} -f - << EOF
You can’t perform that action at this time.
0 commit comments