Skip to content

Latest commit

 

History

History
 
 

ltc

ltc: The Lattice CLI

Website: http://lattice.cf
Mailing List: Subscribe
Archives: [ Nabble | Google Groups ]

Build Status Coverage Status

ltc provides an easy-to-use command line interface for Lattice

With ltc you can:

  • target a Lattice deployment
  • create, scale and remove Dockerimage-based applications
  • tail logs for your running applications
  • list all running applications and visualize their distributions across the Lattice cluster
  • fetch detail status information for a running application

##Setup:

Download the appropriate binary for your architecture. These link to the latest release of ltc. For a specific release version visit the releases page. The latest unstable build is available below.

Platform Architecture Type Link
MacOS amd64 Release https://lattice.s3.amazonaws.com/releases/latest/darwin-amd64/ltc
Linux amd64 Release https://lattice.s3.amazonaws.com/releases/latest/linux-amd64/ltc
MacOS amd64 Unstable https://lattice.s3.amazonaws.com/unstable/latest/darwin-amd64/ltc
Linux amd64 Unstable https://lattice.s3.amazonaws.com/unstable/latest/linux-amd64/ltc

Here's a simple installation script. It assumes $HOME/bin is on your $PATH

Mac:

  mkdir -p $HOME/bin
  curl https://lattice.s3.amazonaws.com/releases/latest/darwin-amd64/ltc -o $HOME/bin/ltc
  chmod +x $HOME/bin/ltc

Linux:

  mkdir -p $HOME/bin
  wget https://lattice.s3.amazonaws.com/releases/latest/linux-amd64/ltc -O $HOME/bin/ltc
  chmod +x $HOME/bin/ltc

Installing From Source

You must have Go 1.4+ installed and set up correctly. ltc uses Godeps to vendor its dependencies.

go get -d github.com/cloudfoundry-incubator/lattice/ltc
$GOPATH/src/github.com/cloudfoundry-incubator/lattice/ltc/scripts/install

The first command downloads the package. The second installs it, specifying the path to the dependencies.
Note: go get will additionally attempt to download package dependencies, which may fail. This is due to Docker auto-generated packages, and is safe to ignore.

Example Usage:

ltc target 192.168.11.11.xip.io
ltc create lattice-app cloudfoundry/lattice-app
ltc logs lattice-app

To view the app in a browser visit http://lattice-app.192.168.11.11.xip.io/

To scale up the app:

ltc scale lattice-app 5

Refresh the browser to see the requests routing to different Docker containers running lattice-app.

Copyright

See LICENSE for details. Copyright (c) 2015 Pivotal Software, Inc.