Skip to content

Commit

Permalink
Merge branch 'main' into tls_rotation_gateway
Browse files Browse the repository at this point in the history
  • Loading branch information
rubenvp8510 committed Jul 25, 2024
2 parents aa57ffa + 8449542 commit 0d0cfdb
Show file tree
Hide file tree
Showing 9 changed files with 124 additions and 45 deletions.
Original file line number Diff line number Diff line change
@@ -1,9 +1,3 @@
# The namespace is auto-deleted by chainsaw after the test run.
apiVersion: v1
kind: Namespace
metadata:
name: chainsaw-tls-mono-st
---
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
Expand Down
123 changes: 97 additions & 26 deletions tests/e2e-openshift/tls-monolithic-singletenant/01-assert.yaml
Original file line number Diff line number Diff line change
@@ -1,72 +1,119 @@
apiVersion: tempo.grafana.com/v1alpha1
kind: TempoMonolithic
metadata:
name: monolithic-cert
name: mono
namespace: chainsaw-tls-mono-st

---
apiVersion: apps/v1
kind: StatefulSet
metadata:
labels:
app.kubernetes.io/component: tempo
app.kubernetes.io/instance: monolithic-cert
app.kubernetes.io/instance: mono
app.kubernetes.io/managed-by: tempo-operator
app.kubernetes.io/name: tempo-monolithic
name: tempo-monolithic-st
name: tempo-mono
namespace: chainsaw-tls-mono-st
spec:
replicas: 1
selector:
matchLabels:
app.kubernetes.io/component: tempo
app.kubernetes.io/instance: monolithic-cert
app.kubernetes.io/instance: mono
app.kubernetes.io/managed-by: tempo-operator
app.kubernetes.io/name: tempo-monolithic
template:
metadata:
labels:
app.kubernetes.io/component: tempo
app.kubernetes.io/instance: monolithic-cert
app.kubernetes.io/instance: mono
app.kubernetes.io/managed-by: tempo-operator
app.kubernetes.io/name: tempo-monolithic
spec:
containers:
- name: tempo
- name: tempo-query
- name: tempo
volumeMounts:
- mountPath: /conf
name: tempo-conf
readOnly: true
- mountPath: /var/tempo
name: tempo-storage
- mountPath: /var/run/tls/receiver/grpc
name: tempo-mono-serving-cert
readOnly: true
- mountPath: /var/run/tls/receiver/http
name: tempo-mono-serving-cert
readOnly: true
- name: tempo-query
volumeMounts:
- mountPath: /conf
name: tempo-conf
readOnly: true
- mountPath: /tmp
name: tempo-query-tmp
- name: oauth-proxy
volumeMounts:
- mountPath: /etc/tls/private
name: mono-ui-oauth-proxy-tls
- mountPath: /etc/proxy/cookie/
name: tempo-mono-cookie-proxy
volumes:
- configMap:
defaultMode: 420
name: tempo-mono-config
name: tempo-conf
- emptyDir:
medium: Memory
sizeLimit: 2Gi
name: tempo-storage
- name: tempo-mono-serving-cert
secret:
defaultMode: 420
secretName: tempo-mono-serving-cert
- emptyDir: {}
name: tempo-query-tmp
- name: mono-ui-oauth-proxy-tls
secret:
defaultMode: 420
secretName: mono-ui-oauth-proxy-tls
- name: tempo-mono-cookie-proxy
secret:
defaultMode: 420
secretName: tempo-mono-cookie-proxy
status:
availableReplicas: 1
currentReplicas: 1
readyReplicas: 1
replicas: 1

---
apiVersion: v1
kind: Pod
metadata:
labels:
app.kubernetes.io/component: tempo
app.kubernetes.io/instance: monolithic-cert
app.kubernetes.io/managed-by: tempo-operator
app.kubernetes.io/name: tempo-monolithic
name: tempo-mono-0
namespace: chainsaw-tls-mono-st
status:
containerStatuses:
- name: tempo
ready: true
started: true
- name: tempo-query
ready: true
started: true
- name: oauth-proxy
ready: true
started: true
- name: tempo
ready: true
started: true
- name: tempo-query
ready: true
started: true
phase: Running

---
apiVersion: v1
kind: Service
metadata:
labels:
app.kubernetes.io/component: tempo
app.kubernetes.io/instance: mono-cert
app.kubernetes.io/instance: mono
app.kubernetes.io/managed-by: tempo-operator
app.kubernetes.io/name: tempo-monolithic
name: tempo-monolithic-cert
name: tempo-mono
namespace: chainsaw-tls-mono-st
spec:
ipFamilyPolicy: SingleStack
Expand All @@ -85,7 +132,7 @@ spec:
targetPort: otlp-http
selector:
app.kubernetes.io/component: tempo
app.kubernetes.io/instance: mono-cert
app.kubernetes.io/instance: mono
app.kubernetes.io/managed-by: tempo-operator
app.kubernetes.io/name: tempo-monolithic
---
Expand All @@ -94,10 +141,10 @@ kind: Service
metadata:
labels:
app.kubernetes.io/component: jaegerui
app.kubernetes.io/instance: monolithic-cert
app.kubernetes.io/instance: mono
app.kubernetes.io/managed-by: tempo-operator
app.kubernetes.io/name: tempo-monolithic
name: mono-cert-jaegerui
name: tempo-mono-jaegerui
namespace: chainsaw-tls-mono-st
spec:
ipFamilyPolicy: SingleStack
Expand All @@ -114,8 +161,32 @@ spec:
port: 16687
protocol: TCP
targetPort: jaeger-metrics
- name: oauth-proxy
port: 8443
protocol: TCP
targetPort: oauth-proxy
selector:
app.kubernetes.io/component: tempo
app.kubernetes.io/instance: monolithic-cert
app.kubernetes.io/instance: mono
app.kubernetes.io/managed-by: tempo-operator
app.kubernetes.io/name: tempo-monolithic

