Update photoprism-install.sh
This commit is contained in:
parent
6263fc6f7b
commit
da171df9b6
1 changed files with 19 additions and 19 deletions
|
@ -104,28 +104,28 @@ sudo cp -a assets/ /opt/photoprism/assets/
|
||||||
sudo chown -R photoprism:photoprism /opt/photoprism
|
sudo chown -R photoprism:photoprism /opt/photoprism
|
||||||
echo -e "${CM}${CL} \r"
|
echo -e "${CM}${CL} \r"
|
||||||
|
|
||||||
echo -en "${GN} Creating Service file photoprism.service... "
|
#echo -en "${GN} Creating Service file photoprism.service... "
|
||||||
service_path="/etc/systemd/system/photoprism.service"
|
#service_path="/etc/systemd/system/photoprism.service"
|
||||||
|
|
||||||
echo "[Unit]
|
#echo "[Unit]
|
||||||
Description=PhotoPrism service
|
#Description=PhotoPrism service
|
||||||
After=network.target
|
#After=network.target
|
||||||
|
|
||||||
[Service]
|
#[Service]
|
||||||
Type=forking
|
#Type=forking
|
||||||
User=photoprism
|
#User=photoprism
|
||||||
Group=photoprism
|
#Group=photoprism
|
||||||
WorkingDirectory=/opt/photoprism
|
#WorkingDirectory=/opt/photoprism
|
||||||
EnvironmentFile=/var/lib/photoprism/.env
|
#EnvironmentFile=/var/lib/photoprism/.env
|
||||||
ExecStart=/opt/photoprism/bin/photoprism up -d
|
#ExecStart=/opt/photoprism/bin/photoprism up -d
|
||||||
ExecStop=/opt/photoprism/bin/photoprism down
|
#ExecStop=/opt/photoprism/bin/photoprism down
|
||||||
|
|
||||||
[Install]
|
#[Install]
|
||||||
WantedBy=multi-user.target" > $service_path
|
#WantedBy=multi-user.target" > $service_path
|
||||||
sudo systemctl daemon-reload
|
#sudo systemctl daemon-reload
|
||||||
sudo systemctl start photoprism
|
#sudo systemctl start photoprism
|
||||||
sudo systemctl enable photoprism &>/dev/null
|
#sudo systemctl enable photoprism &>/dev/null
|
||||||
echo -e "${CM}${CL} \r"
|
#echo -e "${CM}${CL} \r"
|
||||||
|
|
||||||
PASS=$(grep -w "root" /etc/shadow | cut -b6);
|
PASS=$(grep -w "root" /etc/shadow | cut -b6);
|
||||||
if [[ $PASS != $ ]]; then
|
if [[ $PASS != $ ]]; then
|
||||||
|
|
Loading…
Reference in a new issue