Skip to content

Commit

Permalink
Enable submission worker metrics and fix node exporter metrics (Cloud…
Browse files Browse the repository at this point in the history
  • Loading branch information
Ram81 authored Oct 19, 2021
1 parent ba8ca06 commit d19d7ca
Show file tree
Hide file tree
Showing 4 changed files with 31 additions and 2 deletions.
2 changes: 2 additions & 0 deletions apps/challenges/aws_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,8 @@
"RDS_PORT": settings.DATABASES["default"]["PORT"],
"SECRET_KEY": settings.SECRET_KEY,
"SENTRY_URL": os.environ.get("SENTRY_URL"),
"STATSD_ENDPOINT": os.environ.get("STATSD_ENDPOINT"),
"STATSD_PORT": os.environ.get("STATSD_PORT"),
}

VPC_DICT = {
Expand Down
25 changes: 24 additions & 1 deletion apps/challenges/task_definitions.py
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,14 @@
{{
"name": "AWS_SES_REGION_ENDPOINT",
"value": "{AWS_SES_REGION_ENDPOINT}"
}},
{{
"name": "STATSD_ENDPOINT",
"value: "{STATSD_ENDPOINT}"
}},
{{
"name": "STATSD_PORT",
"value: "{STATSD_PORT}"
}}
],
"workingDirectory": "/code",
Expand Down Expand Up @@ -346,6 +354,14 @@
{{
"name": "AWS_SES_REGION_ENDPOINT",
"value": "{AWS_SES_REGION_ENDPOINT}"
}},
{{
"name": "STATSD_ENDPOINT",
"value: "{STATSD_ENDPOINT}"
}},
{{
"name": "STATSD_PORT",
"value: "{STATSD_PORT}"
}}
],
"workingDirectory": "/code",
Expand Down Expand Up @@ -414,10 +430,17 @@
"name": "EVALAI_DNS",
"value": "{EVALAI_DNS}"
}},
{{
"name": "EFS_ID",
"value": "{EFS_ID}"
}},
{{
"name": "STATSD_ENDPOINT",
"value: "{STATSD_ENDPOINT}"
}},
{{
"name": "STATSD_PORT",
"value: "{STATSD_PORT}"
}}
],
Expand Down
4 changes: 4 additions & 0 deletions docker/prod/nodejs/nginx_production.conf
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@ upstream django_app {
server django:8000 fail_timeout=0;
}

upstream node_exporter {
server node_exporter:9100 fail_timeout=0;
}

server {
server_name evalapi.cloudcv.org evalai.cloudcv.org;
listen 80;
Expand Down
2 changes: 1 addition & 1 deletion monitoring/prometheus/rules.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ groups:
- name: Instance-Status
rules:
- alert: InstanceDown
expr: up == 0
expr: up{job="node_exporter"} == 0
for: 5m
annotations:
title: "Instance(s) Down"
Expand Down

0 comments on commit d19d7ca

Please sign in to comment.