Corrige le payload de mise à jour Proxmox
This commit is contained in:
@@ -382,7 +382,7 @@ rsync -a --delete \
|
|||||||
\"\$repo_dir/\" \"\$web_root/\"
|
\"\$repo_dir/\" \"\$web_root/\"
|
||||||
|
|
||||||
while IFS= read -r -d '' html_file; do
|
while IFS= read -r -d '' html_file; do
|
||||||
perl -0pi -e 's{((?:href|src)=\")(?!https?://|data:|//)([^\"?]+?\.(?:css|js|png|jpg|jpeg|svg|webp|ico|pdf))(?:\?[^"]*)?(\")}{\$1 . \$2 . \"?v='"\"\$asset_version\""'\" . \$3}ge' \"\$html_file\"
|
ASSET_VERSION=\"\$asset_version\" perl -0pi -e 's{((?:href|src)=\")(?!https?://|data:|//)([^\"?]+?\.(?:css|js|png|jpg|jpeg|svg|webp|ico|pdf))(?:\?[^\"]*)?(\")}{\$1 . \$2 . \"?v=\" . \$ENV{ASSET_VERSION} . \$3}ge' \"\$html_file\"
|
||||||
done < <(find \"\$web_root\" -maxdepth 1 -type f -name '*.html' -print0)
|
done < <(find \"\$web_root\" -maxdepth 1 -type f -name '*.html' -print0)
|
||||||
|
|
||||||
chown -R www-data:www-data \"\$web_root\"
|
chown -R www-data:www-data \"\$web_root\"
|
||||||
|
|||||||
@@ -203,7 +203,7 @@ rsync -a --delete \
|
|||||||
\"\$repo_dir/\" \"\$web_root/\"
|
\"\$repo_dir/\" \"\$web_root/\"
|
||||||
|
|
||||||
while IFS= read -r -d '' html_file; do
|
while IFS= read -r -d '' html_file; do
|
||||||
perl -0pi -e 's{((?:href|src)=\")(?!https?://|data:|//)([^\"?]+?\.(?:css|js|png|jpg|jpeg|svg|webp|ico|pdf))(?:\?[^"]*)?(\")}{\$1 . \$2 . \"?v='"\"\$asset_version\""'\" . \$3}ge' \"\$html_file\"
|
ASSET_VERSION=\"\$asset_version\" perl -0pi -e 's{((?:href|src)=\")(?!https?://|data:|//)([^\"?]+?\.(?:css|js|png|jpg|jpeg|svg|webp|ico|pdf))(?:\?[^\"]*)?(\")}{\$1 . \$2 . \"?v=\" . \$ENV{ASSET_VERSION} . \$3}ge' \"\$html_file\"
|
||||||
done < <(find \"\$web_root\" -maxdepth 1 -type f -name '*.html' -print0)
|
done < <(find \"\$web_root\" -maxdepth 1 -type f -name '*.html' -print0)
|
||||||
|
|
||||||
chown -R www-data:www-data \"\$web_root\"
|
chown -R www-data:www-data \"\$web_root\"
|
||||||
|
|||||||
Reference in New Issue
Block a user