diff --git a/README.md b/README.md index 877dec2..bf4cedb 100644 --- a/README.md +++ b/README.md @@ -92,7 +92,7 @@ Which configuration is used is specified by environment variables which must be set. The environment variables are: -- *OS_CONFIG*: the configuration to use (like "standalone" or "standalone-sql") --- *OPENSIM_CONFIGKEY*: (optional) the password for extracting secrets in .crypt files +-- *OS_CONFIGKEY*: (optional) the password for extracting secrets in .crypt files The container starts the script `/home/opensim/bootOpenSim.sh` which runs configuration scripts and then starts the simulator. There are other scripts @@ -172,7 +172,7 @@ container. Once the Docker image is built, it can be run with a command like: ``` -OS_CONFIG=standalone OPENSIM_CONFIGKEY=secretPassword ./run-opensim.sh +OS_CONFIG=standalone OS_CONFIGKEY=secretPassword ./run-opensim.sh ``` Once started, a `docker ps` will show something like: diff --git a/image-ncg/config-standalone/os-secrets b/image-ncg/config-standalone/os-secrets index 7c75b4e..fb75487 100644 --- a/image-ncg/config-standalone/os-secrets +++ b/image-ncg/config-standalone/os-secrets @@ -4,18 +4,17 @@ # The configuration files look for the file 'os-secrets.crypt' and, when # found, runs 'ccrypt' using the password from the environment variable -# "OPENSIM_CONFIGKEY". So, edit this file and do: +# "OS_CONFIGKEY". So, edit this file and do: # cp os-secrets tempFile # -# ccrypt -e -E "OPENSIM_CONFIGKEY" < tempFile > os-secrets.crypt +# ccrypt -e -E "OS_CONFIGKEY" < tempFile > os-secrets.crypt # rm tempFile # or (exposing the key in the bash history): # ccrypt -e -K thekey < os-secrets > os-secrets.crypt # # Later, if you need to review the passwords, decrypt the file with: -# ccrypt -d -E "OPENSIM_CONFIGKEY" < os-secrets.crypt +# ccrypt -d -E "OS_CONFIGKEY" < os-secrets.crypt -# If this next variable is defined, MYSQL is configured export MYSQL_ROOT_PASSWORD=unknownStuff export MARIADB_ROOT_PASSWORD=unknownStuff export MYSQL_DB_HOST=dbservice diff --git a/image-ncg/config-standalone/scripts/setEnvironment.sh b/image-ncg/config-standalone/scripts/setEnvironment.sh index a3f1956..430254e 100755 --- a/image-ncg/config-standalone/scripts/setEnvironment.sh +++ b/image-ncg/config-standalone/scripts/setEnvironment.sh @@ -11,11 +11,11 @@ cd "$OPENSIMCONFIG" # See if we have encrypted secrets unset HAVE_SECRETS -if [[ ! -z "$OPENSIM_CONFIGKEY" ]] ; then +if [[ ! -z "$OS_CONFIGKEY" ]] ; then for secretsFile in $OPENSIMCONFIG/os-secrets.crypt ; do if [[ -e "$secretsFile" ]] ; then echo "opensim-docker: setEnvironment.sh: have secrets file \"{$secretsFile}\"" - source <(ccrypt -c -E OPENSIM_CONFIGKEY "$secretsFile") + source <(ccrypt -c -E OS_CONFIGKEY "$secretsFile") HAVE_SECRETS=yes break; else diff --git a/image-opensim-herbal3d/config-osgrid/os-secrets b/image-opensim-herbal3d/config-osgrid/os-secrets index 7c75b4e..fb75487 100644 --- a/image-opensim-herbal3d/config-osgrid/os-secrets +++ b/image-opensim-herbal3d/config-osgrid/os-secrets @@ -4,18 +4,17 @@ # The configuration files look for the file 'os-secrets.crypt' and, when # found, runs 'ccrypt' using the password from the environment variable -# "OPENSIM_CONFIGKEY". So, edit this file and do: +# "OS_CONFIGKEY". So, edit this file and do: # cp os-secrets tempFile # -# ccrypt -e -E "OPENSIM_CONFIGKEY" < tempFile > os-secrets.crypt +# ccrypt -e -E "OS_CONFIGKEY" < tempFile > os-secrets.crypt # rm tempFile # or (exposing the key in the bash history): # ccrypt -e -K thekey < os-secrets > os-secrets.crypt # # Later, if you need to review the passwords, decrypt the file with: -# ccrypt -d -E "OPENSIM_CONFIGKEY" < os-secrets.crypt +# ccrypt -d -E "OS_CONFIGKEY" < os-secrets.crypt -# If this next variable is defined, MYSQL is configured export MYSQL_ROOT_PASSWORD=unknownStuff export MARIADB_ROOT_PASSWORD=unknownStuff export MYSQL_DB_HOST=dbservice diff --git a/image-opensim-herbal3d/config-osgrid/scripts/setEnvironment.sh b/image-opensim-herbal3d/config-osgrid/scripts/setEnvironment.sh index a3f1956..430254e 100755 --- a/image-opensim-herbal3d/config-osgrid/scripts/setEnvironment.sh +++ b/image-opensim-herbal3d/config-osgrid/scripts/setEnvironment.sh @@ -11,11 +11,11 @@ cd "$OPENSIMCONFIG" # See if we have encrypted secrets unset HAVE_SECRETS -if [[ ! -z "$OPENSIM_CONFIGKEY" ]] ; then +if [[ ! -z "$OS_CONFIGKEY" ]] ; then for secretsFile in $OPENSIMCONFIG/os-secrets.crypt ; do if [[ -e "$secretsFile" ]] ; then echo "opensim-docker: setEnvironment.sh: have secrets file \"{$secretsFile}\"" - source <(ccrypt -c -E OPENSIM_CONFIGKEY "$secretsFile") + source <(ccrypt -c -E OS_CONFIGKEY "$secretsFile") HAVE_SECRETS=yes break; else diff --git a/image-opensim-herbal3d/config-standalone/os-secrets b/image-opensim-herbal3d/config-standalone/os-secrets index 7c75b4e..fb75487 100644 --- a/image-opensim-herbal3d/config-standalone/os-secrets +++ b/image-opensim-herbal3d/config-standalone/os-secrets @@ -4,18 +4,17 @@ # The configuration files look for the file 'os-secrets.crypt' and, when # found, runs 'ccrypt' using the password from the environment variable -# "OPENSIM_CONFIGKEY". So, edit this file and do: +# "OS_CONFIGKEY". So, edit this file and do: # cp os-secrets tempFile # -# ccrypt -e -E "OPENSIM_CONFIGKEY" < tempFile > os-secrets.crypt +# ccrypt -e -E "OS_CONFIGKEY" < tempFile > os-secrets.crypt # rm tempFile # or (exposing the key in the bash history): # ccrypt -e -K thekey < os-secrets > os-secrets.crypt # # Later, if you need to review the passwords, decrypt the file with: -# ccrypt -d -E "OPENSIM_CONFIGKEY" < os-secrets.crypt +# ccrypt -d -E "OS_CONFIGKEY" < os-secrets.crypt -# If this next variable is defined, MYSQL is configured export MYSQL_ROOT_PASSWORD=unknownStuff export MARIADB_ROOT_PASSWORD=unknownStuff export MYSQL_DB_HOST=dbservice diff --git a/image-opensim-herbal3d/config-standalone/scripts/setEnvironment.sh b/image-opensim-herbal3d/config-standalone/scripts/setEnvironment.sh index a3f1956..430254e 100755 --- a/image-opensim-herbal3d/config-standalone/scripts/setEnvironment.sh +++ b/image-opensim-herbal3d/config-standalone/scripts/setEnvironment.sh @@ -11,11 +11,11 @@ cd "$OPENSIMCONFIG" # See if we have encrypted secrets unset HAVE_SECRETS -if [[ ! -z "$OPENSIM_CONFIGKEY" ]] ; then +if [[ ! -z "$OS_CONFIGKEY" ]] ; then for secretsFile in $OPENSIMCONFIG/os-secrets.crypt ; do if [[ -e "$secretsFile" ]] ; then echo "opensim-docker: setEnvironment.sh: have secrets file \"{$secretsFile}\"" - source <(ccrypt -c -E OPENSIM_CONFIGKEY "$secretsFile") + source <(ccrypt -c -E OS_CONFIGKEY "$secretsFile") HAVE_SECRETS=yes break; else diff --git a/image-opensim/config-osgrid/os-secrets b/image-opensim/config-osgrid/os-secrets index 7c75b4e..fb75487 100644 --- a/image-opensim/config-osgrid/os-secrets +++ b/image-opensim/config-osgrid/os-secrets @@ -4,18 +4,17 @@ # The configuration files look for the file 'os-secrets.crypt' and, when # found, runs 'ccrypt' using the password from the environment variable -# "OPENSIM_CONFIGKEY". So, edit this file and do: +# "OS_CONFIGKEY". So, edit this file and do: # cp os-secrets tempFile # -# ccrypt -e -E "OPENSIM_CONFIGKEY" < tempFile > os-secrets.crypt +# ccrypt -e -E "OS_CONFIGKEY" < tempFile > os-secrets.crypt # rm tempFile # or (exposing the key in the bash history): # ccrypt -e -K thekey < os-secrets > os-secrets.crypt # # Later, if you need to review the passwords, decrypt the file with: -# ccrypt -d -E "OPENSIM_CONFIGKEY" < os-secrets.crypt +# ccrypt -d -E "OS_CONFIGKEY" < os-secrets.crypt -# If this next variable is defined, MYSQL is configured export MYSQL_ROOT_PASSWORD=unknownStuff export MARIADB_ROOT_PASSWORD=unknownStuff export MYSQL_DB_HOST=dbservice diff --git a/image-opensim/config-osgrid/scripts/setEnvironment.sh b/image-opensim/config-osgrid/scripts/setEnvironment.sh index a3f1956..430254e 100755 --- a/image-opensim/config-osgrid/scripts/setEnvironment.sh +++ b/image-opensim/config-osgrid/scripts/setEnvironment.sh @@ -11,11 +11,11 @@ cd "$OPENSIMCONFIG" # See if we have encrypted secrets unset HAVE_SECRETS -if [[ ! -z "$OPENSIM_CONFIGKEY" ]] ; then +if [[ ! -z "$OS_CONFIGKEY" ]] ; then for secretsFile in $OPENSIMCONFIG/os-secrets.crypt ; do if [[ -e "$secretsFile" ]] ; then echo "opensim-docker: setEnvironment.sh: have secrets file \"{$secretsFile}\"" - source <(ccrypt -c -E OPENSIM_CONFIGKEY "$secretsFile") + source <(ccrypt -c -E OS_CONFIGKEY "$secretsFile") HAVE_SECRETS=yes break; else diff --git a/image-opensim/config-standalone/os-secrets b/image-opensim/config-standalone/os-secrets index 7c75b4e..fb75487 100644 --- a/image-opensim/config-standalone/os-secrets +++ b/image-opensim/config-standalone/os-secrets @@ -4,18 +4,17 @@ # The configuration files look for the file 'os-secrets.crypt' and, when # found, runs 'ccrypt' using the password from the environment variable -# "OPENSIM_CONFIGKEY". So, edit this file and do: +# "OS_CONFIGKEY". So, edit this file and do: # cp os-secrets tempFile # -# ccrypt -e -E "OPENSIM_CONFIGKEY" < tempFile > os-secrets.crypt +# ccrypt -e -E "OS_CONFIGKEY" < tempFile > os-secrets.crypt # rm tempFile # or (exposing the key in the bash history): # ccrypt -e -K thekey < os-secrets > os-secrets.crypt # # Later, if you need to review the passwords, decrypt the file with: -# ccrypt -d -E "OPENSIM_CONFIGKEY" < os-secrets.crypt +# ccrypt -d -E "OS_CONFIGKEY" < os-secrets.crypt -# If this next variable is defined, MYSQL is configured export MYSQL_ROOT_PASSWORD=unknownStuff export MARIADB_ROOT_PASSWORD=unknownStuff export MYSQL_DB_HOST=dbservice diff --git a/image-opensim/config-standalone/scripts/setEnvironment.sh b/image-opensim/config-standalone/scripts/setEnvironment.sh index a3f1956..430254e 100755 --- a/image-opensim/config-standalone/scripts/setEnvironment.sh +++ b/image-opensim/config-standalone/scripts/setEnvironment.sh @@ -11,11 +11,11 @@ cd "$OPENSIMCONFIG" # See if we have encrypted secrets unset HAVE_SECRETS -if [[ ! -z "$OPENSIM_CONFIGKEY" ]] ; then +if [[ ! -z "$OS_CONFIGKEY" ]] ; then for secretsFile in $OPENSIMCONFIG/os-secrets.crypt ; do if [[ -e "$secretsFile" ]] ; then echo "opensim-docker: setEnvironment.sh: have secrets file \"{$secretsFile}\"" - source <(ccrypt -c -E OPENSIM_CONFIGKEY "$secretsFile") + source <(ccrypt -c -E OS_CONFIGKEY "$secretsFile") HAVE_SECRETS=yes break; else diff --git a/run-scripts/README.md b/run-scripts/README.md index 242716c..c3729e7 100644 --- a/run-scripts/README.md +++ b/run-scripts/README.md @@ -11,7 +11,7 @@ to the image-* directory. for seeing that the configuration files and other setup (like DB) are initialized. This script calls `firstTimeSetup.sh` for the first ever boot to do any initial setup. -This script will fail if the environment variables `CONFIGKEY` or `EXTERNAL_HOSTNAME` +This script will fail if the environment variables `OS_CONFIGKEY` or `EXTERNAL_HOSTNAME` are not set. `run.opensim.sh` starts the OpenSimulator instance. diff --git a/run-scripts/bootOpenSim.sh b/run-scripts/bootOpenSim.sh index 32057ba..f16ac9b 100755 --- a/run-scripts/bootOpenSim.sh +++ b/run-scripts/bootOpenSim.sh @@ -6,7 +6,7 @@ # The environment variable CONFIG_NAME can be set here otherwise # the value in config/os-config is used # If os-secrets.crypt exists in the configuration, the environment -# variable CONFIGKEY must exist and be the password for the encrypted file +# variable OS_CONFIGKEY must exist and be the password for the encrypted file export OPENSIMHOME=/home/opensim export VERSIONDIR=$OPENSIMHOME/VERSION