diff --git a/docker/ipfs/ipfs-config.sh b/docker/ipfs/ipfs-config.sh index 80a3b32..60b64cf 100755 --- a/docker/ipfs/ipfs-config.sh +++ b/docker/ipfs/ipfs-config.sh @@ -137,7 +137,7 @@ ipfs config Datastore.StorageMax "$((diskSize * ${IPFS_DATASTORE_DISKUSAGE:-50}/ [ -n "${IPFS_REPROVIDER_STRATEGY}" ] && ipfs config Reprovider.Strategy "${IPFS_REPROVIDER_STRATEGY}" ## routing -[ -n "${IPFS_ROUTING_TYPE}" ] && ipfs config --json Routing.Type "${IPFS_ROUTING_TYPE}" +[ -n "${IPFS_ROUTING_TYPE}" ] && ipfs config Routing.Type "${IPFS_ROUTING_TYPE}" [ -n "${IPFS_ROUTING_ACCELERATEDDHTCLIENT}" ] && ipfs config --json Routing.AcceleratedDHTClient "${IPFS_ROUTING_ACCELERATEDDHTCLIENT}" [ -n "${IPFS_ROUTING_LOOPBACKADDRESSESONLANDHT}" ] && ipfs config --bool Routing.LoopbackAddressesOnLanDHT "${IPFS_ROUTING_LOOPBACKADDRESSESONLANDHT}" [ -n "${IPFS_ROUTING_METHODS}" ] && ipfs config --json Routing.Methods "${IPFS_ROUTING_METHODS}" diff --git a/docker/nginx/Dockerfile b/docker/nginx/Dockerfile index bcc5070..e116661 100644 --- a/docker/nginx/Dockerfile +++ b/docker/nginx/Dockerfile @@ -6,7 +6,7 @@ RUN sed -i 's/\(function _resolvers() {\)$/function _nginx_config() {\n\t\/app\/ && sed -i 's|\( return 503;\)$|{{- if (exists (printf "/etc/nginx/vhost.d/%s" (or $.Env.DEFAULT "default"))) }}\n include {{ (printf "/etc/nginx/vhost.d/%s" (or $.Env.DEFAULT "default")) }};\n{{- if (and (exists "/etc/nginx/vhost.d/default_location") ($.Env.DEFAULT_LOCATION)) }}\n include /etc/nginx/vhost.d/default_location;\n{{- end }}\n{{- if (and (exists "/etc/nginx/vhost.d/default_location_php") ($.Env.DEFAULT_LOCATION_PHP)) }}\n include /etc/nginx/vhost.d/default_location_php;\n{{- end }}\n{{- if (and (exists "/etc/nginx/vhost.d/default_location_ipfs") ($.Env.DEFAULT_LOCATION_IPFS)) }}\n include /etc/nginx/vhost.d/default_location_ipfs;\n{{- end }}\n{{- else }}\n\1\n{{- end }}|' /app/nginx.tmpl \ && sed -i 's|\({{-\? if (exists "/etc/nginx/proxy.conf") }}\)|{{- if (exists "/etc/nginx/vhost.d/nginx.conf") }}\ninclude /etc/nginx/vhost.d/nginx.conf;\n{{ end }}\n\n\1|' /app/nginx.tmpl \ && sed -i 's|exists "/etc/nginx/vhost.d/default"|exists (printf "/etc/nginx/vhost.d/%s" (or $.Env.DEFAULT "default"))|;s|include /etc/nginx/vhost.d/default;|include {{ (printf "/etc/nginx/vhost.d/%s" (or $.Env.DEFAULT "default")) }};|' /app/nginx.tmpl \ - && awk '/proxy_pass \{\{ trim .Proto \}\}/{sub(/else/, "else if ne .Proto \"local\"", last)} NR>1{print last} {last=$0} END {print last}' /app/nginx.tmpl > /tmp/nginx.tmpl && mv /tmp/nginx.tmpl /app/ + && awk '/proxy_pass \{\{ trim \$proto \}\}/{sub(/else/, "else if ne \$proto \"local\"", last)} NR>1{print last} {last=$0} END {print last}' /app/nginx.tmpl > /tmp/nginx.tmpl && mv /tmp/nginx.tmpl /app/ COPY ${DOCKER_BUILD_DIR}/nginx* /app diff --git a/make/def.mk b/make/def.mk index ed2c127..e9a381a 100644 --- a/make/def.mk +++ b/make/def.mk @@ -195,7 +195,6 @@ JWT = $(strip \ $(eval b64_payload := $(call base64t,$(payload))) \ $(eval b64_signature := $(call base64t,$(call hs256,$(b64_header).$(b64_payload),$(secret)))) \ $(eval b64_signature := $(call b64_hs256,$(b64_header).$(b64_payload),$(secret))) \ - $(if $(DEBUG),$(header) - $(payload) - $(secret) --- ) \ $(b64_header).$(b64_payload).$(b64_signature)) # macro RESU: Print USER associated to MAIL diff --git a/stack/User/ipfs.yml b/stack/User/ipfs.yml index 5c79b52..b9fd830 100644 --- a/stack/User/ipfs.yml +++ b/stack/User/ipfs.yml @@ -10,7 +10,7 @@ services: - UID=${UID} context: ../.. dockerfile: docker/ipfs/Dockerfile - command: daemon --agent-version-suffix=${COMPOSE_PROJECT_NAME} ${USER_IPFS_DAEMON_ARGS:---migrate} + command: daemon --agent-version-suffix=${COMPOSE_PROJECT_NAME} ${USER_IPFS_DAEMON_ARGS:---migrate=true} container_name: ${COMPOSE_PROJECT_NAME}-ipfs cpus: 0.5 environment: diff --git a/stack/host/host.mk b/stack/host/host.mk index c00b0d3..b39858a 100644 --- a/stack/host/host.mk +++ b/stack/host/host.mk @@ -51,7 +51,7 @@ host-certbot: host-docker-build-certbot --mount source=$(HOST_DOCKER_VOLUME),target=/etc/letsencrypt/ \ --mount source=$(HOST_DOCKER_VOLUME),target=/var/log/letsencrypt/ \ --network host \ - $(HOST_DOCKER_REPOSITORY)/certbot \ + $(HOST_DOCKER_REPOSITORY)/certbot:$(DOCKER_IMAGE_TAG) \ --dns-standalone-address=0.0.0.0 \ --dns-standalone-port=53 \ --non-interactive --agree-tos --email hostmaster@$(domain) certonly \ @@ -64,12 +64,12 @@ host-certbot: host-docker-build-certbot # target host-certbot-certificates: List letsencrypt certificates .PHONY: host-certbot-certificates host-certbot-certificates: host-docker-build-certbot - docker run --rm --mount source=$(HOST_DOCKER_VOLUME),target=/etc/letsencrypt/ $(HOST_DOCKER_REPOSITORY)/certbot certificates + docker run --rm --mount source=$(HOST_DOCKER_VOLUME),target=/etc/letsencrypt/ $(HOST_DOCKER_REPOSITORY)/certbot:$(DOCKER_IMAGE_TAG) certificates # target host-certbot-renew: Renew letsencrypt certificates .PHONY: host-certbot-renew host-certbot-renew: host-docker-build-certbot - docker run --rm --mount source=$(HOST_DOCKER_VOLUME),target=/etc/letsencrypt/ --network host $(HOST_DOCKER_REPOSITORY)/certbot renew + docker run --rm --mount source=$(HOST_DOCKER_VOLUME),target=/etc/letsencrypt/ --network host $(HOST_DOCKER_REPOSITORY)/certbot:$(DOCKER_IMAGE_TAG) renew # target host-certbot-staging: Create staging ${DOMAIN} certificate files with letsencrypt .PHONY: host-certbot-staging @@ -80,7 +80,7 @@ host-certbot-staging: host-docker-build-certbot --mount source=$(HOST_DOCKER_VOLUME),target=/etc/letsencrypt/ \ --mount source=$(HOST_DOCKER_VOLUME),target=/var/log/letsencrypt/ \ --network host \ - $(HOST_DOCKER_REPOSITORY)/certbot \ + $(HOST_DOCKER_REPOSITORY)/certbot:$(DOCKER_IMAGE_TAG) \ --dns-standalone-address=0.0.0.0 \ --dns-standalone-port=53 \ --non-interactive --agree-tos --email hostmaster@$(domain) certonly \ diff --git a/stack/host/ipfs.yml b/stack/host/ipfs.yml index fa6f5e6..ae53ef8 100644 --- a/stack/host/ipfs.yml +++ b/stack/host/ipfs.yml @@ -10,7 +10,7 @@ services: - UID=${HOST_UID} context: ../.. dockerfile: docker/ipfs/Dockerfile - command: daemon --agent-version-suffix=${HOST_COMPOSE_PROJECT_NAME} ${HOST_IPFS_DAEMON_ARGS:---migrate} + command: daemon --agent-version-suffix=${HOST_COMPOSE_PROJECT_NAME} ${HOST_IPFS_DAEMON_ARGS:---migrate=true} container_name: ${HOST_COMPOSE_PROJECT_NAME}-ipfs cpus: 0.5 environment: diff --git a/stack/ipfs/ipfs.yml b/stack/ipfs/ipfs.yml index f0843a2..c7d2158 100644 --- a/stack/ipfs/ipfs.yml +++ b/stack/ipfs/ipfs.yml @@ -9,7 +9,7 @@ services: - UID=${UID} context: ../.. dockerfile: docker/ipfs/Dockerfile - command: daemon --agent-version-suffix=${COMPOSE_PROJECT_NAME} ${IPFS_DAEMON_ARGS:---migrate} + command: daemon --agent-version-suffix=${COMPOSE_PROJECT_NAME} ${IPFS_DAEMON_ARGS:---migrate=true} cpus: 0.5 environment: - DEBUG=${DEBUG:-}