Skip to content

Commit 9f36122

Browse files
committed
Next try!
1 parent d2393af commit 9f36122

File tree

4 files changed

+40
-9
lines changed

4 files changed

+40
-9
lines changed

ci/Dockerfile

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,3 +34,33 @@ ENTRYPOINT ["devbox", "run", "--config=/code", "--"]
3434

3535
# Avoid the bash from debox.json and use Debian's bash for better pre-configuration.
3636
CMD ["/usr/bin/bash"]
37+
38+
39+
# ================================================================================
40+
# WORKDIR /
41+
# USER root:root
42+
43+
# COPY devbox.json devbox.json
44+
# COPY devbox.lock devbox.lock
45+
# COPY nix nix
46+
47+
# # 💡 In theory we could avoid the copies by mounting the content into the image during
48+
# # build-time. However devbox has issues with the read-only-mounts in the name of the user
49+
# # “root”.
50+
# RUN \
51+
# # --mount=type=bind,source=./nix,target=/code/nix,readonly \
52+
# # --mount=type=bind,source=./devbox.json,target=/code/debox.json,readonly \
53+
# # --mount=type=bind,source=./devbox.lock,target=/code/devbox.lock,readonly \
54+
# devbox run -- echo 'Installed Packages.'
55+
56+
# # Make use of the installed devbox-environment: This is required for the defined entry-point to
57+
# # work.
58+
# ENV \
59+
# PATH="/.devbox/nix/profile/default/bin:${PATH}" \
60+
# LD_LIBRARY_PATH="/.devbox/nix/profile/default/lib"
61+
62+
# # The image is meant to be run with the particular devbox-setup from the “code”-folder.
63+
# ENTRYPOINT ["devbox", "run", "--"]
64+
65+
# # Avoid the bash from debox.json and use Debian's bash for better pre-configuration.
66+
# CMD ["/usr/bin/bash"]

ci/autoscaler/scripts/common.sh

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -179,15 +179,15 @@ function cf_target(){
179179
# process finishes.
180180
function ci_prepare_postgres_db() {
181181
# devbox makes sure that the environment-variables PGHOST and PGDATA are set appropriately.
182-
set -x # 🚧 To-do: Debug-code
183-
echo "pwd: $(pwd)" # 🚧 To-do: Debug-code
184-
echo "ls -lah .: $(ls -lah .)" # 🚧 To-do: Debug-code
182+
# set -x # 🚧 To-do: Debug-code
183+
# echo "pwd: $(pwd)" # 🚧 To-do: Debug-code
184+
# echo "ls -lah .: $(ls -lah .)" # 🚧 To-do: Debug-code
185185
initdb
186-
devbox services --config='/code' up postgresql --background # 🚧 To-do: Can we avoid the `--config`-parameter?
187-
#devbox services up postgresql --background # pg_ctl will not work as it is not aware of where to
186+
# devbox services --config='/code' up postgresql --background # 🚧 To-do: Can we avoid the `--config`-parameter?
187+
devbox services up postgresql --background # pg_ctl will not work as it is not aware of where to
188188
# create the socket.
189189
createuser tests-pg
190190
createdb tests-pg # Needed to be done like this, because 'tests-pg' does not have the required#
191191
# priviledges.
192-
set +x # 🚧 To-do: Debug-code
192+
# set +x # 🚧 To-do: Debug-code
193193
}

ci/autoscaler/scripts/run-unit-tests.sh

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,10 @@ echo "1. Name des Skripts (wie aufgerufen): $0"
99
echo "2. Tatsächlicher Pfad des Skripts: $BASH_SOURCE"
1010
echo "3. Aufrufargumente: $@"
1111
echo "4. Anzahl der Argumente: $#"
12-
echo "5. Vollständiger Aufrufbefehl:"
13-
ps -o args= -p $$
12+
echo '5. Umgebung:'
13+
echo "$(env)"
14+
# echo "6. Vollständiger Aufrufbefehl:"
15+
# ps -o args= -p $$
1416
# ==================== 🚧 To-do: end debugging ====================
1517

1618
script_dir="$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" &> /dev/null && pwd)"

ci/autoscaler/tasks/run-unit-tests.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,5 +11,4 @@ run:
1111
- "run"
1212
- "--config=/code"
1313
- "--"
14-
- "pwd; ls; echo 'Alle verfügbaren Umgebungsvariablen:'; env;"
1514
- "${DEVBOX_WD}/app-autoscaler-release/ci/autoscaler/scripts/run-unit-tests.sh"

0 commit comments

Comments
 (0)