Example config map for redis where the redis image name is customized as redis-test or redis-stage:
---
kind: ConfigMap
apiVersion: v1
metadata:
name: redis-config
namespace: default
data:
redis_ad: |-
| import boto3 | |
| import json | |
| import os | |
| import pprint | |
| import requests | |
| from datetime import datetime, timedelta | |
| from datadog_lambda.wrapper import datadog_lambda_wrapper | |
| from datadog_lambda.metric import lambda_metric |
Example config map for redis where the redis image name is customized as redis-test or redis-stage:
---
kind: ConfigMap
apiVersion: v1
metadata:
name: redis-config
namespace: default
data:
redis_ad: |-
| import time | |
| import json | |
| from faker import Factory | |
| fake = Factory.create() | |
| start_time = time.time() + 900 | |
| while time.time() < start_time: | |
| p = fake.profile() |
| import datetime | |
| import os | |
| import time | |
| import csv | |
| import requests | |
| import simplejson | |
| from datadog import initialize, api | |
| """ |
| import os | |
| import pprint | |
| import subprocess | |
| import random | |
| from checks import AgentCheck | |
| # for logging | |
| def log_parsed_output(output_list): | |
| with open(writepath, mode) as f: | |
| for i in output_list: |
Create a directory to house any custom integration yaml files for integrations running in other docker containers on this host. You can also extend or customize integration settings generated by auto discovery. Example:
mkdir /opt/datadog-agent-conf.d
touch /opt/datadog-agent-conf.d/jmx.yaml
| { | |
| "containerDefinitions": [ | |
| { | |
| "name": "datadog-agent", | |
| "image": "datadog/agent:latest", | |
| "cpu": 10, | |
| "memory": 256, | |
| "essential": true, | |
| "portMappings": [ | |
| { |
| """ | |
| Disclaimer | |
| These projects are not a part of Datadog's subscription services and are provided for example purposes only. | |
| They are NOT guaranteed to be bug free and are not production quality. | |
| If you choose to use to adapt them for use in a production environment, you do so at your own risk. | |
| """ | |
| import json | |
| import os | |
| import requests |