mirror of
https://github.com/balena-os/balena-supervisor.git
synced 2024-12-19 21:57:54 +00:00
Auto-merge for PR #460 via VersionBot
dind: Set DELTA_ENDPOINT, insert variant into os-release, and fix vpn apikeys
This commit is contained in:
commit
639aa0aece
@ -4,6 +4,10 @@ All notable changes to this project will be documented in this file
|
||||
automatically by Versionist. DO NOT EDIT THIS FILE MANUALLY!
|
||||
This project adheres to [Semantic Versioning](http://semver.org/).
|
||||
|
||||
## v5.0.2 - 2017-07-01
|
||||
|
||||
* Dind: Set DELTA_ENDPOINT, insert variant into os-release, and fix vpn apikeys [Pablo Carranza Velez]
|
||||
|
||||
## v5.0.1 - 2017-07-01
|
||||
|
||||
* Allow registering the deviceApiKey in a non-compatible OS by making the apiKey equal the deviceApiKey, and add an fsync to all config.json writes [Pablo Carranza Velez]
|
||||
|
@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "resin-supervisor",
|
||||
"description": "This is resin.io's Supervisor, a program that runs on IoT devices and has the task of running user Apps (which are Docker containers), and updating them as Resin's API informs it to.",
|
||||
"version": "5.0.1",
|
||||
"version": "5.0.2",
|
||||
"license": "Apache-2.0",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
|
@ -30,6 +30,7 @@ RUN passwd -d root
|
||||
|
||||
# Change os release to a resin-sync compatible one
|
||||
RUN sed -i 's/\(PRETTY_NAME=\).*/\1"ResinOS 1.2.1+dind"/' /etc/os-release
|
||||
RUN echo 'VARIANT_ID="dev"' >> /etc/os-release
|
||||
|
||||
COPY config/openvpn/ /etc/openvpn/
|
||||
COPY config/dropbear/config /etc/default/dropbear
|
||||
|
@ -26,6 +26,7 @@ ExecStart=/bin/bash -c 'source /usr/src/app/resin-vars && \
|
||||
-v /etc/resolv.conf:/etc/resolv.conf:rw \
|
||||
${SUPERVISOR_EXTRA_MOUNTS} \
|
||||
-e "API_ENDPOINT=$API_ENDPOINT" \
|
||||
-e "DELTA_ENDPOINT=$DELTA_ENDPOINT" \
|
||||
-e "REGISTRY_ENDPOINT=$REGISTRY_ENDPOINT" \
|
||||
-e "PUBNUB_SUBSCRIBE_KEY=$PUBNUB_SUBSCRIBE_KEY" \
|
||||
-e "PUBNUB_PUBLISH_KEY=$PUBNUB_PUBLISH_KEY" \
|
||||
|
@ -44,6 +44,7 @@ fi
|
||||
if [ -f $CONFIG_PATH ]
|
||||
then
|
||||
API_ENDPOINT=$(jq --raw-output ".apiEndpoint" $CONFIG_PATH)
|
||||
DELTA_ENDPOINT=$(jq --raw-output ".deltaEndpoint" $CONFIG_PATH)
|
||||
LISTEN_PORT=$(jq --raw-output ".listenPort" $CONFIG_PATH)
|
||||
MIXPANEL_TOKEN=$(jq --raw-output ".mixpanelToken" $CONFIG_PATH)
|
||||
PUBNUB_PUBLISH_KEY=$(jq --raw-output ".pubnubPublishKey" $CONFIG_PATH)
|
||||
|
@ -7,7 +7,7 @@ while true; do
|
||||
echo "UUID missing from config file, VPN cannot connect"
|
||||
sleep 2
|
||||
else
|
||||
read uuid api_key <<<$(jq -r '.uuid,.deviceApiKey // .apiKey' $CONFIG_PATH)
|
||||
read uuid api_key <<<$(jq -r '.uuid,.apiKey // .deviceApiKey' $CONFIG_PATH)
|
||||
mkdir -p /var/volatile/
|
||||
echo $uuid > /var/volatile/vpnfile
|
||||
echo $api_key >> /var/volatile/vpnfile
|
||||
|
Loading…
Reference in New Issue
Block a user