Ensure newly required settings

This commit is contained in:
Johannes Zellner 2023-12-24 12:46:54 +01:00
parent e6c37a102f
commit b97e25852c
2 changed files with 14 additions and 2 deletions

View file

@ -76,12 +76,13 @@ email:
storage: storage:
tmp: '/app/data/storage/tmp/' # Use to download data (imports etc), store uploaded files before processing... tmp: '/app/data/storage/tmp/' # Use to download data (imports etc), store uploaded files before processing...
avatars: '/app/data/storage/avatars/' avatars: '/app/data/storage/avatars/'
videos: '/app/data/storage/videos/' web_videos: '/app/data/storage/web-videos/'
streaming_playlists: '/app/data/storage/streaming-playlists/' streaming_playlists: '/app/data/storage/streaming-playlists/'
redundancy: '/app/data/storage/redundancy/' redundancy: '/app/data/storage/redundancy/'
logs: '/app/data/storage/logs/' logs: '/app/data/storage/logs/'
previews: '/app/data/storage/previews/' previews: '/app/data/storage/previews/'
thumbnails: '/app/data/storage/thumbnails/' thumbnails: '/app/data/storage/thumbnails/'
storyboards: '/app/data/storage/storyboards/'
torrents: '/app/data/storage/torrents/' torrents: '/app/data/storage/torrents/'
captions: '/app/data/storage/captions/' captions: '/app/data/storage/captions/'
cache: '/app/data/storage/cache/' cache: '/app/data/storage/cache/'
@ -240,7 +241,7 @@ transcoding:
# Generate videos in a WebTorrent format (what we do since the first PeerTube release) # Generate videos in a WebTorrent format (what we do since the first PeerTube release)
# If you also enabled the hls format, it will multiply videos storage by 2 # If you also enabled the hls format, it will multiply videos storage by 2
# If disabled, breaks federation with PeerTube instances < 2.1 # If disabled, breaks federation with PeerTube instances < 2.1
webtorrent: web_videos:
enabled: true enabled: true
# /!\ Requires ffmpeg >= 4.1 # /!\ Requires ffmpeg >= 4.1

View file

@ -77,6 +77,17 @@ update_config() {
yq eval ".storage.bin = \"/app/data/storage/bin/\"" -i /app/data/production.yaml yq eval ".storage.bin = \"/app/data/storage/bin/\"" -i /app/data/production.yaml
yq eval ".storage.well_known = \"/app/data/storage/well_known/\"" -i /app/data/production.yaml yq eval ".storage.well_known = \"/app/data/storage/well_known/\"" -i /app/data/production.yaml
yq eval ".storage.tmp_persistent = \"/app/data/storage/tmp_persistent/\"" -i /app/data/production.yaml yq eval ".storage.tmp_persistent = \"/app/data/storage/tmp_persistent/\"" -i /app/data/production.yaml
# changes for 6.0.0
yq eval ".storage.storyboards = \"/app/data/storage/storyboards/\"" -i /app/data/production.yaml
if [[ -d "/app/data/storage/videos" ]]; then
echo "==> Migrate videos/ to videos-web/"
mv /app/data/storage/videos /app/data/storage/web-videos
fi
yq eval ".storage.web_videos = \"/app/data/storage/web-videos/\"" -i /app/data/production.yaml
yq eval "del(.storage.videos)" -i /app/data/production.yaml
yq eval "del(.transcoding.webtorrent)" -i /app/data/production.yaml
yq eval ".transcoding.web_videos.enabled = true" -i /app/data/production.yaml
} }
echo "==> Changing ownership" echo "==> Changing ownership"