Skip to content

Instantly share code, notes, and snippets.

@arxdsilva
Last active October 6, 2016 22:26
Show Gist options
  • Save arxdsilva/d12369bc28a4493ef6795b21f76af131 to your computer and use it in GitHub Desktop.
Save arxdsilva/d12369bc28a4493ef6795b21f76af131 to your computer and use it in GitHub Desktop.
Tsuru TL;DR

This md is a list of commands to use on terminal after you setup your first Vagrant VM. This is your Copy-Paste easy-steps to start tsuru on a test env. If you want a more advanced setup please visit our documentation!!

 sudo apt-get update
 sudo apt-get install python-software-properties
 sudo apt-add-repository ppa:tsuru/ppa -y
 sudo apt-get update
 sudo apt-get install tsuru-server -qqy

Editing file:

Now you will need to edit this file: tsuru.conf that is located under /etc/tsuru/ folder, just copy-paste the code bellow:

 cd /etc/tsuru/
 vim tsuru.conf

Code:

isten: "0.0.0.0:8080"
debug: true
host: http://localhost:8080
repo-manager: none
auth:
    user-registration: true
    scheme: native
database:
    url: localhost:27017
    name: tsurudb
pubsub:
    redis-host: localhost
    redis-port: 6379
queue:
    mongo-url: localhost:27017
    mongo-database: queuedb
provisioner: docker
docker:
    router: hipache
    collection: docker_containers
    repository-namespace: tsuru
    deploy-cmd: /var/lib/tsuru/deploy
    bs:
        image: tsuru/bs:v1
        reporter-interval: 10
        socket: /var/run/docker.sock
    cluster:
        storage: mongodb
        mongo-url: localhost:27017
        mongo-database: cluster
    run-cmd:
        bin: /var/lib/tsuru/start
        port: "8888"
    ssh:
        add-key-cmd: /var/lib/tsuru/add-key
        user: ubuntu
routers:
    hipache:
        type: hipache
        domain: 192.168.0.17.nip.io
        redis-server: localhost:6379
 sudo apt-get install build-essential
 sudo apt-get install tcl8.5
 wget http://download.redis.io/releases/redis-stable.tar.gz
 tar xzf redis-stable.tar.gz
 cd redis-stable
 make
 make test
 sudo make install
 cd utils
 sudo ./install_server.sh
 sudo service redis_6379 start
 sudo apt-get install mongodb
 sudo sed -i -e 's/=no/=yes/' /etc/default/tsuru-server
 sudo start tsuru-server-api
 tsurud root-user-create --config /etc/tsuru/tsuru.conf [email protected]
 tsurupassword
 
 sudo apt-get install tsuru-client
 tsuru target-add default localhost:8080
 tsuru target-set default
 tsuru login [email protected]
 tsurupassword
 
 sudo apt-get install software-properties-common -y
 sudo apt-add-repository ppa:tsuru/ppa -y
 sudo apt-get update
 sudo apt-get install planb -y
 sudo apt-add-repository ppa:tsuru/ppa
 sudo apt-get update
 sudo apt-get install tsuru-admin
 tsuru-admin pool-add example
 tsuru-admin docker-node-add --register 
 
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment