The open and composable observability and data visualization platform. Visualize metrics, logs, and traces from multiple sources like Prometheus, Loki, Elasticsearch, InfluxDB, Postgres and many more.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
grafana/scripts/drone/services/services.star

85 lines
2.6 KiB

"""
This module has functions for Drone services to be used in pipelines.
"""
load(
"scripts/drone/utils/images.star",
"images",
)
def integration_test_services_volumes():
return [
{"name": "postgres", "temp": {"medium": "memory"}},
{"name": "mysql57", "temp": {"medium": "memory"}},
{"name": "mysql80", "temp": {"medium": "memory"}},
]
def integration_test_services():
services = [
{
"name": "postgres",
"image": images["postgres_alpine"],
"environment": {
"POSTGRES_USER": "grafanatest",
"POSTGRES_PASSWORD": "grafanatest",
"POSTGRES_DB": "grafanatest",
"PGDATA": "/var/lib/postgresql/data/pgdata",
},
"volumes": [
{"name": "postgres", "path": "/var/lib/postgresql/data/pgdata"},
],
},
{
"name": "mysql57",
"image": images["mysql5"],
"environment": {
"MYSQL_ROOT_PASSWORD": "rootpass",
"MYSQL_DATABASE": "grafana_tests",
"MYSQL_USER": "grafana",
"MYSQL_PASSWORD": "password",
},
"volumes": [{"name": "mysql57", "path": "/var/lib/mysql"}],
"commands": ["docker-entrypoint.sh mysqld --character-set-server=utf8mb4 --collation-server=utf8mb4_unicode_ci"],
},
{
"name": "mysql80",
"image": images["mysql8"],
"environment": {
"MYSQL_ROOT_PASSWORD": "rootpass",
"MYSQL_DATABASE": "grafana_tests",
"MYSQL_USER": "grafana",
"MYSQL_PASSWORD": "password",
},
"volumes": [{"name": "mysql80", "path": "/var/lib/mysql"}],
"commands": ["docker-entrypoint.sh mysqld --default-authentication-plugin=mysql_native_password"],
},
{
"name": "mimir_backend",
"image": images["mimir"],
"environment": {},
"commands": ["/bin/mimir -target=backend"],
},
{
"name": "redis",
"image": images["redis_alpine"],
"environment": {},
},
{
"name": "memcached",
"image": images["memcached_alpine"],
"environment": {},
},
]
return services
def ldap_service():
return {
"name": "ldap",
"image": images["openldap"],
"environment": {
"LDAP_ADMIN_PASSWORD": "grafana",
"LDAP_DOMAIN": "grafana.org",
"SLAPD_ADDITIONAL_MODULES": "memberof",
},
}