Проверка работоспособности ручной установки на Vagrant
# -*- mode: ruby -*- # vi: set ft=ruby : # All Vagrant configuration is done below. The "2" in Vagrant.configure # configures the configuration version (we support older styles for # backwards compatibility). Please don't change it unless you know what # you're doing. $sshKeyInstall = <<-SHELL cat /home/vagrant/.ssh/me.pub >> /home/vagrant/.ssh/authorized_keys SHELL $lampInstall = <<-SHELL apt install -y apache2 mariadb-server php echo "memory_limit=512M" > /etc/php/7.3/cli/conf.d/memory.ini echo "memory_limit=512M" > /etc/php/7.3/apache2/conf.d/memory.ini SHELL $phpModInstall = <<-SHELL apt install -y php-mbstring php-ldap php-dom php-intl php-curl php-imagick php-gmp php-zip php-mysql SHELL $dbPrepare = <<-SHELL systemctl start mysqld echo 'create database arms' | mysql echo 'grant all on arms.* to test_admin@\"%\" identified by \"test_pass"' | mysql arms SHELL $pathsPrepare = <<-SHELL mkdir -p /var/www/arms chown -R www-data:www-data /var/www SHELL $composerInstall = <<-SHELL mkdir -p /var/www/.composer echo '{"github-oauth": {"github.com": "hidden}}' >> /var/www/.composer/auth.json SHELL $appPrepare = <<-SHELL cd /var/www/arms apt install git curl wget -y git clone https://github.com/spo0okie/arms_inventory.git . echo '<?php' > /var/www/arms/config/db-local.php echo "return ['dsn' => 'mysql:host=127.0.0.1;dbname=arms', 'username' => 'test_admin', 'password' => 'test_pass'];" >>/var/www/arms/config/db-local.php echo '<?php' > /var/www/arms/config/params-local.php wget -nv https://getcomposer.org/download/latest-stable/composer.phar sudo -u www-data php ./composer.phar up -n chmod 555 ./yii ./yii migrate --migrationPath=@yii/rbac/migrations/ --interactive=0 ./yii migrate --interactive=0 SHELL Vagrant.configure("2") do |config| config.vm.define "debian10-inventory.test" do |common_test| common_test.vm.box = "debian/buster64" common_test.vm.hostname = "inventory.reviakin.lab" common_test.vm.provider "virtualbox" do |vb| vb.memory = "1024" vb.cpus = "2" vb.name = "inventory.reviakin.lab" end common_test.vm.provision "file", source: "C:/Joker/Documents/keys/puppet.pub", destination: "~/.ssh/me.pub" common_test.vm.provision "shell", inline: $sshKeyInstall common_test.vm.provision "shell", inline: $lampInstall common_test.vm.provision "shell", inline: $phpModInstall common_test.vm.provision "shell", inline: $pathsPrepare common_test.vm.provision "shell", inline: $composerInstall common_test.vm.provision "shell", inline: $dbPrepare common_test.vm.provision "shell", inline: $appPrepare end end
Ставится норм, правда не проверял что получается на морде