bigbluebutton-Github/bigbluebutton-html5/dev_local_deployment/mongod_start_pre.sh

15 lines
289 B
Bash
Raw Normal View History

#!/bin/bash
rm -rf /mnt/mongo-ramdisk/*
mkdir -p /mnt/mongo-ramdisk
if /bin/findmnt | grep -q "/mnt/mongo-ramdisk"; then
umount /mnt/mongo-ramdisk/
fi
if [ ! -f /.dockerenv ]; then
mount -t tmpfs -o size=512m tmpfs /mnt/mongo-ramdisk
fi
chown -R mongodb:mongodb /mnt/mongo-ramdisk