www in docker support
This commit is contained in:
parent
539a848e95
commit
c227fce036
2145 changed files with 399596 additions and 58 deletions
48
local-jsp-docker/tomcat/bootstrap-docbase.sh
Normal file
48
local-jsp-docker/tomcat/bootstrap-docbase.sh
Normal file
|
|
@ -0,0 +1,48 @@
|
|||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
docbase="${LOCAL_DOCBASE:-/data/docbase/}"
|
||||
workspace_www="/workspace/www"
|
||||
workspace_pkl="/workspace/test_pkl"
|
||||
|
||||
mkdir -p \
|
||||
"${docbase}" \
|
||||
"${docbase}_tmp" \
|
||||
"${docbase}_logs" \
|
||||
"${docbase}admin/csv" \
|
||||
"${docbase}_help/attach" \
|
||||
"${docbase}_help/export" \
|
||||
"${docbase}_help/img"
|
||||
|
||||
link_into_docbase() {
|
||||
local source_path="$1"
|
||||
local target_path="$2"
|
||||
|
||||
rm -rf "$target_path"
|
||||
ln -s "$source_path" "$target_path"
|
||||
}
|
||||
|
||||
if [ -d "${workspace_www}/mailMessage" ]; then
|
||||
link_into_docbase "${workspace_www}/mailMessage" "${docbase}mailMessage"
|
||||
fi
|
||||
|
||||
for subdir in _attach _csv _docs _img _imgMsg csv pics images pdf Templates tmp; do
|
||||
if [ -e "${workspace_www}/${subdir}" ]; then
|
||||
link_into_docbase "${workspace_www}/${subdir}" "${docbase}${subdir}"
|
||||
fi
|
||||
done
|
||||
|
||||
if [ -d "${workspace_pkl}" ]; then
|
||||
link_into_docbase "${workspace_pkl}" "${docbase}test_pkl"
|
||||
|
||||
for subdir in 2026 live test_images; do
|
||||
if [ -e "${workspace_pkl}/${subdir}" ]; then
|
||||
link_into_docbase "${workspace_pkl}/${subdir}" "${docbase}${subdir}"
|
||||
fi
|
||||
done
|
||||
|
||||
# Common generic aliases for code that expects a mounted external storage root.
|
||||
for alias_name in storage nas archive pkl RUS; do
|
||||
link_into_docbase "${workspace_pkl}" "${docbase}${alias_name}"
|
||||
done
|
||||
fi
|
||||
Loading…
Add table
Add a link
Reference in a new issue