mirror of
https://github.com/chevereto/docker.git
synced 2026-01-19 13:42:05 +01:00
20 lines
601 B
Bash
Executable File
20 lines
601 B
Bash
Executable File
#!/usr/bin/env bash
|
|
set -e
|
|
SOURCE=/var/www/chevereto/
|
|
TARGET=/var/www/html/
|
|
EXCLUDE="\.git|\.DS_Store|\.well-known|\.vscode|\/app\/vendor|\/app\/env\.php|\/app\/importer\/jobs"
|
|
[ -d "${SOURCE}"app/vendor/ ] && rsync --mkpath -a "${SOURCE}"app/vendor/ "${TARGET}"app/vendor/
|
|
cp "${SOURCE}".gitignore "${TARGET}".gitignore
|
|
function sync() {
|
|
rsync -r -I -og \
|
|
--chown=www-data:www-data \
|
|
--info=progress2 \
|
|
--filter=':- .gitignore' \
|
|
--exclude '.git' \
|
|
--exclude '.well-known' \
|
|
--exclude '_assets/' \
|
|
--delete \
|
|
$SOURCE $TARGET
|
|
}
|
|
sync
|