From 609a43691c411fa65a5008a556ababce257f0ed3 Mon Sep 17 00:00:00 2001 From: meaz Date: Thu, 2 Jan 2020 19:08:21 +0100 Subject: [PATCH] Update vargrant readme + languag plugin installation from our repo --- vagrant/README.md | 13 +++++++++++-- vagrant/Vagrantfile | 3 ++- vagrant/bootstrap.sh | 8 +++++++- 3 files changed, 20 insertions(+), 4 deletions(-) diff --git a/vagrant/README.md b/vagrant/README.md index 42a103d8..61e066b1 100644 --- a/vagrant/README.md +++ b/vagrant/README.md @@ -50,12 +50,20 @@ ``` git clone https://git.fosscommunity.in/disroot/disroot-website.git ~/disroot-website ``` -2. Add the local domain name for the hub to your host machine's `/etc/hosts` file. +2. Clone grav-theme-disroot repo to disroot-website project folder + ``` + git clone https://git.disroot.org/Disroot/grav-theme-disroot.git ~/disroot-website + ``` +3. Clone grav-plugin-language-selector repo to disroot-website project folder + ``` + git clone https://git.disroot.org/Disroot/grav-plugin-language-selector.git ~/disroot-website + ``` +4. Add the local domain name for the hub to your host machine's `/etc/hosts` file. ``` echo "192.168.33.12 disroot.lan" >> /etc/hosts ``` -3. Launch Vagrant to build the virtual machine (VM). This will take several minutes. +5. Launch Vagrant to build the virtual machine (VM). This will take several minutes. ``` cd ~/disroot-website/vagrant vagrant up disroot_lan @@ -65,6 +73,7 @@ Congratulations, you should now have a fully functioning apache+GRAV server runn ``` cd ~/disroot-website/vagrant vagrant up disroot_lan + vagrant provision ``` ### Enable SSH access diff --git a/vagrant/Vagrantfile b/vagrant/Vagrantfile index 82b3b857..f404a208 100644 --- a/vagrant/Vagrantfile +++ b/vagrant/Vagrantfile @@ -18,7 +18,8 @@ Vagrant.configure("2") do |config| disroot_lan.vm.provision :shell, path: "bootstrap.sh" disroot_lan.vm.synced_folder "../pages/", "/var/www/pages", owner: "www-data", group: "www-data" - disroot_lan.vm.synced_folder "../../grav-theme-disroot", "/var/www/grav-theme-disroot", owner: "www-data", group: "www-data" + disroot_lan.vm.synced_folder "../../grav-theme-disroot", "/var/www/grav-theme-disroot", owner: "www-data", group: "www-data" + disroot_lan.vm.synced_folder "../../grav-plugin-language-selector", "/var/www/grav-plugin-language-selector", owner: "www-data", group: "www-data" end end diff --git a/vagrant/bootstrap.sh b/vagrant/bootstrap.sh index f64f4abb..ffaff5b1 100755 --- a/vagrant/bootstrap.sh +++ b/vagrant/bootstrap.sh @@ -48,7 +48,7 @@ sudo chown -R ${WWW_USER}:${WWW_USER} "${WEB_ROOT}" sudo chmod 775 -R bin/ sudo -u "${WWW_USER}" bin/grav install #sudo -u www-data bin/gpm install disroot -sudo -u "${WWW_USER}" bin/gpm install language-selector +#sudo -u "${WWW_USER}" bin/gpm install language-selector sudo -u "${WWW_USER}" bin/gpm install form sudo -u "${WWW_USER}" sed -i 's/quark/disroot/g' "${YAML}" @@ -86,5 +86,11 @@ sudo sed -i "s/127.0.0.1\tlocalhost/127.0.0.1\tlocalhost $WEB_NAME/" /etc/hosts #Add website pages in GRAV sudo mount -o bind /var/www/pages "${WEB_ROOT}""${WEB_NAME}"/user/pages chown "${WWW_USER}":"${WWW_USER}" -R "${WEB_ROOT}""${WEB_NAME}"/user/pages + +#Add Disroot theme in GRAV sudo -u www-data ln -s /var/www/grav-theme-disroot "${WEB_ROOT}""${WEB_NAME}"/user/themes/disroot + +#Add language-selector in GRAV +sudo -u www-data ln -s /var/www/grav-plugin-language-selector "${WEB_ROOT}""${WEB_NAME}"/user/plugins/language-selector + exit 0