This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| table ip nat { | |
| chain DOCKER { | |
| iifname "docker0" counter return | |
| iifname "br-matomo" counter return | |
| ip daddr 127.0.0.2 iifname != "br-matomo" tcp dport 8080 counter dnat to 172.30.0.3:80 | |
| } | |
| chain PREROUTING { | |
| type nat hook prerouting priority dstnat; policy accept; | |
| fib daddr type local counter jump DOCKER |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| script_path="$(dirname "$(realpath "${0}")")" | |
| cd "${script_path}"||exit 1 | |
| stitky_vystup_slozka="${script_path}/output/stitky" | |
| qr_vystup_slozka="${script_path}/output/qr" | |
| template="${script_path}/stitek.svg" | |
| # mazání starých štítků a qr kódů | |
| find "${script_path}/output" -type f -delete |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| # priklad: generuj_qr_platbu.sh 1000.00 CZK 20240824 Notix | |
| castka="${1}" | |
| mena="${2}" | |
| faktura="${3}" | |
| odberatel="${4}" | |
| format='SPD*1.0' | |
| IBAN='CZ3330300000003106065017' | |
| BANKA='AIRACZPP' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (shared_settings_static) { | |
| encode zstd gzip | |
| file_server { | |
| precompressed zstd br gzip | |
| } | |
| import logging | |
| header Strict-Transport-Security "max-age=63072000; includeSubDomains; preload" | |
| header X-XSS-Protection "1; mode=block" | |
| header X-Frame-Options DENY | |
| header Content-Security-Policy "upgrade-insecure-requests;" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (strip-www) { | |
| @www.{args[0]} host www.{args[0]} | |
| redir @www.{args[0]} {scheme}://{args[0]}{uri} 308 | |
| } | |
| (add-www) { | |
| @{args[0]} host {args[0]} | |
| redir @{args[0]} {scheme}://www.{args[0]}{uri} 308 | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (logins) { | |
| franta $2a$14$Z7r89DNih.WfqMbw9K/vkuSfp7pQi10ws1MND4KsktZ1hbJtOCFNK | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (logging) { | |
| log { | |
| output file /var/log/caddy/access.log { | |
| roll_size 1gb | |
| roll_keep 1 | |
| roll_keep_for 720h | |
| } | |
| } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| if ! command -v curl; then apt -y install curl; fi | |
| curl https://dl.cloudsmith.io/public/caddy/stable/gpg.key > /etc/apt/trusted.gpg.d/caddy.asc | |
| echo 'deb [signed-by=/etc/apt/trusted.gpg.d/caddy.asc] https://dl.cloudsmith.io/public/caddy/stable/deb/debian any-version main' >/etc/apt/sources.list.d/caddy.list | |
| chmod 644 /etc/apt/{trusted.gpg.d/caddy.asc,sources.list.d/caddy.list} | |
| apt update | |
| apt install caddy -y | |
| exit |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| MSSQL_HOST="localhost" | |
| BACKUP_DIR="/data/mssql/backup/" | |
| BACKUP_DAYS=4 | |
| MSSQL_USER="sa" | |
| MSSQL_PASS='' | |
| MSSQL_EXEC="/opt/mssql-tools/bin/sqlcmd" | |
| DATE="$(date +%Y%m%d)" | |
| # Set Backup Parameters |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| optidir="$*" | |
| fronta="$(mktemp)" | |
| find "${optidir}/" -type f -iname *.jpg -exec du -a {} + | sort -n -r | cut -f 2 >"$fronta" | |
| while read line | |
| do | |
| printf "%s\n" "$line" |
NewerOlder