PROVISION UID
This commit is contained in:
@@ -10,7 +10,7 @@ services:
|
||||
- ./writable:/var/www/html/writable:Z
|
||||
- ./apache_log:/var/log/apache2:Z
|
||||
environment:
|
||||
- PROVISION_UID=PROVISION_UID
|
||||
- PROVISION_UID=PROVISION_UID_REPLACE
|
||||
# - APACHE_RUN_USER=1000
|
||||
# - APACHE_RUN_GROUP=1000
|
||||
networks:
|
||||
|
||||
@@ -10,7 +10,7 @@ services:
|
||||
- ./writable:/var/www/html/writable:Z
|
||||
- ./apache_log:/var/log/apache2:Z
|
||||
environment:
|
||||
- PROVISION_UID=PROVISION_UID
|
||||
- PROVISION_UID=PROVISION_UID_REPLACE
|
||||
# - APACHE_RUN_USER=1000
|
||||
# - APACHE_RUN_GROUP=1000
|
||||
networks:
|
||||
|
||||
@@ -13,7 +13,7 @@ services:
|
||||
WORDPRESS_DB_USER: CNT_DB_NAME
|
||||
WORDPRESS_DB_PASSWORD: CNT_DB_PASS
|
||||
WORDPRESS_DB_NAME: CNT_DB_NAME
|
||||
PROVISION_UID: PROVISION_UID
|
||||
PROVISION_UID: PROVISION_UID_REPLACE
|
||||
networks:
|
||||
- wpsite
|
||||
|
||||
|
||||
@@ -13,7 +13,7 @@ services:
|
||||
WORDPRESS_DB_USER: CNT_DB_NAME
|
||||
WORDPRESS_DB_PASSWORD: CNT_DB_PASS
|
||||
WORDPRESS_DB_NAME: CNT_DB_NAME
|
||||
PROVISION_UID: PROVISION_UID
|
||||
PROVISION_UID: PROVISION_UID_REPLACE
|
||||
networks:
|
||||
- wpsite
|
||||
|
||||
|
||||
@@ -13,7 +13,7 @@ services:
|
||||
WORDPRESS_DB_USER: CNT_DB_NAME
|
||||
WORDPRESS_DB_PASSWORD: CNT_DB_PASS
|
||||
WORDPRESS_DB_NAME: CNT_DB_NAME
|
||||
PROVISION_UID: PROVISION_UID
|
||||
PROVISION_UID: PROVISION_UID_REPLACE
|
||||
networks:
|
||||
- wpsite
|
||||
|
||||
|
||||
@@ -176,6 +176,7 @@ class Provision extends BaseController
|
||||
$composer_template_contents = str_replace("CNT_DB_NAME", $ContainerName, $composer_template_contents);
|
||||
$composer_template_contents = str_replace("CNT_DB_PASS", $provisionUID, $composer_template_contents);
|
||||
$composer_template_contents = str_replace("CNT_DB_DATA", '172.16.4.96:3307', $composer_template_contents);
|
||||
$composer_template_contents = str_replace("PROVISION_UID_REPLACE", $provisionUID, $composer_template_contents);
|
||||
|
||||
//Save to the specific path
|
||||
$destination_composer_path = $ansible_folder . "/parts/" . $provisionUID . "/docker-compose.yml";
|
||||
@@ -369,7 +370,7 @@ class Provision extends BaseController
|
||||
$composer_template_contents = str_replace("CNT_DB_NAME", $ContainerName, $composer_template_contents);
|
||||
$composer_template_contents = str_replace("CNT_DB_PASS", $provisionUID, $composer_template_contents);
|
||||
$composer_template_contents = str_replace("CNT_DB_DATA", '172.16.4.96:3307', $composer_template_contents);
|
||||
|
||||
$composer_template_contents = str_replace("PROVISION_UID_REPLACE", $provisionUID, $composer_template_contents);
|
||||
//Save to the specific path
|
||||
$composerFile = fopen($destination_composer_path, "w") or die("Unable to open file!");
|
||||
fwrite($composerFile, $composer_template_contents);
|
||||
|
||||
Reference in New Issue
Block a user