1
0
Fork 0
mirror of synced 2024-07-05 22:40:39 +12:00
budibase/hosting/digitalocean/files/var/lib/cloud/scripts/per-instance/001_onboot
2022-02-01 11:02:37 +01:00

21 lines
556 B
Bash
Executable file

#!/bin/bash
# go into the app dir
cd /root
# fetch nginx and docker-compose files
wget https://raw.githubusercontent.com/Budibase/budibase/master/hosting/docker-compose.yaml
wget https://raw.githubusercontent.com/Budibase/budibase/master/hosting/hosting.properties
# Create .env file from hosting.properties using bash and then remove it
while read line; do
uuid=$(uuidgen)
echo $line | sed "s/budibase/$uuid/g" | sed "s/testsecret/$uuid/g" >> .env
done <hosting.properties
rm hosting.properties
# boot the stack
docker-compose up -d
# return
cd -