diff --git a/.gitignore b/.gitignore index 80e3a4d..a6dc3f2 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,2 @@ /kairos_remote_adapter -build/bin/ +out/ diff --git a/Dockerfile b/Dockerfile index e470510..4966d5f 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,10 +1,9 @@ FROM alpine:latest -ADD out/adapter /usr/bin/ +ADD out/adapter_linux_amd64 /usr/bin/adapter RUN chmod +x /usr/bin/adapter ADD launch.sh ./launch -EXPOSE 8080 CMD ./launch diff --git a/bin/build b/bin/build index 0ecbc6c..7d53485 100755 --- a/bin/build +++ b/bin/build @@ -6,4 +6,4 @@ echo -e "\nGenerating Binary..." CURRENTDIR=`pwd` -go build -o $CURRENTDIR/out/adapter +CGO_ENABLED=0 go build -a -ldflags '-extldflags "-static"' -o $CURRENTDIR/out/adapter diff --git a/config.yml b/config.yml index fcc7ab2..1d3a306 100644 --- a/config.yml +++ b/config.yml @@ -4,4 +4,4 @@ listen_addr: 127.0.0.1 log_level: debug log_json: false no_color: false -worker: 5 +workers: 5 diff --git a/launch.sh b/launch.sh index 1468c3a..a540bb5 100755 --- a/launch.sh +++ b/launch.sh @@ -5,7 +5,7 @@ set -e cat << EOF > config.yml kairos_url: ${KAIROS} skip_insecure: ${SKIP_INSECURE:-false} -listen_addr: 0.0.0.0:8080 +listen_addr: ${LISTEN_ADDR:-0.0.0.0:8080} log_level: ${LOG_LEVEL:-info} log_json: ${LOG_JSON:-true} no_color: ${NO_COLOR:-false}