GithubHelp home page GithubHelp logo

sunnyvsm / dev-setup-1 Goto Github PK

View Code? Open in Web Editor NEW

This project forked from stucco/dev-setup

0.0 1.0 0.0 409 KB

Setup for development, test, and demo environment

Home Page: http://stucco.github.io/

License: Other

Shell 29.54% Ruby 70.46%

dev-setup-1's Introduction

Stucco Dev-Setup

This project will set up the test and demonstration environment for Stucco using Vagrant. Linux and Mac OS X are supported.

Setup

  1. Download VirtualBox for your OS and install. (Tested with version 4.3.x.)
  2. Download Vagrant for your OS and install. (Tested with version 1.7.x.)
  3. Download Ansible. (Tested with version 2.0.x.). (Ansible requires Python 2.6.)
  4. Get this repo from github : git clone https://github.com/stucco/dev-setup.git stucco && cd stucco.
  5. Start the VM: vagrant up
  6. Open a web browser to http://10.10.10.100:8000/. Not all data will be there right away, it takes some time to load everything. Start on the help page. (The default Vagrant IP address is 10.10.10.100; if you change it, change the URL.)

Usage

Run vagrant ssh to log into the VM. The stucco project will be in /stucco and/or stucco-shared (see below).

Customize IP/hostname

If you want to set an IP address, use the VM_IP environment variable before the vagrant up command:

    VM_IP="172.17.18.12" vagrant up

If you want to set hostname, use the VM_HOSTNAME environment variable before the vagrant up command:

    VM_HOSTNAME="stucco-1" vagrant up

To access the VM from the host, use the host-only IP address defined at the top of the Vagrantfile:

options = {
  :ip => "10.10.10.100"
}

Networking is set up as host-only, so you will not be able to connect to the VM from another machine.

Vagrant notes

This Vagrantfile assumes your machine can handle 10gb of memory and 4 cores dedicated to the virtual machine, if you need to lower this, edit the configuration options at the top of the Vagrantfile.

To stop/start the VM, the fastest approach is to use vagrant suspend and vagrant resume. You can also use vagrant halt and vagrant up, but this will completely rebuild the VM each time.

To cache some dependencies to make vagrant up faster, install the Vagrant cache plugin to use a cache for downloaded software by running vagrant plugin install vagrant-cachier.

To use Vagrant snapshots, see the 'Snapshots' page on the wiki. Install the Vagrant snapshot plugin by running vagrant plugin install vagrant-vbox-snapshot.

If you want less verbose output from vagrant, you can change the log level:

    VAGRANT_LOG=warn vagrant up

Using the VM for demonstration

All Stucco components will be pulled from the repos on Github and built in the /stucco directory. Each of the components will be started automatically. To confirm this, log into the VM (vagrant ssh) and run sudo supervisorctl status). Log files are in /var/log/supervisord/.

Using the VM for development

To use this VM for development, vagrant will mount the parent directory of this project within the VM at /stucco-shared. It is expected that you will have a directory structure where all of the repositories are in a common folder, so it looks like this:

- stucco
  - dev-setup
  - document-service
  - collectors
  - rt
  - ui

The Github code is started by default, using supervisord. In order to use the repos from your host OS, you will need to change the paths for each of the stucco files in /etc/supervisor/conf.d to /stucco-shared, and reload the configurations (supervisorctl reload), then restart the processes (supervisorctl start all).

P.S.: Commands to run to complete installation (installation script is not running properly with new node v6, have to fix it):

$ vagrant ssh $ cd ../../stucco/ui $ sudo npm install $ sudo node run build $ sudo supervisorctl reload

dev-setup-1's People

Contributors

jgoodall avatar mikeiannacone avatar anishathalye avatar zbeech avatar sjfawks avatar mariavincent avatar

Watchers

James Cloos avatar

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.