Skip to content

dohernandez/automation

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

48 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Automation

Background

Vagrant and VirtualBox (or some other VM provider) can be used to quickly build or rebuild virtual servers.

This repository contains the Ansible automation code to provision a simple Nginx, MySQL and PHP (the 'EMP' part of 'LEMP') environment.

Applications available

  • LEMP (Linux Nginx 1.4, MySQL, and PHP-fpm 7.0) installed
    • MySQL connection details:
      • host: localhost
      • port: 3306
      • dbname: dohernandez
      • username: dohernandez
      • password: dohernandez

Note

To enable the php 5.6 version you should edit the file "vars/all.yml".

php5x:
    install: '0'
    
by default, the php 5.6 version is disable

php5x:
    install: '1'
    
  • Composer installed
  • XDebug
  • MongoDB
    • MongoDB connection details:
      • host: localhost
      • port: 27017
  • Redis

Before starting

VM settings

To edit additional configuration options exposes in VirtualBox-powered Vagrant environments,
copy the config/box_setting.dist.yml to config/box_setting.yml and edit the file.

Ansible settings

To edit where Ansible can find its commands to run during the vagrant provision, copy the config/box_setting.dist.yml to config/box_setting.yml and edit the file.

Software

Make sure you have the following software installed in your machine. If running OSX, just follow the instructions below.

OSX Must-haves

Homebrew and Cask make it very easy to install software on OSX.

# Install Homebrew
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

# Install Cask
brew install caskroom/cask/brew-cask

# Install git
brew install git

# Install virtualbox
brew cask install virtualbox

# Install vagrant and plugins
brew cask install vagrant
vagrant plugin install vagrant-hostmanager

Getting Started

To get started developing:

  1. Clone this repository somewhere.
  2. Cd into the repository
  3. Run vagrant up to get the VM running.
  4. Your application code go into src/<app name>, ex: src/laravel.
  5. Your public files go into src/<app name>/public, ex: src/laravel/public.

About

This repository contains the ansible automation code to build a simple PHP environment

Resources

Stars

Watchers

Forks

Packages

 
 
 

Contributors