diff --git a/cluster-scope/base/core/namespaces/opentelemetry/kustomization.yaml b/cluster-scope/base/core/namespaces/opentelemetry/kustomization.yaml new file mode 100644 index 00000000..48ef36e5 --- /dev/null +++ b/cluster-scope/base/core/namespaces/opentelemetry/kustomization.yaml @@ -0,0 +1,4 @@ +apiVersion: kustomize.config.k8s.io/v1beta1 +kind: Kustomization +resources: + - namespace.yaml diff --git a/cluster-scope/base/core/namespaces/opentelemetry/namespace.yaml b/cluster-scope/base/core/namespaces/opentelemetry/namespace.yaml new file mode 100644 index 00000000..1d342b73 --- /dev/null +++ b/cluster-scope/base/core/namespaces/opentelemetry/namespace.yaml @@ -0,0 +1,5 @@ +apiVersion: v1 +kind: Namespace +metadata: + name: opentelemetry +spec: {} diff --git a/cluster-scope/bundles/opentelemetry/kustomization.yaml b/cluster-scope/bundles/opentelemetry/kustomization.yaml new file mode 100644 index 00000000..2297dc7d --- /dev/null +++ b/cluster-scope/bundles/opentelemetry/kustomization.yaml @@ -0,0 +1,6 @@ +apiVersion: kustomize.config.k8s.io/v1beta1 +kind: Kustomization +commonLabels: + nerc.mghpcc.org/bundle: opentelemetry +resources: +- ../../base/core/namespaces/opentelemetry diff --git a/cluster-scope/overlays/nerc-ocp-obs/kustomization.yaml b/cluster-scope/overlays/nerc-ocp-obs/kustomization.yaml index 6f7bcb57..2a88f0f0 100644 --- a/cluster-scope/overlays/nerc-ocp-obs/kustomization.yaml +++ b/cluster-scope/overlays/nerc-ocp-obs/kustomization.yaml @@ -15,6 +15,7 @@ resources: - ../../bundles/prom-keycloak-proxy - ../../bundles/zookeeper - ../../bundles/solr +- ../../bundles/opentelemetry - ../../base/core/namespaces/openshift-gitops - ../../base/core/namespaces/dex - ../../base/rbac.authorization.k8s.io/clusterroles/allow-edit-rbac diff --git a/opentelemetry/base/opentelemetry-collector.yaml b/opentelemetry/base/opentelemetry-collector.yaml new file mode 100644 index 00000000..19d07507 --- /dev/null +++ b/opentelemetry/base/opentelemetry-collector.yaml @@ -0,0 +1,25 @@ +apiVersion: opentelemetry.io/v1alpha1 +kind: OpenTelemetryCollector +metadata: + name: opentelemetry-collector + namespace: opentelemetry +spec: + mode: deployment + config: | + exporters: + otlp: + endpoint: tempo-ingester: + tls: + ca_file: ca.pem + cert_file: cert.pem + key_file: key.pem + insecure: false + insecure_skip_verify: false + reload_interval: 1h + server_name_override: + headers: + X-Scope-OrgID: "dev" + service: + pipelines: + traces: + exporters: [otlp] diff --git a/opentelemetry/overlays/nerc-ocp-obs/externalsecrets/patch-opentelemetry-admin-credentials.yaml b/opentelemetry/overlays/nerc-ocp-obs/externalsecrets/patch-opentelemetry-admin-credentials.yaml new file mode 100644 index 00000000..c0a6a04c --- /dev/null +++ b/opentelemetry/overlays/nerc-ocp-obs/externalsecrets/patch-opentelemetry-admin-credentials.yaml @@ -0,0 +1,9 @@ +apiVersion: external-secrets.io/v1beta1 +kind: ExternalSecret +metadata: + name: opentelemetry-admin-credentials + namespace: opentelemetry +spec: + dataFrom: + - extract: + key: nerc/nerc-ocp-obs/ai-telemetry/opentelemetry