install fastfetch and only show fastfetch when installed and fix update alias and building of spaceing
Build and Push Docker Container / build-and-push (push) Successful in 1m17s

This commit is contained in:
2026-04-12 00:52:00 +02:00
parent 04cd1a4ee3
commit dc27d4ea69
3 changed files with 23 additions and 15 deletions
+1 -1
View File
@@ -10,7 +10,7 @@ ENV RUN_PROMETHEUS_EXPORTER="false"
ENV TZ="" ENV TZ=""
RUN apk add --no-cache \ RUN apk add --no-cache \
bash sudo openssh-server shadow tzdata curl git dcron coreutils grep sed gawk util-linux ca-certificates tmux prometheus-node-exporter \ bash sudo openssh-server shadow tzdata curl git dcron coreutils grep sed gawk util-linux ca-certificates tmux fastfetch prometheus-node-exporter \
borgbackup \ borgbackup \
&& mkdir -p \ && mkdir -p \
/.ssh \ /.ssh \
+11 -7
View File
@@ -3,7 +3,7 @@ if [ ! -z $(cat /etc/environment | grep "USE_TMUX_SHELL") ] && [[ -t 0 ]] && [ -
exit exit
fi fi
alias update='sudo pacman -Syu --noconfirm' alias update='sudo apk update && sudo apk upgrade'
export HISTTIMEFORMAT="%d/%m/%y %T " export HISTTIMEFORMAT="%d/%m/%y %T "
export PS1='\u@\h:\W \$ ' export PS1='\u@\h:\W \$ '
@@ -14,19 +14,23 @@ alias ll='ls -alF'
alias ls='ls --color=auto' alias ls='ls --color=auto'
export PS1="\[\e[31m\][\[\e[m\]\[\e[38;5;172m\]\u\[\e[m\]@\[\e[38;5;153m\]\h\[\e[m\] \[\e[38;5;214m\]\W\[\e[m\]\[\e[31m\]]\[\e[m\]\\$ " export PS1="\[\e[31m\][\[\e[m\]\[\e[38;5;172m\]\u\[\e[m\]@\[\e[38;5;153m\]\h\[\e[m\] \[\e[38;5;214m\]\W\[\e[m\]\[\e[31m\]]\[\e[m\]\\$ "
############################################################################################################################## ###############################################################################
# Functions # Functions
############################################################################################################################## ###############################################################################
source "/variables.sh" source "/variables.sh"
COLUMNS=$(/usr/bin/tput cols) if command -v tput >/dev/null 2>&1; then
COLUMNS=$(tput cols)
fi
function print_container_info { function print_container_info {
sepurator sepurator
echo "BorgServer powered by $BORG_VERSION - Image Hostname: $HOSTNAME | Image Version: $DOCKER_IMAGE_VERSION" echo "BorgServer powered by $BORG_VERSION - Image Hostname: $HOSTNAME | Image Version: $DOCKER_IMAGE_VERSION"
sepurator sepurator
} }
############################################################################################################################## ###############################################################################
# Run Code # Run Code
############################################################################################################################## ###############################################################################
print_container_info print_container_info
fastfetch --config neofetch if command -v fastfetch >/dev/null 2>&1; then
fastfetch --config neofetch
fi
+11 -7
View File
@@ -1,4 +1,4 @@
alias update='pacman -Syu --noconfirm' alias update='apk update && apk upgrade'
export HISTTIMEFORMAT="%d/%m/%y %T " export HISTTIMEFORMAT="%d/%m/%y %T "
export PS1='\u@\h:\W \$ ' export PS1='\u@\h:\W \$ '
@@ -9,11 +9,13 @@ alias ll='ls -alF'
alias ls='ls --color=auto' alias ls='ls --color=auto'
export PS1="\[\e[31m\][\[\e[m\]\[\e[38;5;172m\]\u\[\e[m\]@\[\e[38;5;153m\]\h\[\e[m\] \[\e[38;5;214m\]\W\[\e[m\]\[\e[31m\]]\[\e[m\]\\$ " export PS1="\[\e[31m\][\[\e[m\]\[\e[38;5;172m\]\u\[\e[m\]@\[\e[38;5;153m\]\h\[\e[m\] \[\e[38;5;214m\]\W\[\e[m\]\[\e[31m\]]\[\e[m\]\\$ "
############################################################################################################################## ###############################################################################
# Borg Repo finder # Borg Repo finder
############################################################################################################################## ###############################################################################
source "/variables.sh" source "/variables.sh"
COLUMNS=$(/usr/bin/tput cols) if command -v tput >/dev/null 2>&1; then
COLUMNS=$(tput cols)
fi
function find_borg_repo { function find_borg_repo {
repo_list=( $(find "$1" -name "index.*" -type f | rev | cut -d '/' -f "2-" | rev) ) repo_list=( $(find "$1" -name "index.*" -type f | rev | cut -d '/' -f "2-" | rev) )
@@ -84,9 +86,9 @@ function print_container_info {
echo "BorgServer powered by $BORG_VERSION - Image Hostname: $HOSTNAME | Image Version: $DOCKER_IMAGE_VERSION" echo "BorgServer powered by $BORG_VERSION - Image Hostname: $HOSTNAME | Image Version: $DOCKER_IMAGE_VERSION"
sepurator sepurator
} }
############################################################################################################################## ###############################################################################
# Run Code # Run Code
############################################################################################################################## ###############################################################################
if [ "$INTERACTIVE_MODE" != "false" ]; then if [ "$INTERACTIVE_MODE" != "false" ]; then
find_borg_repo /backups/ find_borg_repo /backups/
export BORG_REPO="${repo_list[selected_repo]}" export BORG_REPO="${repo_list[selected_repo]}"
@@ -97,4 +99,6 @@ if [ "$INTERACTIVE_MODE" != "false" ]; then
fi fi
print_container_info print_container_info
fastfetch --config neofetch if command -v fastfetch >/dev/null 2>&1; then
fastfetch --config neofetch
fi