From 9a1815ea771d798fd2d358cc7fdc2d5c2dd6c1fc Mon Sep 17 00:00:00 2001 From: Akis Kesoglou Date: Thu, 1 Nov 2018 18:16:55 +0200 Subject: [PATCH] Forward VPN config to the API container Change-type: patch --- compose/services.yml | 3 +++ scripts/make-env | 30 ++++++++++++++++++++++++++++++ 2 files changed, 33 insertions(+) diff --git a/compose/services.yml b/compose/services.yml index 45470a3..2d14bc3 100644 --- a/compose/services.yml +++ b/compose/services.yml @@ -25,6 +25,9 @@ services: DB_PORT: 5432 DB_USER: docker DELTA_HOST: delta.${OPENBALENA_HOST_NAME} + DEVICE_CONFIG_OPENVPN_CONFIG: ${OPENBALENA_VPN_CONFIG} + DEVICE_CONFIG_OPENVPN_CA: ${OPENBALENA_VPN_CA} + DEVICE_CONFIG_SSH_AUTHORIZED_KEYS: ${OPENBALENA_SSH_AUTHORIZED_KEYS} HOST: api.${OPENBALENA_HOST_NAME} IMAGE_MAKER_URL: img.${OPENBALENA_HOST_NAME} IMAGE_STORAGE_BUCKET: resin-production-img-cloudformation diff --git a/scripts/make-env b/scripts/make-env index ba0a257..8e61ba8 100755 --- a/scripts/make-env +++ b/scripts/make-env @@ -34,6 +34,34 @@ b64encode() { cat "$@" | base64 --wrap=0 2>/dev/null || cat "$@" | base64 --break=0 } +VPN_CONFIG=$(b64encode <