general way to copy assets using env variables
This commit is contained in:
parent
dd47cb56f6
commit
1dc2ba18d4
|
@ -33,3 +33,4 @@ AUTHENTIK_COLOR_BACKGROUND_LIGHT=#1c1e21
|
||||||
WELCOME_MESSAGE="Welcome to Authentik"
|
WELCOME_MESSAGE="Welcome to Authentik"
|
||||||
DEFAULT_LANGUAGE=en
|
DEFAULT_LANGUAGE=en
|
||||||
AUTHENTIK_FOOTER_LINKS='[{"name": "My Organization","href":"https://example.com"}]'
|
AUTHENTIK_FOOTER_LINKS='[{"name": "My Organization","href":"https://example.com"}]'
|
||||||
|
COPY_ASSETS="flow_background.jpg|app:/web/dist/assets/images/ icon_left_brand.svg|app:/web/dist/assets/icons/ icon.png|app:/web/dist/assets/icons/"
|
||||||
|
|
23
abra.sh
23
abra.sh
|
@ -7,22 +7,13 @@ customize() {
|
||||||
echo "Usage: ... customize <assets_path>"
|
echo "Usage: ... customize <assets_path>"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
# TODO: use env to specify source and target files
|
asset_dir=$1
|
||||||
if [ -e $1/flow_background.jpg ]
|
for asset in $COPY_ASSETS; do
|
||||||
then
|
source=$(echo $asset | cut -d "|" -f1)
|
||||||
echo copy flow_background.jpg
|
target=$(echo $asset | cut -d "|" -f2)
|
||||||
abra app cp $APP_NAME $1/flow_background.jpg app:/web/dist/assets/images/
|
echo copy $source to $target
|
||||||
fi
|
abra app cp $APP_NAME $asset_dir/$source $target
|
||||||
if [ -e $1/icon_left_brand.svg ]
|
done
|
||||||
then
|
|
||||||
echo copy icon_left_brand.svg
|
|
||||||
abra app cp $APP_NAME $1/icon_left_brand.svg app:/web/dist/assets/icons/
|
|
||||||
fi
|
|
||||||
if [ -e $1/icon.png ]
|
|
||||||
then
|
|
||||||
echo copy icon.png
|
|
||||||
abra app cp $APP_NAME $1/icon.png app:/web/dist/assets/icons/
|
|
||||||
fi
|
|
||||||
}
|
}
|
||||||
|
|
||||||
set_admin_pass() {
|
set_admin_pass() {
|
||||||
|
|
Loading…
Reference in New Issue