refactor: self hosting setup (#411)

* merge-commit: self hosted updates

* dev: updates in self hosting setup

* dev: update script to get the instance IP

* dev: update script to generate backend secret key
This commit is contained in:
pablohashescobar
2023-03-09 20:49:12 +05:30
committed by GitHub
parent e3e57df4a2
commit 0416e07f46
7 changed files with 57 additions and 43 deletions

7
setup.sh Normal file → Executable file
View File

@@ -1,4 +1,7 @@
# Generating API Server environmental variables
#!/bin/bash
cp ./apiserver/.env.example ./apiserver/.env
# Generating App environmental variables
cp ./apps/app/.env.example ./apps/app/.env
cp ./apps/app/.env.example ./apps/app/.env
echo -e "\nNEXT_PUBLIC_API_BASE_URL=http://$1" >> ./apps/app/.env
echo -e "\nSECRET_KEY=\"$(tr -dc 'a-z0-9!@#$%^&*(-_=+)' < /dev/urandom | head -c50)\"" >> ./apiserver/.env