[why] when execute container/scheduler/start error: [root@localhost scheduler]# ./start s001-alpine-3018 s001-alpine-3018 Unhandled exception: Invalid Int32: (ArgumentError) from /usr/lib/crystal/core/string.cr:421:5 in 'to_i32' from /usr/lib/crystal/core/crystal/once.cr:255:3 in 'once' from /usr/lib/crystal/core/crystal/once.cr:48:3 in '__crystal_once' from /c/cci/src/scheduler/constants.cr:19:1 in '__crystal_main' from /usr/lib/crystal/core/crystal/main.cr:97:5 in 'main_user_code' from /usr/lib/crystal/core/crystal/main.cr:86:7 in 'main' from /usr/lib/crystal/core/crystal/main.cr:106:3 in 'main' from ???
because when deploy scheduler container not by submit deploy-cci.yaml in machine, ENV INITRD_HTTP_PORT is null in /etc/compass-ci/defaults/localhost.yaml.
[how] set default $initrd_http_port=8800, to prevent scheduler start failed when $INITRD_HTTP_PORT is null.
Signed-off-by: Liu Yinsi liuyinsi@163.com --- sparrow/3-code/dev-env | 1 + 1 file changed, 1 insertion(+)
diff --git a/sparrow/3-code/dev-env b/sparrow/3-code/dev-env index 87431be..f36aaca 100755 --- a/sparrow/3-code/dev-env +++ b/sparrow/3-code/dev-env @@ -6,6 +6,7 @@ server_name=$(hostname | cut -f1 -d.) server_ip=$(ip route get 1.2.3.4 | awk '{print $7; exit}') : ${sched_host:=$server_ip} : ${sched_port:=3000} +: ${initrd_http_port:=8800} : ${gitcache_host:=$server_ip} : ${gitcache_port:=5000} : ${MASTER_FLUENTD_HOST:=$server_ip}