Code Monkey home page Code Monkey logo

vagrant's Introduction

Vagrant

This is intended to be included as a submodule in another project, providing a standardized Virtual Machine for LAMP project development. The virtual machine shares the directory which serves the html pages (public_html) with the host system, allowing editing of the files on the host system.

The shared directory ../public_html is expected to be found (outside of this repository) and must be provided by the containing repository or project. See Vagrant Drupal 7 for an example of a project making use of this vagrant submodule.

Prerequisites

  1. Download and install install virtualbox for Windows or Mac.
  2. Download and install vagrant for Windows or Mac
  3. If you use Windows please download and install Cygwin. See Cygwin Setup for help. Make sure to install ssh and git packages.

Installation

Copy and paste this into your shell to install everything:

curl -s https://raw.github.com/delphian/vagrant/master/scripts/bootstrap.sh | bash

Installation script will:

  • Create a virtual machine on 33.33.33.36
  • Modify hosts file mapping site.local to 33.33.33.36

Or install manually by:

git clone --recursive git://github.com/delphian/vagrant.git
cd vagrant
./install.sh 33.33.33.36 site.local /var/www/site.local

Usage

After installation script is finished open a browser and navigate to http://site.local (If Chrome is present on Mac OSX the script will attempt to automtically open the browser)

Database management

SequelPro may be used to access the mysql server inside vagrant:

  • Use the key located at : ~/.vagrant.d/insecure_private_key
  • Configure the ip address to : 33.33.33.66

Normal ssh

A normal ssh session can be invoked with the following commands:

PORT=`vagrant ssh-config | grep Port | grep -o '[0-9]\+'`
chmod 600 ~/.vagrant.d/insecure_private_key
ssh -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no -i ~/.vagrant.d/insecure_private_key vagrant@localhost -p $PORT

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.