From 57d8401fbd2e050d8c698b2f5b4c697d16ba5cb3 Mon Sep 17 00:00:00 2001 From: ckunki Date: Tue, 6 Feb 2024 13:06:27 +0100 Subject: [PATCH 1/4] Explained login to docker container --- doc/changes/changes_0.2.0.md | 5 ++++ doc/user_guide/docker/docker_usage.md | 27 ++++++++++++++++++- .../roles/entrypoint/files/entrypoint.py | 2 +- 3 files changed, 32 insertions(+), 2 deletions(-) diff --git a/doc/changes/changes_0.2.0.md b/doc/changes/changes_0.2.0.md index c8e0ce0f..55f1378a 100644 --- a/doc/changes/changes_0.2.0.md +++ b/doc/changes/changes_0.2.0.md @@ -16,7 +16,12 @@ Version: 0.2.0 * #163: Fixed version number of VM images etc. * #161: Fixed the bug in the Transformers' Translation notebook. +## Documentation + +* #125: Explained login to docker container + ## Refactoring + * #160: Implemented the PM's recommendations of 2024-01-24. * #120: Passing the secret store object (sb_config) as a parameter to all functions that need it. diff --git a/doc/user_guide/docker/docker_usage.md b/doc/user_guide/docker/docker_usage.md index 70b014a2..745d943e 100644 --- a/doc/user_guide/docker/docker_usage.md +++ b/doc/user_guide/docker/docker_usage.md @@ -142,10 +142,35 @@ port to the same port then you can connect with http://localhost:49494. └─┘┴ ─┴┘┴ ┴ ┴ └─┘ ┴ └─┘└─┘┴└─ └┘└─┘┴ ┴ ┴ └─┘┴└─ ┴ ┴ ┴└─┘└─┘└┴┘└─┘┴└──┴┘ o The default password is "ai-lab". -To update the password as user root run +To update the password login to the Docker container as user root and run /root/jupyterenv/bin/jupyter-lab server password ``` Using an internet browser you then can connect to the Jupyter server running in the Docker container in order to follow the tutorials presented by a set of Jupyter notebooks, see [Connecting to Jupyter Service](../user_guide.md#connecting-to-jupyter-service). For parameter ``: If your daemon machine is identical to the machine your browser is running on then you can replace `` by `localhost` otherwise please use the IP address of the daemon machine. + +The following section explains how to login to the Docker container in order to change the default password for example. + +## Login to the Docker container + +To update the password you first need to login to the Docker container. + +The following command shows the list of currently running Docker containers + +```shell +docker ps +``` + +Here is a sample output + +``` +CONTAINER ID IMAGE COMMAND NAMES +1199447716d4 image:2 "entrypoint" funny_rabbit +``` + +The following command enables you to login as user `root` to the specified container: + +```shell +docker exec --user root -it ${CONTAINER_ID} bash +``` diff --git a/exasol/ds/sandbox/runtime/ansible/roles/entrypoint/files/entrypoint.py b/exasol/ds/sandbox/runtime/ansible/roles/entrypoint/files/entrypoint.py index 5bdc8c57..0250f01c 100644 --- a/exasol/ds/sandbox/runtime/ansible/roles/entrypoint/files/entrypoint.py +++ b/exasol/ds/sandbox/runtime/ansible/roles/entrypoint/files/entrypoint.py @@ -100,7 +100,7 @@ def exit_on_error(rc): └─┘┴ ─┴┘┴ ┴ ┴ └─┘ ┴ └─┘└─┘┴└─ └┘└─┘┴ ┴ ┴ └─┘┴└─ ┴ ┴ ┴└─┘└─┘└┴┘└─┘┴└──┴┘ o The default password is "{password}". - To update the password as user {user} run + To update the password login to the Docker container as user {user} and run {binary_path} server password """) with open(logfile, "r") as f: From a2549ca42412c1cd5f04d32183b256bdef3efd56 Mon Sep 17 00:00:00 2001 From: ckunki Date: Tue, 6 Feb 2024 13:32:29 +0100 Subject: [PATCH 2/4] cherry picked changes of .github/workflows/check_ci.yaml --- .github/workflows/check_ci.yaml | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/.github/workflows/check_ci.yaml b/.github/workflows/check_ci.yaml index a3bd8422..5e1a76ba 100644 --- a/.github/workflows/check_ci.yaml +++ b/.github/workflows/check_ci.yaml @@ -30,7 +30,8 @@ jobs: AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_ACCESS_KEY_SECRET }} AWS_DEFAULT_REGION: ${{ secrets.AWS_REGION }} - run_nodebook_tests: + run_notebook_tests: + if: "contains(github.event.head_commit.message, '[run-notebook-tests]')" environment: AWS_SAGEMAKER runs-on: ubuntu-latest @@ -38,6 +39,21 @@ jobs: - uses: actions/checkout@v3 with: fetch-depth: 0 + - name: Free disk space + uses: jlumbroso/free-disk-space@main + with: + tool-cache: true + large-packages: false + + - name: Free disk space by removing large directories + run: | + sudo rm -rf /usr/local/graalvm/ + sudo rm -rf /usr/local/.ghcup/ + sudo rm -rf /usr/local/share/powershell + sudo rm -rf /usr/local/share/chromium + sudo rm -rf /usr/local/lib/node_modules + sudo rm -rf /opt/ghc + - name: Setup Python & Poetry Environment uses: ./.github/actions/prepare_poetry_env From 5a68ce0353472d6af90ab7cd370a700eed35f65f Mon Sep 17 00:00:00 2001 From: ckunki Date: Tue, 6 Feb 2024 15:05:42 +0100 Subject: [PATCH 3/4] Fixed changes file --- doc/changes/changes_0.2.0.md | 2 -- 1 file changed, 2 deletions(-) diff --git a/doc/changes/changes_0.2.0.md b/doc/changes/changes_0.2.0.md index 2f2c6f65..f9a1538c 100644 --- a/doc/changes/changes_0.2.0.md +++ b/doc/changes/changes_0.2.0.md @@ -29,5 +29,3 @@ Version: 0.2.0 * #170: Renaming the section name "Set up" to "Setup". * #182: Renaming the secret store global variable from "sb_config" to "ai_lab_config". * #169: Renaming the default database schema from "IDA" to "AI_LAB". - -## Documentation From 9847de171de5fbf539b978dab0d5e335a6e7e9b3 Mon Sep 17 00:00:00 2001 From: ckunki Date: Wed, 7 Feb 2024 09:00:14 +0100 Subject: [PATCH 4/4] Fixed review findings --- doc/user_guide/docker/docker_usage.md | 10 +++++----- .../ansible/roles/entrypoint/files/entrypoint.py | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/doc/user_guide/docker/docker_usage.md b/doc/user_guide/docker/docker_usage.md index 745d943e..df3f7f65 100644 --- a/doc/user_guide/docker/docker_usage.md +++ b/doc/user_guide/docker/docker_usage.md @@ -142,7 +142,7 @@ port to the same port then you can connect with http://localhost:49494. └─┘┴ ─┴┘┴ ┴ ┴ └─┘ ┴ └─┘└─┘┴└─ └┘└─┘┴ ┴ ┴ └─┘┴└─ ┴ ┴ ┴└─┘└─┘└┴┘└─┘┴└──┴┘ o The default password is "ai-lab". -To update the password login to the Docker container as user root and run +To update the password, log in to the Docker container as the user root and run /root/jupyterenv/bin/jupyter-lab server password ``` @@ -150,13 +150,13 @@ Using an internet browser you then can connect to the Jupyter server running in For parameter ``: If your daemon machine is identical to the machine your browser is running on then you can replace `` by `localhost` otherwise please use the IP address of the daemon machine. -The following section explains how to login to the Docker container in order to change the default password for example. +The following section explains how to log in to the Docker container to change settings, such as the default password. ## Login to the Docker container -To update the password you first need to login to the Docker container. +To update the password you must log in to the Docker container. -The following command shows the list of currently running Docker containers +First, you need to find out the container's ID. The following command shows the list of currently running Docker containers. ```shell docker ps @@ -169,7 +169,7 @@ CONTAINER ID IMAGE COMMAND NAMES 1199447716d4 image:2 "entrypoint" funny_rabbit ``` -The following command enables you to login as user `root` to the specified container: +The following command enables you to log in as the user `root` to the specified container: ```shell docker exec --user root -it ${CONTAINER_ID} bash diff --git a/exasol/ds/sandbox/runtime/ansible/roles/entrypoint/files/entrypoint.py b/exasol/ds/sandbox/runtime/ansible/roles/entrypoint/files/entrypoint.py index 0250f01c..8c2bb2d4 100644 --- a/exasol/ds/sandbox/runtime/ansible/roles/entrypoint/files/entrypoint.py +++ b/exasol/ds/sandbox/runtime/ansible/roles/entrypoint/files/entrypoint.py @@ -100,7 +100,7 @@ def exit_on_error(rc): └─┘┴ ─┴┘┴ ┴ ┴ └─┘ ┴ └─┘└─┘┴└─ └┘└─┘┴ ┴ ┴ └─┘┴└─ ┴ ┴ ┴└─┘└─┘└┴┘└─┘┴└──┴┘ o The default password is "{password}". - To update the password login to the Docker container as user {user} and run + To update the password, log in to the Docker container as the user {user} and run {binary_path} server password """) with open(logfile, "r") as f: