Commit 787f04a28f44941b01f5421c412a807ec781044d
1 parent
f78dba5d
Exists in
dev
Fix warning docker environment values
Showing
2 changed files
with
6 additions
and
3 deletions
Show diff stats
docker/docker-compose.yml
... | ... | @@ -16,6 +16,8 @@ services: |
16 | 16 | # note : as db is an image of mysql, this root password will be set on the first installation on the image, if the value is changed, it will not be updated in the database |
17 | 17 | - "MYSQL_ROOT_PASSWORD=${MYSQL_ROOT_PASSWORD:-root}" |
18 | 18 | - VNC_NO_PASSWORD=1 |
19 | + env_file: | |
20 | + - .env | |
19 | 21 | volumes: |
20 | 22 | - db:/var/lib/mysql/ |
21 | 23 | deploy: | ... | ... |
pyros.py
... | ... | @@ -174,7 +174,7 @@ SQL_USER = "" |
174 | 174 | SQL_PSWD = "" |
175 | 175 | MYSQL_EXE_PATH = "" |
176 | 176 | |
177 | -ENV_PATH = "docker/variables.env" | |
177 | +ENV_PATH = "docker/.env" | |
178 | 178 | ENV_SAMPLE_PATH = "docker/.env-sample" |
179 | 179 | |
180 | 180 | |
... | ... | @@ -476,7 +476,7 @@ def shell(): |
476 | 476 | os.environ["PATH_TO_OBSCONF_FOLDER"] = os.path.join(os.path.abspath( |
477 | 477 | PYROS_DJANGO_BASE_DIR), "../../../config/pyros_observatory/pyros_observatory_default/") |
478 | 478 | os.environ["PATH_TO_OBSCONF_FILE"] = os.path.join(os.path.abspath( |
479 | - PYROS_DJANGO_BASE_DIR), os.environ["PATH_TO_OBSCONF_FOLDER"] + "observatory_default.yml") | |
479 | + PYROS_DJANGO_BASE_DIR), os.environ["PATH_TO_OBSCONF_FOLDER"] + "observatory.yml") | |
480 | 480 | print("Execution commande shell") |
481 | 481 | print("NAME IS", __name__) |
482 | 482 | print() |
... | ... | @@ -579,7 +579,7 @@ def install_or_update(UPDATE: bool = False, with_packages: bool = True, with_dat |
579 | 579 | os.environ["PATH_TO_OBSCONF_FOLDER"] = os.path.join(os.path.abspath( |
580 | 580 | PYROS_DJANGO_BASE_DIR), "../../../config/pyros_observatory/pyros_observatory_default/") |
581 | 581 | os.environ["PATH_TO_OBSCONF_FILE"] = os.path.join(os.path.abspath( |
582 | - PYROS_DJANGO_BASE_DIR), os.environ["PATH_TO_OBSCONF_FOLDER"] + "observatory_default.yml") | |
582 | + PYROS_DJANGO_BASE_DIR), os.environ["PATH_TO_OBSCONF_FOLDER"] + "observatory.yml") | |
583 | 583 | ACTION = "UPDATING" if UPDATE else "INSTALLING" |
584 | 584 | |
585 | 585 | # if WITH_DOCKER: with_database = True |
... | ... | @@ -1681,6 +1681,7 @@ def install_observatory(observatory): |
1681 | 1681 | cloned_repo = Repo.clone_from( |
1682 | 1682 | f"https://gitlab.irap.omp.eu/pyros-irap/pyros_observatory_{observatory}.git", os.path.join(pyros_observatory_path, f"pyros_observatory_{observatory}")) |
1683 | 1683 | print("Cloned successfully: ", cloned_repo.__class__ is Repo) |
1684 | + print(f"The observatory {observatory} has been installed in {os.path.join(pyros_observatory_path, f'pyros_observatory_{observatory}')}") | |
1684 | 1685 | except GitError: |
1685 | 1686 | if not os.path.exists(os.path.join(pyros_observatory_path, f"pyros_observatory_{observatory}")): |
1686 | 1687 | print("No repository found. PyROS will create a copy of an default observatory that you can modify.") | ... | ... |