From 02f2c2ccc9464a5e1e45c612d9075397ac4f9f34 Mon Sep 17 00:00:00 2001 From: Gerd Aschemann Date: Mon, 17 Feb 2020 21:37:49 +0100 Subject: [PATCH] Separate spring profiles for "static" environments cf. dukecon/dukecon_server#102 --- modules/dukecon/puppet/docker-compose.erb | 4 ++-- modules/dukecon/puppet/init.pp | 2 ++ 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/modules/dukecon/puppet/docker-compose.erb b/modules/dukecon/puppet/docker-compose.erb index 67f73de..dff5602 100644 --- a/modules/dukecon/puppet/docker-compose.erb +++ b/modules/dukecon/puppet/docker-compose.erb @@ -48,7 +48,7 @@ services: environment: - "JAVA_OPTS=-Xms1024m -Xmx2048m -XX:+ExitOnOutOfMemoryError -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=/opt/dukecon/heapdumps" - "SPRING_CONFIG_ADDITIONAL_LOCATION=/opt/dukecon/config" - - "SPRING_PROFILES_ACTIVE=<%= @dukecon_instance_name %>,postgresql,docker" + - "SPRING_PROFILES_ACTIVE=<%= @dukecon_instance_spring_profiles %>,postgresql,docker" networks: - default - monitoring @@ -74,7 +74,7 @@ services: environment: - "JAVA_OPTS=-XX:+ExitOnOutOfMemoryError -XX:+HeapDumpOnOutOfMemoryError -XX:HeapDumpPath=/opt/dukecon/heapdumps" - "SPRING_CONFIG_ADDITIONAL_LOCATION=/opt/dukecon/config" - - "SPRING_PROFILES_ACTIVE=<%= @dukecon_instance_name %>,postgresql,docker" + - "SPRING_PROFILES_ACTIVE=<%= @dukecon_instance_spring_profiles %>,postgresql,docker" networks: - default - monitoring diff --git a/modules/dukecon/puppet/init.pp b/modules/dukecon/puppet/init.pp index c5d7659..f41c93a 100644 --- a/modules/dukecon/puppet/init.pp +++ b/modules/dukecon/puppet/init.pp @@ -13,6 +13,7 @@ { 'name' => 'latest', 'label' => 'latest', + 'spring_profiles' => 'latest', 'server_port' => '9050', 'internal_port' => '9051', 'postgres_port' => '9052', @@ -41,6 +42,7 @@ $dukecon_docker_instances.each |$docker_instance| { $dukecon_instance_name = $docker_instance['name'] $dukecon_instance_label = $docker_instance['label'] + $dukecon_instance_spring_profiles = $docker_instance['spring_profiles'] $dukecon_instance_server_port = $docker_instance['server_port'] $dukecon_instance_internal_port = $docker_instance['internal_port'] $dukecon_instance_postgres_port = $docker_instance['postgres_port']