modified: start.sh
Set to hardcoded mountpoints rather than variables, as these need to be hardcoded in the container image anyway
This commit is contained in:
parent
604ed39d7c
commit
32d5885669
12
start.sh
12
start.sh
@ -8,16 +8,16 @@ dd if=/dev/zero of=/ramdisk/image.ext4 count=0 bs=1 seek=400M
|
||||
echo -e 'Create filesystem on ramdisk file'
|
||||
mkfs.ext4 /ramdisk/image.ext4
|
||||
echo -e 'Mount the ramdisk file to /mnt/sonarr-ramdisk-mount'
|
||||
mount /ramdisk/image.ext4 $RAMDISK_MOUNT_DIR
|
||||
mount /ramdisk/image.ext4 /mnt/db-ramdisk-mount
|
||||
echo -e 'Initial copy of the config from the remote share to the ramdisk'
|
||||
cp -fvp $APP_CONFIG_DIR/*.* $RAMDISK_MOUNT_DIR
|
||||
cp -fvp /perm-config/*.* /mnt/db-ramdisk-mount
|
||||
echo -e 'Set up the filesystem freeze, copy, unfreeze loop'
|
||||
while true; do
|
||||
sleep 890
|
||||
date
|
||||
sync $RAMDISK_MOUNT_DIR/*.*
|
||||
fsfreeze --freeze $RAMDISK_MOUNT_DIR
|
||||
sync /mnt/db-ramdisk-mount/*.*
|
||||
fsfreeze --freeze /mnt/db-ramdisk-mount
|
||||
sleep 10
|
||||
cp -fvp $RAMDISK_MOUNT_DIR/*.* $APP_CONFIG_DIR/
|
||||
fsfreeze --unfreeze $RAMDISK_MOUNT_DIR
|
||||
cp -fvp /mnt/db-ramdisk-mount/*.* /perm-config/
|
||||
fsfreeze --unfreeze /mnt-ramdisk-mount
|
||||
done
|
||||
|
||||
Loading…
Reference in New Issue
Block a user