Skip to content

Commit 0a25106

Browse files
authored
Open Archiver: Fix missing command in update procedure (#8765)
* Fix update * Update * Update * Update service file
1 parent 2cfe936 commit 0a25106

File tree

2 files changed

+8
-3
lines changed

2 files changed

+8
-3
lines changed

ct/open-archiver.sh

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,11 +38,16 @@ function update_script() {
3838
mv /opt/openarchiver.env /opt/openarchiver/.env
3939

4040
msg_info "Updating Open Archiver"
41+
cd /opt/openarchiver
4142
$STD pnpm install --shamefully-hoist --frozen-lockfile --prod=false
42-
$STD pnpm build
43+
$STD pnpm run build:oss
4344
$STD pnpm db:migrate
4445
msg_ok "Updated Open Archiver"
4546

47+
if grep -q '^ExecStart=/usr/bin/pnpm docker-start$' /etc/systemd/system/openarchiver.service; then
48+
sed -i 's|^ExecStart=/usr/bin/pnpm docker-start$|ExecStart=/usr/bin/pnpm docker-start:oss|' /etc/systemd/system/openarchiver.service
49+
fi
50+
4651
msg_info "Starting Services"
4752
systemctl start openarchiver
4853
msg_ok "Started Services"

install/open-archiver-install.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ sed -i "s|^ENCRYPTION_KEY=.*|ENCRYPTION_KEY=$SECRET_KEY|g" /opt/openarchiver/.en
9090
sed -i "s|^TIKA_URL=.*|TIKA_URL=|g" /opt/openarchiver/.env
9191
echo "ORIGIN=http://$IP_ADDR:3000" >> /opt/openarchiver/.env
9292
$STD pnpm install --shamefully-hoist --frozen-lockfile --prod=false
93-
$STD pnpm build
93+
$STD pnpm run build:oss
9494
$STD pnpm db:migrate
9595
msg_ok "Setup Open Archiver"
9696

@@ -105,7 +105,7 @@ Type=simple
105105
User=root
106106
EnvironmentFile=/opt/openarchiver/.env
107107
WorkingDirectory=/opt/openarchiver
108-
ExecStart=/usr/bin/pnpm docker-start
108+
ExecStart=/usr/bin/pnpm docker-start:oss
109109
Restart=on-failure
110110
111111
[Install]

0 commit comments

Comments
 (0)