---
apiVersion: route.openshift.io/v1
kind: Route
metadata:
labels:
app.kubernetes.io/component: jaegerui
app.kubernetes.io/instance: mono
app.kubernetes.io/managed-by: tempo-operator
app.kubernetes.io/name: tempo-monolithic
name: tempo-mono-jaegerui
namespace: chainsaw-tls-mono-st
spec:
port:
targetPort: oauth-proxy
tls:
termination: reencrypt
to:
kind: Service
name: tempo-mono-jaegerui
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,4 @@ spec:
enabled: true
http:
tls:
enabled: true
enabled: true
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@

apiVersion: opentelemetry.io/v1alpha1
kind: OpenTelemetryCollector
metadata:
Expand Down Expand Up @@ -37,4 +36,3 @@ spec:
traces/http:
receivers: [otlp/http]
exporters: [otlphttp]
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: batch/v1
kind: Job
metadata:
name: generate-traces-grpc
namespace: tls-monolithic-singletenant
namespace: chainsaw-tls-mono-st
status:
conditions:
- status: "True"
Expand All @@ -12,7 +12,7 @@ apiVersion: batch/v1
kind: Job
metadata:
name: generate-traces-http
namespace: tls-monolithic-singletenant
namespace: chainsaw-tls-mono-st
status:
conditions:
- status: "True"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: batch/v1
kind: Job
metadata:
name: verify-traces-grpc
namespace: tls-monolithic-singletenant
namespace: chainsaw-tls-mono-st
status:
conditions:
- status: "True"
Expand All @@ -12,7 +12,7 @@ apiVersion: batch/v1
kind: Job
metadata:
name: verify-traces-http
namespace: tls-monolithic-singletenant
namespace: chainsaw-tls-mono-st
status:
conditions:
- status: "True"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: batch/v1
kind: Job
metadata:
name: verify-traces-grpc
namespace: tls-monolithic-singletenant
namespace: chainsaw-tls-mono-st
spec:
template:
spec:
Expand All @@ -15,7 +15,7 @@ spec:
- -c
args:
- |
curl -v -G http://tempo-simplest-query-frontend:16686/api/traces --data-urlencode "service=grpc" | tee /tmp/jaeger.out
curl -v -G http://tempo-mono-jaegerui:16686/api/traces --data-urlencode "service=grpc" | tee /tmp/jaeger.out
num_traces=$(jq ".data | length" /tmp/jaeger.out)
if [[ "$num_traces" -ne 10 ]]; then
echo && echo "The Jaeger API returned $num_traces instead of 10 traces."
Expand All @@ -27,7 +27,7 @@ apiVersion: batch/v1
kind: Job
metadata:
name: verify-traces-http
namespace: tls-monolithic-singletenant
namespace: chainsaw-tls-mono-st
spec:
template:
spec:
Expand All @@ -40,7 +40,7 @@ spec:
- -c
args:
- |
curl -v -G http://tempo-simplest-query-frontend:16686/api/traces --data-urlencode "service=http" | tee /tmp/jaeger.out
curl -v -G http://tempo-mono-jaegerui:16686/api/traces --data-urlencode "service=http" | tee /tmp/jaeger.out
num_traces=$(jq ".data | length" /tmp/jaeger.out)
if [[ "$num_traces" -ne 10 ]]; then
echo && echo "The Jaeger API returned $num_traces instead of 10 traces."
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@
apiVersion: chainsaw.kyverno.io/v1alpha1
kind: Test
metadata:
creationTimestamp: null
name: tls-singletenant
name: tls-singletenant-monolithic
spec:
namespace: chainsaw-tls-mono-st
steps:
- name: step-00
try:
Expand Down
16 changes: 16 additions & 0 deletions tests/e2e/monolithic-receivers-tls/01-assert.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,22 @@ spec:
app.kubernetes.io/name: tempo-monolithic
status:
readyReplicas: 1

---
apiVersion: v1
kind: Pod
metadata:
name: tempo-simplest-0
status:
containerStatuses:
- name: tempo
ready: true
started: true
- name: tempo-query
ready: true
started: true
phase: Running

---
apiVersion: v1
kind: Service
Expand Down

0 comments on commit 0d0cfdb

Please sign in to comment.