From 9c5eadb1f8f510054a84673787720c5d7b400d9c Mon Sep 17 00:00:00 2001 From: Alex Parsons Date: Wed, 25 Sep 2024 14:28:55 +0000 Subject: [PATCH] Remove vagrant support --- README.md | 21 ++----- Vagrantfile | 73 ----------------------- conf/Vagrantfile.example | 124 --------------------------------------- conf/httpd.vagrant | 36 ------------ 4 files changed, 5 insertions(+), 249 deletions(-) delete mode 100644 Vagrantfile delete mode 100644 conf/Vagrantfile.example delete mode 100644 conf/httpd.vagrant diff --git a/README.md b/README.md index 5fa9c02744..e0ae42d97a 100644 --- a/README.md +++ b/README.md @@ -61,27 +61,16 @@ This will setup the Docker container and environment. Once finished, the link to To populate with a minimal amount of data, run `scripts/quick-populate` (about 1 hour). -### DEPRECATED: Developing with Vagrant - -Please note that we are not currently supporting the Vagrant environment, and may remove it -altogether. Please use the Docker environment instead. - -You will need the latest versions of VirtualBox and Vagrant, then: - -* Run `vagrant up`. -* Go make a cup of tea. It may take a while whilst Vagrant and Puppet do their thing. -* Point your web browser at `http://10.11.12.13` and marvel at modern technology. - -See INSTALL.md for instructions on downloading and importing Parlparse data (members, debates, votes, etc). - - #### Compiling Static Assets If you're working on a page which uses the redesign, you will need to compile static assets after changes: -* `vagrant ssh` -* `cd /vagrant/theyworkforyou/www/docs/style` +* `script/watch-css` + +or + +* `cd www/docs/style` * `bundle exec compass compile` for a one-off compilation or `bundle exec compass watch` to recompile on changes ## Testing diff --git a/Vagrantfile b/Vagrantfile deleted file mode 100644 index ef7e070599..0000000000 --- a/Vagrantfile +++ /dev/null @@ -1,73 +0,0 @@ -# -*- mode: ruby -*- -# vi: set ft=ruby : - -Vagrant.configure(2) do |config| - # The most common configuration options are documented and commented below. - # For a complete reference, please see the online documentation at - # https://docs.vagrantup.com. - - # Every Vagrant development environment requires a box. You can search for - # boxes at https://atlas.hashicorp.com/search. - config.vm.box = "debian/stretch64" - - # Enable NFS access to the disk - config.vm.synced_folder ".", "/vagrant", disabled: true - config.vm.synced_folder ".", "/vagrant/theyworkforyou", :nfs => true - - # NFS requires a host-only network - # This also allows you to test via other devices (e.g. mobiles) on the same - # network - config.vm.network :private_network, ip: "10.11.12.13" - - # Give the VM a bit more power to speed things up - config.vm.provider "virtualbox" do |v| - v.memory = 2048 - v.cpus = 2 - end - - # Provision the vagrant box - config.vm.provision "shell", inline: <<-SHELL - export DEBIAN_FRONTEND=noninteractive - echo 'deb http://mirror.bytemark.co.uk/debian stretch-backports main' > /etc/apt/sources.list.d/backports.list - apt-get update - - chown vagrant:vagrant /vagrant - cd /vagrant/theyworkforyou - - # Install needed things - apt-get -qq -y install unzip fakeroot git >/dev/null - - # mysql and xapian - bin/install-php7-xapian.sh - bin/install-mysql vagrant - - # Install the packages from conf/packages - grep -vE "^#" conf/packages | xargs apt-get install -qq -y >/dev/null - - # Install webserver - apt-get -qq -y install apache2 libapache2-mod-php >/dev/null - - # apache config and modules - cp conf/httpd.vagrant /etc/apache2/sites-enabled/twfy.conf - a2enmod expires rewrite - /etc/init.d/apache2 reload - - # NFS woes mean you have to do this - it can't compile FFI inside - mkdir /home/vagrant/bundle - chown vagrant:vagrant /home/vagrant/bundle - ln -sn /home/vagrant/bundle vendor/bundle - - su vagrant -c 'bin/install-as-user vagrant 10.11.12.13 /vagrant yes' - su vagrant -c 'bin/deploy.bash' - - echo "Your site should now be visible at http://10.11.12.13/" - SHELL - - # It's likely the shared folder wasn't available when Apache started. - # So restart Apache again once the machine has started up. - config.vm.provision "shell", run: "always", inline: <<-SHELL - sudo apachectl restart - echo "Your site should now be visible at http://10.11.12.13/" - SHELL - -end diff --git a/conf/Vagrantfile.example b/conf/Vagrantfile.example deleted file mode 100644 index b768c85996..0000000000 --- a/conf/Vagrantfile.example +++ /dev/null @@ -1,124 +0,0 @@ -# -*- mode: ruby -*- -# vi: set ft=ruby : - -$script = <