summaryrefslogtreecommitdiffstats
path: root/setup/projects/services/vars/mysql.yml
diff options
context:
space:
mode:
authorSuren A. Chilingaryan <csa@suren.me>2020-08-20 04:06:35 +0200
committerSuren A. Chilingaryan <csa@suren.me>2020-08-20 04:06:35 +0200
commit0b972f0816408fc696e75fd55de5cd160d6d7ccc (patch)
treebb6d12968add8c9d7c450fe82fb24f103935feb1 /setup/projects/services/vars/mysql.yml
parent159fbcff7917d60372d780509a866384e8dc5c86 (diff)
downloadands-0b972f0816408fc696e75fd55de5cd160d6d7ccc.tar.gz
ands-0b972f0816408fc696e75fd55de5cd160d6d7ccc.tar.bz2
ands-0b972f0816408fc696e75fd55de5cd160d6d7ccc.tar.xz
ands-0b972f0816408fc696e75fd55de5cd160d6d7ccc.zip
Add MySQL service (for Michele and other low-volume users)
Diffstat (limited to 'setup/projects/services/vars/mysql.yml')
-rw-r--r--setup/projects/services/vars/mysql.yml21
1 files changed, 21 insertions, 0 deletions
diff --git a/setup/projects/services/vars/mysql.yml b/setup/projects/services/vars/mysql.yml
new file mode 100644
index 0000000..c174b61
--- /dev/null
+++ b/setup/projects/services/vars/mysql.yml
@@ -0,0 +1,21 @@
+mysql:
+ pods:
+ mysql:
+ service: { ports: [ 3306 ] }
+ groups: [ "services_mysql" ]
+ images:
+ - stream: "openshift/mysql:5.7"
+ env:
+ - { name: "MYSQL_USER", value: "ipe" }
+ - { name: "MYSQL_PASSWORD", value: "secret@mysql/ipe-password" }
+ - { name: "MYSQL_ROOT_PASSWORD", value: "secret@mysql/root-password" }
+ - { name: "MYSQL_DATABASE", value: "test" }
+ - { name: "MYSQL_PMA_PASSWORD", value: "secret@mysql/pma-password" }
+ - { name: "MYSQL_MAX_CONNECTIONS", value: "500" }
+ mappings:
+ - { name: "db", path: "mysql", mount: "/var/lib/mysql/data" }
+ resources: { request: { cpu: 500m, mem: 1Gi }, limit: { cpu: 2000m, mem: 4Gi } }
+ probes:
+ - { port: 3306 }
+# - { type: "liveness", port: 3306 }
+# - { type: "readiness", command: [/bin/sh, -i, -c, MYSQL_PWD="$MYSQL_PASSWORD" mysql -h 127.0.0.1 -u $MYSQL_USER -D $MYSQL_DATABASE, -e 'SELECT 1'] }