Git Product home page Git Product logo

cf-vagrant-installer's Introduction

Overview

This project provides a mechanism to automate several tasks to be able to set up a Vagrant VM with the following V2 (NG) Cloud Foundry components:

  • Cloud Controller
  • NATS
  • DEA
  • Gorouter
  • UAA
  • Warden
  • Health Manager

Requirements

  • Vagrant

    • Download it from http://www.vagrantup.com (version 1.2 or higher)
    • Install required plugins: vagrant plugin install vagrant-berkshelf vagrant plugin install vagrant-omnibus
  • Ruby 1.9.3

  • (Optional) The VMware Fusion or VMware Workstation provider. If you do not have these installed, you can use the default VirtualBox provider (http://docs.vagrantup.com/v2/vmware/index.html)

    • Fusion: vagrant plugin install vagrant-vmware-fusion vagrant plugin license vagrant-vmware-fusion license.lic

    • Workstation: vagrant plugin install vagrant-vmware-workstation vagrant plugin license vagrant-vmware-workstation license.lic

Installation

Clone the repo

git clone https://github.com/Altoros/cf-vagrant-installer.git
cd cf-vagrant-installer

want to try a particular version?

git checkout tags/v1.0.0

Initialize submodules

rake host:bootstrap

Provision The VM

Using VirtualBox

Initialize the Vagrant VM using the default VirtualBox provider.

vagrant up

Using VMware Fusion / Workstation

Alternatively, you can use a different Vagrant provider such as the VMware Fusion or VMware Workstation provider. See the Vagrant documentation for information on installing and using providers.

Stop!! If you are going to use the VMware provider, you must follow the instructions [here] (vmware/VMware-Instructions.md) first, or the next steps will result in an environment that will not work.

Fusion: vagrant up --provider=vmware_fusion
Workstation: vagrant up --provider=vmware_workstation

Running Cloud Foundry

Cloud Foundry will be bootstrapped the first time the Vagrant provisioner runs (it may take several minutes). After the bootstrap is complete, an upstart configuration will be generated to automatically start Cloud Foundry at boot.

The following commands may be helpful if you wish to manually start and stop Cloud Foundry.

# shell into the VM if you are not already there
vagrant ssh
cd /vagrant

# List the status of each CF component
./status.sh

# Start Cloud Foundry
./start.sh

# Also, to stop:
./stop.sh

Test Your New Cloud Foundry (v2) Instance

Make sure your CF is up and running

  • Set up your PaaS account
# from the directory where you cloned the repo
rake cf:init_cf_cli
  • Push a very simple sinatra application
cd test/fixtures/apps/sinatra
cf push

Expected output:

Using manifest file manifest.yml

Creating hello... OK

Binding hello.192.168.12.34.xip.io to hello... OK
Uploading hello... OK
Preparing to start hello... OK
Checking status of app 'hello'...
  0 of 1 instances running (1 starting)
  1 of 1 instances running (1 running) # This may vary

Open a browser and check if the app has been deployed: hello.192.168.12.34.xip.io

Sinatra Test app for CF Vagrant Installer

Hello from 0.0.0.0:61007!
..... Some environment info .....
...
...

Use "cf apps" command to list the apps you pushed:

cf apps
Getting applications in myspace... OK

name    status    usage      url
hello   running   1 x 256M   hello.192.168.12.34.xip.io

There is also a node.js sample app in test/fixtures/apps

Custom buildpacks power

Now you can test any buildpacks (3rd party, or your own) with cf-vagrant-installer

  • How does it help?
  • What are the use cases?
  • What are they?
  • Step by step example
  • [Continue reading] (custom-buildpacks/custom-buildpacks.md)

Cloud Foundry documentation

http://docs.cloudfoundry.com/

Collaborate

You are welcome to contribute via pull request.

cf-vagrant-installer's People

Contributors

bonzofenix avatar borovsky avatar drnic avatar gramos avatar grenzr-bskyb avatar julioalucero avatar lukebakken avatar mgarciap avatar renatco avatar ryfow avatar scottfrederick avatar smaccoun avatar styx avatar sykesm avatar wacko avatar

Watchers

 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.