No project description provided
Project description
# Treadmill
[![Build Status](https://travis-ci.org/Morgan-Stanley/treadmill.svg?branch=master)](https://travis-ci.org/Morgan-Stanley/treadmill)
## Download
```shell
wget https://github.com/Morgan-Stanley/treadmill/releases/download/0.0.1/treadmill -O /usr/bin/treadmill && chmod +x /usr/bin/treadmill
```
This will put `treadmill` in your path.
## Vagrant setup for development
### Prerequisites
* [VirtualBox](https://www.virtualbox.org/wiki/Downloads)
* [Vagrant](https://www.vagrantup.com/docs/installation/)
* Install the [Guest Additions plugin](https://github.com/dotless-de/vagrant-vbguest) for Vagrant
``` sh
vagrant plugin install vagrant-vbguest
```
### Vagrant Setup
* Clone the [treadmill](https://github.com/Morgan-Stanley/treadmill.git) repo.
* Clone the [treadmill-pid1](https://github.com/Morgan-Stanley/treadmill-pid1) repo.
* Run the following commands
``` sh
cd treadmill
git checkout standard_setup
vagrant up
vagrant ssh
```
* Create the cgroup folders as root
``` sh
sudo su -
cd /sys/fs/cgroup
for i in *; do mkdir -p $i/treadmill/apps $i/treadmill/core $i/system ; done
cd -
```
* Start the zookeeper service
``` sh
cd /home/centos && zookeeper-3.4.9/bin/zkServer.sh start
```
* Make the mount private
``` sh
sudo mount --make-rprivate /
```
* Treadmill should now be available on the box
``` sh
source /home/centos/env/bin/activate
treadmill --help
```
### Treadmill cli cheatsheet
``` sh
treadmill sproc scheduler /tmp
treadmill sproc service --root-dir /tmp/treadmill/ localdisk --reserve 20G --img-location /tmp/treadmill --default-read-bps 100M --default-write-bps 100M --default-read-iops 300 --default-write-iops 300
treadmill sproc service --root-dir /tmp/treadmill/ network
treadmill sproc service --root-dir /tmp/treadmill/ cgroup
# Zookeeper shell
create /scheduled/centos.bar#123 {"memory":"100M","cpu":"10%","disk":"500M","proid":"centos","affinity":"centos.bar","services":[{"name":"sleep","command":"/bin/top","restart":{"limit":5,"interval":60}}]}
create /servers/localhost.localdomain {"parent":"all:unknown","features":[],"traits":[],"label":null,"valid_until":1488573090.0}
create /cell/all:unknown {}
create /buckets/all:unknown {"parent":null,"traits":0}
# System shell
treadmill sproc init --approot /tmp/treadmill/
cd /tmp/treadmill/running && nohup /bin/s6-svscan > s6_svscan.out & && cd -
treadmill sproc eventdaemon
treadmill sproc appcfgmgr
```
[![Build Status](https://travis-ci.org/Morgan-Stanley/treadmill.svg?branch=master)](https://travis-ci.org/Morgan-Stanley/treadmill)
## Download
```shell
wget https://github.com/Morgan-Stanley/treadmill/releases/download/0.0.1/treadmill -O /usr/bin/treadmill && chmod +x /usr/bin/treadmill
```
This will put `treadmill` in your path.
## Vagrant setup for development
### Prerequisites
* [VirtualBox](https://www.virtualbox.org/wiki/Downloads)
* [Vagrant](https://www.vagrantup.com/docs/installation/)
* Install the [Guest Additions plugin](https://github.com/dotless-de/vagrant-vbguest) for Vagrant
``` sh
vagrant plugin install vagrant-vbguest
```
### Vagrant Setup
* Clone the [treadmill](https://github.com/Morgan-Stanley/treadmill.git) repo.
* Clone the [treadmill-pid1](https://github.com/Morgan-Stanley/treadmill-pid1) repo.
* Run the following commands
``` sh
cd treadmill
git checkout standard_setup
vagrant up
vagrant ssh
```
* Create the cgroup folders as root
``` sh
sudo su -
cd /sys/fs/cgroup
for i in *; do mkdir -p $i/treadmill/apps $i/treadmill/core $i/system ; done
cd -
```
* Start the zookeeper service
``` sh
cd /home/centos && zookeeper-3.4.9/bin/zkServer.sh start
```
* Make the mount private
``` sh
sudo mount --make-rprivate /
```
* Treadmill should now be available on the box
``` sh
source /home/centos/env/bin/activate
treadmill --help
```
### Treadmill cli cheatsheet
``` sh
treadmill sproc scheduler /tmp
treadmill sproc service --root-dir /tmp/treadmill/ localdisk --reserve 20G --img-location /tmp/treadmill --default-read-bps 100M --default-write-bps 100M --default-read-iops 300 --default-write-iops 300
treadmill sproc service --root-dir /tmp/treadmill/ network
treadmill sproc service --root-dir /tmp/treadmill/ cgroup
# Zookeeper shell
create /scheduled/centos.bar#123 {"memory":"100M","cpu":"10%","disk":"500M","proid":"centos","affinity":"centos.bar","services":[{"name":"sleep","command":"/bin/top","restart":{"limit":5,"interval":60}}]}
create /servers/localhost.localdomain {"parent":"all:unknown","features":[],"traits":[],"label":null,"valid_until":1488573090.0}
create /cell/all:unknown {}
create /buckets/all:unknown {"parent":null,"traits":0}
# System shell
treadmill sproc init --approot /tmp/treadmill/
cd /tmp/treadmill/running && nohup /bin/s6-svscan > s6_svscan.out & && cd -
treadmill sproc eventdaemon
treadmill sproc appcfgmgr
```
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Treadmill-0.0.2.tar.gz
(279.0 kB
view details)
Built Distribution
Treadmill-0.0.2-py3.4.egg
(923.3 kB
view details)
File details
Details for the file Treadmill-0.0.2.tar.gz
.
File metadata
- Download URL: Treadmill-0.0.2.tar.gz
- Upload date:
- Size: 279.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0b56b4e1be5d23ce585dd72066cba36a1d66c2c0a1aa3f629616fb61f56de77a |
|
MD5 | 444d0b8618d5b123e7a7d8566cf68ff4 |
|
BLAKE2b-256 | 6243e05129b56ac465017e79c605ab4057659c78d97312c5ed58f37a7cfd007c |
File details
Details for the file Treadmill-0.0.2-py3.4.egg
.
File metadata
- Download URL: Treadmill-0.0.2-py3.4.egg
- Upload date:
- Size: 923.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | c30212761c5d42f8546f214b52cb67d9783a8386af637bdf06e280ad66263b28 |
|
MD5 | c4d2759454c7bf646572923d5b7c7c2c |
|
BLAKE2b-256 | 64ee43fb630f99226ea8a3da9d136d9a1702f7e82ba4a82299066f8597f2a109 |