1
0
mirror of https://github.com/pgbackrest/pgbackrest.git synced 2026-05-22 10:15:16 +02:00

Mount tmpfs in Vagrantfile instead test.pl.

Mounting/unmounting tmpfs on /home/[user]/test takes time, forces at least 3GB of memory to be available for tests, and makes it harder to preserve data between tests.

Instead, move mounting of tmpfs to the Vagrantfile and add it to fstab so it survives reboots.
This commit is contained in:
David Steele
2018-11-02 08:37:27 -04:00
parent 34c63276cd
commit 1a98bd41b4
3 changed files with 15 additions and 3 deletions
+7
View File
@@ -46,6 +46,13 @@ Vagrant.configure(2) do |config|
sudo /etc/init.d/virtualbox-guest-utils stop
sudo /usr/sbin/VBoxService --timesync-set-on-restore --timesync-interval 5000 --timesync-set-threshold 1
# Mount tmpfs at /home/vagrant/test for faster testing
#---------------------------------------------------------------------------------------------------------------------------
echo 'Mount tmpfs' && date
sudo -u vagrant mkdir -p -m 770 /home/vagrant/test
echo 'tmpfs /home/vagrant/test tmpfs size=2560M 0 1' >> /etc/fstab
mount -a
#---------------------------------------------------------------------------------------------------------------------------
echo 'Install Perl Modules' && date
apt-get install -y libdbd-pg-perl libio-socket-ssl-perl libxml-libxml-perl libxml-checker-perl libperl-critic-perl \