#!/bin/bash # timezone sed -i '/TZ/d' /var/lib/immich/env sed -i '/documentation/aTZ=Asia\/Shanghai' /var/lib/immich/env # db sed -i 's/YOUR_STRONG_RANDOM_PW/4p4shEvaLuHN5uph/' /var/lib/immich/env sed -i 's/DB_HOSTNAME=127.0.0.1/DB_HOSTNAME=192.168.50.106/' /var/lib/immich/env # redis sed -i 's/REDIS_HOSTNAME=127.0.0.1/REDIS_HOSTNAME=192.168.50.106/' /var/lib/immich/env # service sed -i 'Requires=redis-server.service/d' /var/lib/immich/env sed -i 'Requires=postgresql.service/d' /var/lib/immich/env # 80 port sed -i '/CAP_NET_BIND_SERVICE/d' /lib/systemd/system/immich.service sed -i '/IMMICH_HOST/d' /lib/systemd/system/immich.service sed -i '/IMMICH_HOST/d' /var/lib/immich/env sed -i '/IMMICH_PORT/d' /lib/systemd/system/immich.service sed -i '/UMask/aCapabilityBoundingSet=CAP_NET_BIND_SERVICE' /lib/systemd/system/immich.service sed -i '/CAP_NET_BIND_SERVICE/aAmbientCapabilities=CAP_NET_BIND_SERVICE' /lib/systemd/system/immich.service sed -i '/WorkingDirectory/aEnvironment="IMMICH_HOST=0.0.0.0"' /lib/systemd/system/immich.service sed -i '/IMMICH_HOST/aEnvironment="IMMICH_PORT=80"' /lib/systemd/system/immich.service systemctl daemon-reload systemctl restart immich.service