P6: Migrate Kiwix and Transmission to Kubernetes #39
2 changed files with 3 additions and 3 deletions
Fix kiwix to read ZIMs from transmission's complete folder
Transmission puts completed downloads in /downloads/complete/, not the root of the downloads directory. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
commit
885b81820b
|
|
@ -22,7 +22,7 @@ spec:
|
|||
|
||||
# Get current ZIM files (among all downloads)
|
||||
# This picks up ZIMs from both declarative list AND manually added torrents
|
||||
current_zims=$(ls -1 /data/*.zim 2>/dev/null | sort | md5sum | cut -d' ' -f1 || echo "empty")
|
||||
current_zims=$(ls -1 /data/complete/*.zim 2>/dev/null | sort | md5sum | cut -d' ' -f1 || echo "empty")
|
||||
|
||||
# Get stored hash from deployment annotation
|
||||
JSONPATH='{.metadata.annotations.kiwix\.blumeops/zim-hash}'
|
||||
|
|
@ -33,7 +33,7 @@ spec:
|
|||
|
||||
# Also list what ZIMs we found
|
||||
echo "ZIM files found:"
|
||||
ls -la /data/*.zim 2>/dev/null || echo " (none)"
|
||||
ls -la /data/complete/*.zim 2>/dev/null || echo " (none)"
|
||||
|
||||
if [[ "$current_zims" != "$stored_hash" && "$current_zims" != "empty" ]]; then
|
||||
echo "ZIM files changed, restarting kiwix deployment..."
|
||||
|
|
|
|||
|
|
@ -23,7 +23,7 @@ spec:
|
|||
image: ghcr.io/kiwix/kiwix-serve:3.8.1
|
||||
command: ["/bin/sh", "-c"]
|
||||
args:
|
||||
- "kiwix-serve --port=80 /data/*.zim"
|
||||
- "kiwix-serve --port=80 /data/complete/*.zim"
|
||||
ports:
|
||||
- containerPort: 80
|
||||
name: http
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue