Skip to content

Commit

Permalink
add specified latest tag, add operatorMasterImage.yaml, fix makefile,…
Browse files Browse the repository at this point in the history
… update docs
  • Loading branch information
hubeadmin committed Oct 1, 2020
1 parent f972a52 commit f608212
Show file tree
Hide file tree
Showing 5 changed files with 55 additions and 4 deletions.
9 changes: 8 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -77,10 +77,17 @@ cluster/cleanup: operator/stop
-kubectl delete deployment grafana-deployment -n ${NAMESPACE}
-kubectl delete namespace ${NAMESPACE}

## Deploy the latest tagged release
.PHONY: operator/deploy
operator/deploy: cluster/prepare/local
kubectl apply -f deploy/operator.yaml -n ${NAMESPACE}
@git checkout -- .
@git checkout -- deploy/cluster_roles/cluster_role_binding_grafana_operator.yaml

## Deploy the latest master image
.PHONY: operator/deploy/master
operator/deploy/master: cluster/prepare/local
kubectl apply -f deploy/operatorMasterImage.yaml -n ${NAMESPACE}
@git checkout -- deploy/cluster_roles/cluster_role_binding_grafana_operator.yaml

.PHONY: operator/stop
operator/stop:
Expand Down
2 changes: 1 addition & 1 deletion deploy/operator.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ spec:
serviceAccountName: grafana-operator
containers:
- name: grafana-operator
image: quay.io/integreatly/grafana-operator:latest
image: quay.io/integreatly/grafana-operator:v3.5.0
ports:
- containerPort: 60000
name: metrics
Expand Down
39 changes: 39 additions & 0 deletions deploy/operatorMasterImage.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: grafana-operator
spec:
replicas: 1
selector:
matchLabels:
name: grafana-operator
strategy:
type: Recreate
template:
metadata:
labels:
name: grafana-operator
spec:
serviceAccountName: grafana-operator
containers:
- name: grafana-operator
image: quay.io/integreatly/grafana-operator:master
ports:
- containerPort: 60000
name: metrics
command:
- grafana-operator
imagePullPolicy: Always
env:
- name: TEMPLATE_PATH
value: /usr/local/bin/templates
- name: WATCH_NAMESPACE
valueFrom:
fieldRef:
fieldPath: metadata.namespace
- name: POD_NAME
valueFrom:
fieldRef:
fieldPath: metadata.name
- name: OPERATOR_NAME
value: "grafana-operator"
7 changes: 6 additions & 1 deletion documentation/deploy_grafana.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,12 @@ The first step is to install the Grafana operator to a namespace in your cluster
There are two options for this procedure, automated via Ansible, or manually running kubectl/oc commands.

### Deploy an example grafana instance and operator
Run `make operator/deploy` This uses the default operator.yaml and Grafana.yaml resources found in the `deploy` directories and subdirectories.

Run `make operator/deploy` To deploy the latest released image of the operator, This uses the default operator.yaml and Grafana.yaml resources found in the `deploy` directories and subdirectories.

***Warning:*** The following make recipe uses the latest master Image. It should only be used for testing, for production please use the tagged releases.

Run `make operator/deploy/master` to deploy the image from the master branch of the operator.

### Automated Procedure

Expand Down
2 changes: 1 addition & 1 deletion grafonnet-lib
Submodule grafonnet-lib updated 37 files
+0 −3 examples/k8s_cluster_summary_compiled.json
+0 −13 grafonnet/alertlist.libsonnet
+0 −47 grafonnet/bar_gauge_panel.libsonnet
+7 −7 grafonnet/cloudwatch.libsonnet
+0 −27 grafonnet/dashboard.libsonnet
+9 −9 grafonnet/dashlist.libsonnet
+0 −10 grafonnet/elasticsearch.libsonnet
+20 −20 grafonnet/gauge_panel.libsonnet
+0 −1 grafonnet/grafana.libsonnet
+50 −58 grafonnet/graph_panel.libsonnet
+5 −5 grafonnet/graphite.libsonnet
+36 −40 grafonnet/heatmap_panel.libsonnet
+10 −13 grafonnet/influxdb.libsonnet
+0 −12 grafonnet/link.libsonnet
+9 −11 grafonnet/log_panel.libsonnet
+0 −5 grafonnet/loki.libsonnet
+15 −18 grafonnet/pie_chart_panel.libsonnet
+2 −2 grafonnet/pluginlist.libsonnet
+0 −14 grafonnet/prometheus.libsonnet
+0 −12 grafonnet/row.libsonnet
+0 −43 grafonnet/singlestat.libsonnet
+0 −6 grafonnet/sql.libsonnet
+24 −24 grafonnet/stat_panel.libsonnet
+11 −23 grafonnet/table_panel.libsonnet
+9 −118 grafonnet/template.libsonnet
+0 −19 grafonnet/text.libsonnet
+0 −5 grafonnet/timepicker.libsonnet
+1 −2 tests/prometheus/test.jsonnet
+0 −1 tests/prometheus/test_compiled.json
+0 −1 tests/table_panel/test.jsonnet
+0 −11 tests/table_panel/test_compiled.json
+0 −15 tests/template/custom.jsonnet
+0 −71 tests/template/custom_compiled.json
+1 −3 tests/template/interval.jsonnet
+1 −31 tests/template/interval_compiled.json
+0 −4 tests/text/test.jsonnet
+0 −14 tests/text/test_compiled.json

0 comments on commit f608212

Please sign in to comment.