Skip to content

Commit

Permalink
Attempt grafana
Browse files Browse the repository at this point in the history
  • Loading branch information
PhilWindle committed Jul 24, 2024
1 parent 06f527a commit 229ebb2
Show file tree
Hide file tree
Showing 7 changed files with 1,117 additions and 11 deletions.
18 changes: 17 additions & 1 deletion .github/workflows/metrics-deploys.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ env:
GIT_COMMIT: ${{ github.sha }}
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
GRAFANA_CLIENT_ID: ${{ secrets.GRAFANA_CLIENT_ID }}
GRAFANA_CLIENT_SECRET: ${{ secrets.GRAFANA_CLIENT_SECRET }}
# TF Vars
TF_VAR_DOCKERHUB_ACCOUNT: aztecprotocol

Expand Down Expand Up @@ -52,6 +54,14 @@ jobs:
docker build -t aztecprotocol/aztec-prometheus .
docker push aztecprotocol/aztec-prometheus
- name: Build & push grafana
working-directory: ./metrics/grafana
if: steps.check_metrics_changes.outputs.result == 'true'
run: |
./replace_secrets.sh $GRAFANA_CLIENT_ID $GRAFANA_CLIENT_SECRET
docker build -t aztecprotocol/aztec-grafana .
docker push aztecprotocol/aztec-grafana
terraform_deploy:
runs-on: ubuntu-latest
needs: build
Expand All @@ -72,8 +82,14 @@ jobs:
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: eu-west-2

- name: Deploy mainnet fork
- name: Deploy prometheus
working-directory: ./metrics/prometheus/terraform
run: |
terraform init -input=false -backend-config="key=aztec-prometheus"
terraform apply -input=false -auto-approve
- name: Deploy grafana
working-directory: ./metrics/grafana/terraform
run: |
terraform init -input=false -backend-config="key=aztec-grafana"
terraform apply -input=false -auto-approve
4 changes: 4 additions & 0 deletions metrics/grafana/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
FROM grafana/grafana:9.3.2
COPY grafana.ini /etc/grafana/grafana.ini
USER root
EXPOSE 80
Loading

0 comments on commit 229ebb2

Please sign in to comment.