Various bugfixes and minor enhancements
* typo in .templates/nginx/nginx_static.inc * better ACL comment in .templates/nginx/nginx_xport.inc * missing dependency and wrong order in storage_gitbackup (MediaWiki, WordPress) * wrong order in tools/build * pointless warnings in tools/backup.d/xport_backup.sh * new info file introduced: services/.ports
This commit is contained in:
parent
449a5012a9
commit
31572ffa08
@ -11,6 +11,8 @@
|
|||||||
#
|
#
|
||||||
# Author: Kovács Zoltán <kovacs.zoltan@smartfront.hu>
|
# Author: Kovács Zoltán <kovacs.zoltan@smartfront.hu>
|
||||||
# License: GNU/GPL v3+ (https://www.gnu.org/licenses/gpl-3.0.en.html)
|
# License: GNU/GPL v3+ (https://www.gnu.org/licenses/gpl-3.0.en.html)
|
||||||
|
# 2025-05-20 v0.3
|
||||||
|
# fix: Wrong output redirection order (>/dev/null 2>&1 was reversed).
|
||||||
# 2024-08-25 v0.2
|
# 2024-08-25 v0.2
|
||||||
# new: docker-compose v2 compatibility - tested with Ubuntu 24.04 LTS.
|
# new: docker-compose v2 compatibility - tested with Ubuntu 24.04 LTS.
|
||||||
# mod: Doesn't do backup if the service is down.
|
# mod: Doesn't do backup if the service is down.
|
||||||
@ -72,7 +74,7 @@ while [ -h "$SOURCE" ]; do
|
|||||||
done; SCRPATH="$( cd -P "$("$DIRNAME" "$SOURCE" )" && echo "$PWD" )" #"
|
done; SCRPATH="$( cd -P "$("$DIRNAME" "$SOURCE" )" && echo "$PWD" )" #"
|
||||||
|
|
||||||
# Let's find which version of docker-compose is installed.
|
# Let's find which version of docker-compose is installed.
|
||||||
if [ $($DOCKER compose version 2>&1 >/dev/null; echo $?) -eq 0 ]; then
|
if [ $($DOCKER compose version >/dev/null 2>&1; echo $?) -eq 0 ]; then
|
||||||
# We'll use v2 if it is available.
|
# We'll use v2 if it is available.
|
||||||
DOCKER_COMPOSE="$DOCKER"
|
DOCKER_COMPOSE="$DOCKER"
|
||||||
commandstring="compose"
|
commandstring="compose"
|
||||||
|
@ -11,6 +11,9 @@
|
|||||||
#
|
#
|
||||||
# Author: Kovács Zoltán <kovacs.zoltan@smartfront.hu>
|
# Author: Kovács Zoltán <kovacs.zoltan@smartfront.hu>
|
||||||
# License: GNU/GPL v3+ (https://www.gnu.org/licenses/gpl-3.0.en.html)
|
# License: GNU/GPL v3+ (https://www.gnu.org/licenses/gpl-3.0.en.html)
|
||||||
|
# 2025-05-20 v0.3
|
||||||
|
# fix: The docker itself was missing from the dependency list :(.
|
||||||
|
# fix: Wrong output redirection order (>/dev/null 2>&1 was reversed).
|
||||||
# 2024-08-25 v0.2
|
# 2024-08-25 v0.2
|
||||||
# new: docker-compose v2 compatibility - tested with Ubuntu 24.04 LTS.
|
# new: docker-compose v2 compatibility - tested with Ubuntu 24.04 LTS.
|
||||||
# mod: Doesn't do backup if the service is down.
|
# mod: Doesn't do backup if the service is down.
|
||||||
@ -50,7 +53,7 @@ YMLFILE="docker-compose.yml"
|
|||||||
#
|
#
|
||||||
TR=$(which tr 2>/dev/null)
|
TR=$(which tr 2>/dev/null)
|
||||||
if [ -z "$TR" ]; then echo "$MSG_MISSINGDEP tr."; exit 1 ; fi
|
if [ -z "$TR" ]; then echo "$MSG_MISSINGDEP tr."; exit 1 ; fi
|
||||||
for item in cut date dirname git readlink
|
for item in cut date dirname docker git readlink
|
||||||
do
|
do
|
||||||
if [ -n "$(which $item)" ]
|
if [ -n "$(which $item)" ]
|
||||||
then export $(echo $item | "$TR" '[:lower:]' '[:upper:]')=$(which $item)
|
then export $(echo $item | "$TR" '[:lower:]' '[:upper:]')=$(which $item)
|
||||||
@ -72,7 +75,7 @@ while [ -h "$SOURCE" ]; do
|
|||||||
done; SCRPATH="$( cd -P "$("$DIRNAME" "$SOURCE" )" && echo "$PWD" )" #"
|
done; SCRPATH="$( cd -P "$("$DIRNAME" "$SOURCE" )" && echo "$PWD" )" #"
|
||||||
|
|
||||||
# Let's find which version of docker-compose is installed.
|
# Let's find which version of docker-compose is installed.
|
||||||
if [ $($DOCKER compose version 2>&1 >/dev/null; echo $?) -eq 0 ]; then
|
if [ $($DOCKER compose version >/dev/null 2>&1; echo $?) -eq 0 ]; then
|
||||||
# We'll use v2 if it is available.
|
# We'll use v2 if it is available.
|
||||||
DOCKER_COMPOSE="$DOCKER"
|
DOCKER_COMPOSE="$DOCKER"
|
||||||
commandstring="compose"
|
commandstring="compose"
|
||||||
|
7
.templates/.ports
Normal file
7
.templates/.ports
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
# This is a human-readable summary of the port allocation.
|
||||||
|
# To be maintained manually. You can use it as you like,
|
||||||
|
# it doesn't matter for docker-skeleton automations.
|
||||||
|
|
||||||
|
8100 ACME for SSL certificates
|
||||||
|
|
||||||
|
8201
|
@ -6,5 +6,5 @@
|
|||||||
allow all;
|
allow all;
|
||||||
autoindex off;
|
autoindex off;
|
||||||
index index.html index.htm;
|
index index.html index.htm;
|
||||||
try_files $ri $uri/ =404;
|
try_files $uri $uri/ =404;
|
||||||
}
|
}
|
||||||
|
@ -2,10 +2,11 @@
|
|||||||
#
|
#
|
||||||
# Export backups feature.
|
# Export backups feature.
|
||||||
# Needs
|
# Needs
|
||||||
# setfacl -m u:www-data:r [...]/configs/xport_backup
|
# setfacl -m u:www-data:r configs/xport_backup
|
||||||
# setfacl -m u:www-data:rx [...]/storage/backups
|
# chmod a-x configs/xport_backup
|
||||||
# setfacl -m u:www-data:rx [...]/storage/backups/export
|
# setfacl -m u:www-data:rx storage/backups
|
||||||
# setfacl -d -m u:www-data:r [...]/storage/backups/export
|
# setfacl -m u:www-data:rx storage/backups/export
|
||||||
|
# setfacl -d -m u:www-data:r storage/backups/export
|
||||||
# ACLs.
|
# ACLs.
|
||||||
location /export {
|
location /export {
|
||||||
root $PAR_SERVICE/storage/backups;
|
root $PAR_SERVICE/storage/backups;
|
||||||
|
@ -10,6 +10,8 @@
|
|||||||
#
|
#
|
||||||
# Author: Kovács Zoltán <kovacsz@marcusconsulting.hu>
|
# Author: Kovács Zoltán <kovacsz@marcusconsulting.hu>
|
||||||
# License: GNU/GPL v3+ (https://www.gnu.org/licenses/gpl-3.0.en.html)
|
# License: GNU/GPL v3+ (https://www.gnu.org/licenses/gpl-3.0.en.html)
|
||||||
|
# 2025-04-02 v0.2
|
||||||
|
# fix: Omits all warnings about missing source folder(s).
|
||||||
# 2025-03-06 v0.1 Initial release
|
# 2025-03-06 v0.1 Initial release
|
||||||
|
|
||||||
# Accepted environment variables and their defaults.
|
# Accepted environment variables and their defaults.
|
||||||
@ -92,7 +94,7 @@ do
|
|||||||
# Selects the appropriate files (which have the "DR" - daily retain - tag).
|
# Selects the appropriate files (which have the "DR" - daily retain - tag).
|
||||||
for filename in $((export CLASSES_PATTERN="$CLASSES_PATTERN" \
|
for filename in $((export CLASSES_PATTERN="$CLASSES_PATTERN" \
|
||||||
RETAIN_DAYS="$PAR_RETAINDAYS" RETAIN_WEEKS=0 RETAIN_MONTHS=0; \
|
RETAIN_DAYS="$PAR_RETAINDAYS" RETAIN_WEEKS=0 RETAIN_MONTHS=0; \
|
||||||
"$ROTATE_FOLDER" --noconf -f "$folder") | \
|
"$ROTATE_FOLDER" --noconf -f "$folder" 2>/dev/null) | \
|
||||||
"$GREP" '^DR ' | "$CUT" -d' ' -f2) ""
|
"$GREP" '^DR ' | "$CUT" -d' ' -f2) ""
|
||||||
do
|
do
|
||||||
# Updates the current file.
|
# Updates the current file.
|
||||||
|
@ -8,6 +8,8 @@
|
|||||||
# Author: Kovács Zoltán <kovacs.zoltan@smartfront.hu>
|
# Author: Kovács Zoltán <kovacs.zoltan@smartfront.hu>
|
||||||
# Kovács Zoltán <kovacsz@marcusconsulting.hu>
|
# Kovács Zoltán <kovacsz@marcusconsulting.hu>
|
||||||
# License: GNU/GPL v3+ (https://www.gnu.org/licenses/gpl-3.0.en.html)
|
# License: GNU/GPL v3+ (https://www.gnu.org/licenses/gpl-3.0.en.html)
|
||||||
|
# 2025-03-21 v1.2
|
||||||
|
# fix: wrong output redirection order in docker compose.
|
||||||
# 2024-08-24 v1.1
|
# 2024-08-24 v1.1
|
||||||
# new: docker-compose v2 compatibility - tested with Ubuntu 24.04 LTS.
|
# new: docker-compose v2 compatibility - tested with Ubuntu 24.04 LTS.
|
||||||
# 2023-06-18 v1.0
|
# 2023-06-18 v1.0
|
||||||
@ -39,7 +41,7 @@ done
|
|||||||
#
|
#
|
||||||
# Let's find which version of docker-compose is installed.
|
# Let's find which version of docker-compose is installed.
|
||||||
commandstring=""
|
commandstring=""
|
||||||
if [ $($DOCKER compose version 2>&1 >/dev/null; echo $?) -eq 0 ]; then
|
if [ $($DOCKER compose version >/dev/null 2>&1; echo $?) -eq 0 ]; then
|
||||||
# We'll use v2 if it is available.
|
# We'll use v2 if it is available.
|
||||||
DOCKER_COMPOSE="$DOCKER"
|
DOCKER_COMPOSE="$DOCKER"
|
||||||
commandstring="compose"
|
commandstring="compose"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user