71d8e49a3d
* fix: fixed transaction messages (#792) * Open Source + Docker image (#793) * feat: added dummy charting library * feat: added docker workflow * feat: remove tests and code-coverage * feat: added final TradingView fallback * env: set private to false * fix: added production env * env: added README and LICENSE * env: cleanup variables * env: add license field * env: finish docker setup * fix: updated the description of the dummy data
30 lines
877 B
Bash
Executable File
30 lines
877 B
Bash
Executable File
#!/bin/bash
|
|
# no verbose
|
|
set +x
|
|
nextFolder='/app/.next'
|
|
# create the config file from environment variables
|
|
envFilename='override.conf'
|
|
echo "APP_NEXT_OSMOSIS_RPC=$URL_OSMOSIS_RPC" >> $envFilename
|
|
echo "APP_NEXT_OSMOSIS_REST=$URL_OSMOSIS_REST" >> $envFilename
|
|
echo "APP_NEXT_WALLET_CONNECT_ID=$WALLET_CONNECT_ID" >> $envFilename
|
|
|
|
function apply_path {
|
|
# read all config file
|
|
while read line; do
|
|
# no comment or not empty
|
|
if [ "${line:0:1}" == "#" ] || [ "${line}" == "" ]; then
|
|
continue
|
|
fi
|
|
|
|
# split
|
|
configName="$(cut -d'=' -f1 <<<"$line")"
|
|
configValue="$(cut -d'=' -f2 <<<"$line")"
|
|
|
|
# replace all config values in built app with the ones defined in override
|
|
find $nextFolder \( -type d -name .git -prune \) -o -type f -print0 | xargs -0 sed -i "s#$configName#$configValue#g"
|
|
|
|
done < $envFilename
|
|
}
|
|
apply_path
|
|
exec "$@"
|