Initial commit to rework cc-docker repo into development environment

This commit is contained in:
Christoph Kluge
2022-06-01 11:27:50 +02:00
parent cb420305ab
commit 7d259dd1ba
13 changed files with 308 additions and 215 deletions

View File

@@ -0,0 +1,29 @@
services:
nats:
container_name: cc-nats
image: nats:alpine
ports:
- "4222:4222"
- "8222:8222"
cc-metric-store:
container_name: cc-metric-store
build:
context: ./cc-metric-store
ports:
- "8084:8084"
volumes:
- ${DATADIR}/cc-metric-store:/data
depends_on:
- nats
openldap:
container_name: cc-ldap
image: osixia/openldap:1.5.0
command: --copy-service --loglevel debug
environment:
- LDAP_ADMIN_PASSWORD=${LDAP_ADMIN_PASSWORD}
- LDAP_ORGANISATION=${LDAP_ORGANISATION}
- LDAP_DOMAIN=${LDAP_DOMAIN}
volumes:
- ${DATADIR}/ldap:/container/service/slapd/assets/config/bootstrap/ldif/custom

View File

@@ -0,0 +1,29 @@
services:
influxdb:
container_name: cc-influxdb
image: influxdb
command: ["--reporting-disabled"]
environment:
DOCKER_INFLUXDB_INIT_MODE: setup
DOCKER_INFLUXDB_INIT_USERNAME: symfony
DOCKER_INFLUXDB_INIT_PASSWORD: ${INFLUXDB_PASSWORD}
DOCKER_INFLUXDB_INIT_ORG: ${INFLUXDB_ORG}
DOCKER_INFLUXDB_INIT_BUCKET: ${INFLUXDB_BUCKET}
DOCKER_INFLUXDB_INIT_RETENTION: 100w
DOCKER_INFLUXDB_INIT_ADMIN_TOKEN: ${INFLUXDB_ADMIN_TOKEN}
ports:
- "127.0.0.1:${INFLUXDB_PORT}:8086"
volumes:
- ${DATADIR}/influxdb/data:/var/lib/influxdb2
- ${DATADIR}/influxdb/config:/etc/influxdb2
openldap:
container_name: cc-ldap
image: osixia/openldap:1.5.0
command: --copy-service --loglevel debug
environment:
- LDAP_ADMIN_PASSWORD=${LDAP_ADMIN_PASSWORD}
- LDAP_ORGANISATION=${LDAP_ORGANISATION}
- LDAP_DOMAIN=${LDAP_DOMAIN}
volumes:
- ${DATADIR}/ldap:/container/service/slapd/assets/config/bootstrap/ldif/custom

View File

@@ -0,0 +1,29 @@
services:
db:
container_name: cc-db
image: mysql:8.0.22
command: ["--default-authentication-plugin=mysql_native_password"]
environment:
MYSQL_ROOT_PASSWORD: ${MYSQL_ROOT_PASSWORD}
MYSQL_DATABASE: ${MYSQL_DATABASE}
MYSQL_USER: ${MYSQL_USER}
MYSQL_PASSWORD: ${MYSQL_PASSWORD}
ports:
- "127.0.0.1:3336:3306"
volumes:
- ${DATADIR}/sql-init:/docker-entrypoint-initdb.d
# - ${DATADIR}/sqldata:/var/lib/mysql
cap_add:
- SYS_NICE
phpmyadmin:
container_name: cc-phpmyadmin
image: phpmyadmin
environment:
- PMA_HOST=cc-db
- PMA_USER=root
- PMA_PASSWORD=${MYSQL_ROOT_PASSWORD}
ports:
- "127.0.0.1:${PHPMYADMIN_PORT}:80"
depends_on:
- db

15
templates/env.ccms Normal file
View File

@@ -0,0 +1,15 @@
########################################################################
# CCBACKEND DEVEL DOCKER SETTINGS FOR LDAP (CCMS-Devel)
########################################################################
#########################################
# LDAP
########################################################################
LDAP_ADMIN_PASSWORD=mashup
LDAP_ORGANISATION=NHR@FAU
LDAP_DOMAIN=rrze.uni-erlangen.de
########################################################################
# INTERNAL SETTINGS
########################################################################
DATADIR=./data

26
templates/env.influxdb Normal file
View File

@@ -0,0 +1,26 @@
########################################################################
# CCBACKEND DEVEL DOCKER SETTINGS FOR INFLUXDB AND LDAP
########################################################################
########################################################################
# INFLUXDB
########################################################################
INFLUXDB_PORT=8086
INFLUXDB_PASSWORD=2RPJpkrduLgkpfQCpcBe1jYv
INFLUXDB_ADMIN_TOKEN=egLfcf7fx0FESqFYU3RpAAbj
INFLUXDB_ORG=ClusterCockpit
INFLUXDB_BUCKET=ClusterCockpit/data
# Whether or not to check SSL Cert in Symfony Client, Default: false
INFLUXDB_SSL=false
########################################################################
# LDAP
########################################################################
LDAP_ADMIN_PASSWORD=mashup
LDAP_ORGANISATION=NHR@FAU
LDAP_DOMAIN=rrze.uni-erlangen.de
########################################################################
# INTERNAL SETTINGS
########################################################################
DATADIR=./data

17
templates/env.mysql Normal file
View File

@@ -0,0 +1,17 @@
########################################################################
# ADDITIONAL ENV VARIABLES FOR MYSQL AND PHPMYADMIN CONTAINERS
########################################################################
########################################################################
# MySQL
# The SQL port is not exposed outside the container
########################################################################
MYSQL_ROOT_PASSWORD=root
MYSQL_DATABASE=ClusterCockpit
MYSQL_USER=symfony
MYSQL_PASSWORD=symfony
########################################################################
# PHPMyAdmin
########################################################################
PHPMYADMIN_PORT=8081