-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathentrypoint.sh
More file actions
executable file
·56 lines (49 loc) · 1.46 KB
/
entrypoint.sh
File metadata and controls
executable file
·56 lines (49 loc) · 1.46 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
#!/usr/bin/env bash
set -e
function initialise_devpi {
echo "[RUN]: Initialise devpi-server"
devpi-server --restrict-modify root --start --init --host 127.0.0.1 --port 3141
devpi-server --status
devpi use http://localhost:3141
devpi login root --password=''
devpi user -m root password="${DEVPI_PASSWORD}"
devpi index -y -c public pypi_whitelist='*'
devpi-server --stop
devpi-server --status
}
if [ "$1" = 'devpi' ]; then
if [ ! -f "${DEVPI_SERVERDIR}/.serverversion" ]; then
initialise_devpi
fi
echo "[RUN]: Launching devpi-server"
exec devpi-server \
--restrict-modify root \
--host 0.0.0.0 \
--port 3141 \
--logger-cfg=${DEVPI_LOGGER_CFG} \
--mirror-cache-expiry=${DEVPI_MIRROR_CACHE_EXPIRY}
fi
echo "[RUN]: Builtin command not provided [devpi]"
echo "[RUN]: $@"
exec "$@"
#
#if [ ! -f "${DEVPI_SERVERDIR}/.serverversion" ]; then
# devpi-server --init
#
# if [ -n "${DEVPI_PASSWORD}" ]; then
# devpi-server --restrict-modify root --start --host 127.0.0.1 --port 3142
# devpi-server --status
# devpi use http://127.0.0.1:3142
# devpi login root --password=''
# devpi user -m root password="${DEVPI_PASSWORD}"
# devpi index -y -c public pypi_whitelist='*'
# devpi-server --stop
# fi
#fi
#
#devpi-server \
# --logger-cfg=/logger_cfg.json \
# --restrict-modify root \
# --mirror-cache-expiry=${DEVPI_MIRROR_CACHE_EXPIRY} \
# --host 0.0.0.0 \
# --port 3141