Compare commits

..

6 Commits

Author SHA1 Message Date
3wc
5d84cef63c app restore
Some checks failed
continuous-integration/drone/pr Build is failing
2021-01-09 13:36:32 +02:00
3wc
eda5198904 Add scaffolding for per-app backup commands
See #70
2021-01-09 13:36:32 +02:00
3wc
a4a3dccd66 Add global --skip-check / --skip-update commands 2021-01-09 13:36:32 +02:00
3wc
a2d249e3a1 Fix abra app ls with * server
All checks were successful
continuous-integration/drone/push Build is passing
2021-01-02 00:34:44 +02:00
dc83baea12
Remove tab
All checks were successful
continuous-integration/drone/push Build is passing
2021-01-01 22:44:21 +01:00
3wc
d6b4a4744f Fix abra app ls for app → type
All checks were successful
continuous-integration/drone/push Build is passing
2021-01-01 23:00:20 +02:00
2 changed files with 5 additions and 5 deletions

8
abra
View File

@ -553,7 +553,7 @@ sub_app_list (){
STATUS="$( [[ $abra___status == "true" ]] && echo "Y" )"
if [ -n "$STATUS" ]; then
if [ -z "$SERVER" ]; then
if [ "$SERVER" = "*" ]; then
get_servers
else
SERVERS=( "$SERVER" )
@ -576,7 +576,7 @@ sub_app_list (){
for i in "${!ENV_FILES[@]}"; do
# Output header inside the loop, so it's included in the pipe to `column`
if [ "$i" == 0 ]; then
printf " DOMAIN\tAPP\tSERVER%s%s\n" "${STATUS:+ }" "${STATUS:+STATUS}"
printf " DOMAIN\tTYPE\tSERVER%s%s\n" "${STATUS:+ }" "${STATUS:+STATUS}"
printf " --\t--\t--%s\n" "${STATUS:+ --}"
fi
@ -590,7 +590,7 @@ sub_app_list (){
set -a
# shellcheck disable=SC1090
APP="$(source "$ENV_FILE" && echo "$APP")"
TYPE="$(source "$ENV_FILE" && echo "$TYPE")"
# shellcheck disable=SC1090
APP_STACK_NAME="$(source "$ENV_FILE" && echo "$STACK_NAME")"
set +a
@ -601,7 +601,7 @@ sub_app_list (){
if [ -n "$STATUS" ]; then
APP_STATUS=$( printf '%s\n' "${DEPLOYED_APPS[@]}" | grep -qP "^${SERVER}~${APP_STACK_NAME}$" && echo "deployed" || echo "inactive")
fi
printf " %s\t%s\t%s%s\n" "$DOMAIN" "$APP" "$SERVER" "${STATUS:+ }${APP_STATUS}"
printf " %s\t%s\t%s%s\n" "$DOMAIN" "$TYPE" "$SERVER" "${STATUS:+ }${APP_STATUS}"
done | column -s' ' -t
# Align table `-t` based on tab characters -s`^V<Tab>`
}

View File

@ -5,7 +5,7 @@ ABRA_SRC="https://git.autonomic.zone/coop-cloud/abra/raw/tag/$ABRA_VERSION/abra"
function install_abra {
mkdir -p "$HOME/.local/bin"
curl "$ABRA_SRC" > "$HOME/.local/bin/abra"
curl "$ABRA_SRC" > "$HOME/.local/bin/abra"
chmod +x "$HOME/.local/bin/abra"
echo "abra installed to $HOME/.loca/bin/abra"
}