minor fix install script

This commit is contained in:
Emmanuel Viennet 2021-05-16 17:03:46 +02:00
parent e52ffb8357
commit 2c5e59120c
3 changed files with 10 additions and 8 deletions

View File

@ -5,9 +5,9 @@
#
[Unit]
Description=ScoDoc 7 service
After=network.target postgresql@11-main.service
Requires=postgresql@11-main.service
PartOf=postgresql@11-main.service
After=network.target postgresql
Requires=postgresql
PartOf=postgresql
StartLimitIntervalSec=0
[Service]
@ -21,4 +21,4 @@ ExecStop=/opt/scodoc/bin/zopectl stop
ExecReload=/opt/scodoc/bin/zopectl restart
[Install]
WantedBy=postgresql@11-main.service
WantedBy=postgresql

View File

@ -32,11 +32,13 @@ fi
chgrp www-data $SCODOC_DIR $SCODOC_DIR/ZopeProducts/*
chmod g+w $SCODOC_DIR $SCODOC_DIR/ZopeProducts/*
chgrp -R www-data "${SCODOC_VAR_DIR}"/photos
chmod -R g+w "${SCODOC_VAR_DIR}"/photos
if [ -d "${SCODOC_VAR_DIR}"/photos ]; then
chgrp -R www-data "${SCODOC_VAR_DIR}"/photos
chmod -R g+w "${SCODOC_VAR_DIR}"/photos
fi
if [ ! -e "${SCODOC_VERSION_DIR}" ]; then
mkdir "${SCODOC_VERSION_DIR}"
mkdir -p "${SCODOC_VERSION_DIR}"
chown www-data.www-data "${SCODOC_VERSION_DIR}"
fi

View File

@ -51,7 +51,7 @@ then
fi
chown root "$DEST"
# Zope DB and ScoDoc archives:
# Zope DB, ScoDoc archives, configuration, photos, etc.
echo "Copying var/ ..."
cp -rp "$INSTANCE_DIR/var" "$DEST"