Skip to content

Instantly share code, notes, and snippets.

@fcjurado
Last active September 24, 2015 08:19
Show Gist options
  • Save fcjurado/2127518630bc4cb0dddb to your computer and use it in GitHub Desktop.
Save fcjurado/2127518630bc4cb0dddb to your computer and use it in GitHub Desktop.
Vagrant bootstrap.sh file for CentOS 7
#!/usr/bin/env bash
sudo yum -y update
cd ~
sudo rpm -Uvh https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
sudo rpm -Uvh http://rpms.famillecollet.com/enterprise/remi-release-7.rpm
sudo rpm -Uvh https://mirror.webtatic.com/yum/el7/webtatic-release.rpm
sudo yum install -y --skip-broken php56w php56w-opcache
sudo yum -y install httpd php56w-mysql php56w-gd php56w-pear nano mariadb-server mariadb net-tools memcached php56w-pecl-memcache php56w-pear php56w-mbstring
if ! [ -L /var/www ]; then
rm -rf /var/www
ln -fs /vagrant /var/www
fi
sudo firewall-cmd --permanent --add-port=80/tcp
sudo firewall-cmd --permanent --add-port=443/tcp
sudo firewall-cmd --reload
sudo systemctl start httpd
sudo systemctl enable httpd.service
sudo systemctl start mariadb.service
sudo systemctl enable mariadb.service
sudo systemctl start memcached
sudo systemctl enable memcached.service
#sudo /usr/bin/mysql_secure_installation
# mysql -u root -p
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment