-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[WFLY-15849] OpenTelemetry QS on OpenShift #872
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
9 changes: 9 additions & 0 deletions
9
...enshift-ci/build-root/scripts/qs-overrides/opentelemetry-tracing/overridable-functions.sh
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
function runPostHelmInstallCommands() { | ||
echo "Applying all OpenTelemetry Collector resources" | ||
oc apply -f charts/opentelemetry-collector.yaml | ||
} | ||
|
||
function cleanPrerequisites() { | ||
echo "Deleting all OpenTelemetry Collector resources" | ||
oc delete -f charts/opentelemetry-collector.yaml | ||
} |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
104 changes: 104 additions & 0 deletions
104
opentelemetry-tracing/charts/opentelemetry-collector.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,104 @@ | ||
--- | ||
apiVersion: v1 | ||
kind: ConfigMap | ||
metadata: | ||
name: collector-config | ||
data: | ||
collector.yml: | | ||
receivers: | ||
otlp: | ||
protocols: | ||
grpc: | ||
http: | ||
processors: | ||
exporters: | ||
logging: | ||
verbosity: detailed | ||
service: | ||
pipelines: | ||
traces: | ||
receivers: [otlp] | ||
processors: [] | ||
exporters: [logging] | ||
--- | ||
apiVersion: apps/v1 | ||
kind: Deployment | ||
metadata: | ||
name: opentelemetrycollector | ||
spec: | ||
replicas: 1 | ||
selector: | ||
matchLabels: | ||
app.kubernetes.io/name: opentelemetrycollector | ||
template: | ||
metadata: | ||
labels: | ||
app.kubernetes.io/name: opentelemetrycollector | ||
spec: | ||
containers: | ||
- name: otelcol | ||
args: | ||
- --config=/conf/collector.yml | ||
image: otel/opentelemetry-collector:0.89.0 | ||
volumeMounts: | ||
- mountPath: /conf | ||
name: collector-config | ||
volumes: | ||
- configMap: | ||
items: | ||
- key: collector.yml | ||
path: collector.yml | ||
name: collector-config | ||
name: collector-config | ||
--- | ||
apiVersion: v1 | ||
kind: Service | ||
metadata: | ||
name: opentelemetrycollector | ||
spec: | ||
ports: | ||
- name: otlp-grpc | ||
port: 4317 | ||
protocol: TCP | ||
targetPort: 4317 | ||
- name: otlp-http | ||
port: 4318 | ||
protocol: TCP | ||
targetPort: 4318 | ||
selector: | ||
app.kubernetes.io/name: opentelemetrycollector | ||
type: ClusterIP | ||
--- | ||
apiVersion: route.openshift.io/v1 | ||
kind: Route | ||
metadata: | ||
name: otelcol-otlp-grpc | ||
labels: | ||
app.kubernetes.io/name: microprofile | ||
spec: | ||
port: | ||
targetPort: otlp-grpc | ||
to: | ||
kind: Service | ||
name: opentelemetrycollector | ||
tls: | ||
termination: edge | ||
insecureEdgeTerminationPolicy: Redirect | ||
wildcardPolicy: None | ||
--- | ||
apiVersion: route.openshift.io/v1 | ||
kind: Route | ||
metadata: | ||
name: otelcol-otlp-http | ||
labels: | ||
app.kubernetes.io/name: microprofile | ||
spec: | ||
port: | ||
targetPort: otlp-http | ||
to: | ||
kind: Service | ||
name: opentelemetrycollector | ||
tls: | ||
termination: edge | ||
insecureEdgeTerminationPolicy: Redirect | ||
wildcardPolicy: None |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
=== Install OpenTelemetry Collector on OpenShift | ||
|
||
The functionality of this quickstart depends on a running instance of the https://opentelemetry.io/docs/collector/[OpenTelemetry Collector]. | ||
|
||
To deploy and configure the OpenTelemetry Collector, you will need to apply a set of configurations to your OpenShift cluster, to configure the OpenTelemetry Collector as well as any external routes needed: | ||
|
||
[source,options="nowrap",subs="+attributes"] | ||
---- | ||
include::charts/opentelemetry-collector.yaml[] | ||
---- | ||
|
||
To make things simpler, you can find these commands in `charts/opentelemetry-collector.yaml`, and to apply them run the following command in your terminal: | ||
|
||
[source] | ||
---- | ||
$ oc apply -f charts/opentelemetry-collector.yaml | ||
---- | ||
|
||
[NOTE] | ||
==== | ||
When done with the quickstart, the `oc delete -f charts/opentelemetry-collector.yaml` command may be used to revert the applied changes. | ||
==== | ||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
[[undeploy_helm]] | ||
== Undeploy the {ProductShortName} Source-to-Image (S2I) Quickstart from OpenShift with Helm Charts | ||
|
||
[source,options="nowrap",subs="+attributes"] | ||
---- | ||
$ helm uninstall {helm-app-name} | ||
---- |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this step should as additional step in undeploy
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The proper solution for this requires an additional extension point for shared-docs, similar to helm-install-prerequisites, and that will affect all QS so I have created https://issues.redhat.com/browse/WFLY-18986 to deliver it (and more general shared improvements). For now the uninstall is referenced as a note at https://github.com/wildfly/quickstart/pull/872/files#diff-437f0901bdbc94e992d4b6b75f355240a557c4879683f47d27dad1c51f27dc4aR19