-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Example to start Grafana and add the Jaeger/Prometheus as data sources to Grafana. We also provide an example dashboard that enables the user to visualize the Service Weaver generated metrics. This can be used as a starting point to create more advanced dashboards for Service Weaver applications.
- Loading branch information
Showing
3 changed files
with
119 additions
and
48 deletions.
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
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,77 @@ | ||
# Copyright 2023 Google LLC | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
# Grafana Deployment | ||
apiVersion: apps/v1 | ||
kind: Deployment | ||
metadata: | ||
name: grafana | ||
spec: | ||
replicas: 1 | ||
selector: | ||
matchLabels: | ||
app: grafana | ||
template: | ||
metadata: | ||
labels: | ||
app: grafana | ||
spec: | ||
containers: | ||
- name: grafana | ||
image: grafana/grafana:latest | ||
ports: | ||
- containerPort: 3000 | ||
volumeMounts: | ||
- mountPath: /etc/grafana/provisioning/datasources/grafana.yaml | ||
name: grafana-config | ||
subPath: grafana.yaml | ||
volumes: | ||
- name: grafana-config | ||
configMap: | ||
name: grafana-config | ||
|
||
--- | ||
|
||
# Grafana Service | ||
apiVersion: v1 | ||
kind: Service | ||
metadata: | ||
name: grafana | ||
spec: | ||
ports: | ||
- name: ui-port | ||
port: 80 | ||
targetPort: 3000 | ||
protocol: TCP | ||
selector: | ||
app: grafana | ||
|
||
--- | ||
|
||
# Store grafana.yaml in a ConfigMap. | ||
apiVersion: v1 | ||
kind: ConfigMap | ||
metadata: | ||
name: grafana-config | ||
data: | ||
grafana.yaml: | | ||
apiVersion: 1 | ||
datasources: | ||
- name: Jaeger | ||
type: jaeger | ||
url: http://jaeger:16686 | ||
- name: Prometheus | ||
type: prometheus | ||
url: http://prometheus:80 |
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