Skip to content

Commit

Permalink
Merge branch 'release/0.1.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
yasuhito committed Jan 29, 2015
2 parents 97ba2cb + 8a4a44c commit a8688fe
Show file tree
Hide file tree
Showing 19 changed files with 270 additions and 176 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
/test/tmp/
/test/version_tmp/
/tmp/
/vendor/

## Specific to RubyMotion:
.dat*
Expand Down
3 changes: 3 additions & 0 deletions .hound.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
ruby:
enabled: true
config_file: .rubocop.yml
11 changes: 5 additions & 6 deletions .rubocop.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
AllCops:
Include:
- Gemfile
- Guardfile
- Rakefile
- tasks/*.rake
Style/StringLiterals:
EnforcedStyle: single_quotes

Style/DotPosition:
EnforcedStyle: trailing
26 changes: 26 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
language: ruby

bundler_args: --without development

script: bundle exec rake travis

rvm:
- 2.0
- 2.1
- 2.2
- ruby-head

before_install:
- sudo apt-get update -qq
- sudo apt-get install libpcap-dev -qq
- gem update bundler

matrix:
allow_failures:
- rvm: ruby-head
fast_finish: true

env:
global:
- secure: K8XOn6irNlcpwwXsTJYH5jA7Iu3JM329kl8lzKIeku+5ypVTOBoknVr7NHQJEJvC/RWUmXh9IxPSo2xUVfO6gVum9rjCRzG+m7dVvhvM7I4E0nnCn/ouTkY+ksSBcPJ34UDb7Z4NzyrrG04MtJKLwbBtD61hRseeo3hOO9uAH6Y=
- secure: lDefP7JDN2SBO/21Sm+TBIvXRYm6sTbyuJDaX76HXIX/ccf/oxYYuqfrxe32SgZuMXVHQcNKjl55kQMz0LtgSVLgKPhn2AaBn96j19F84FdcTV3wMJZURMGIrIgW7uKpc6KLGlQtAHnPcmKSm7/6Vhz2IbtlnZdEEC/jYagVOeY=
9 changes: 9 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# Change log

## develop (unreleased)

## 0.1.0 (1/29/2015)

### Misc

* The initial release version of patch_panel that runs on [pure-Ruby Trema](https://github.com/trema/trema_ruby).
3 changes: 2 additions & 1 deletion Gemfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
source 'https://rubygems.org'

gem 'trema', github: 'trema/trema', branch: 'develop'
gem 'phut', github: 'trema/phut', branch: 'develop'
gem 'trema', github: 'trema/trema_ruby', branch: 'develop'

group :development, :test do
gem 'aruba', require: false
Expand Down
124 changes: 67 additions & 57 deletions Gemfile.lock
Original file line number Diff line number Diff line change
@@ -1,27 +1,32 @@
GIT
remote: git://github.com/trema/trema.git
revision: 40ecd9fb7f388743a03e09327eca2fd2a1e172d1
remote: git://github.com/trema/phut.git
revision: ea3c98aa5fa8cfa815653273114458b759b91929
branch: develop
specs:
trema (0.4.7)
gli (~> 2.11.0)
paper_house (~> 0.6.2)
pio (~> 0.8.1)
phut (0.1.0)
gli (~> 2.12.2)
pio (~> 0.11.2)
pry (~> 0.10.1)

GIT
remote: git://github.com/trema/trema_ruby.git
revision: 1fcbee5ddd7b491a6326f2d40b424bbd7f1c5702
branch: develop
specs:
trema (0.1.0)
bundler (~> 1.7.12)
gli (~> 2.12.0)
pio (~> 0.11.2)
rake
rdoc (~> 4.1.1)

GEM
remote: https://rubygems.org/
specs:
POpen4 (0.1.4)
Platform (>= 0.4.0)
open4
Platform (0.4.0)
abstract_type (0.0.7)
adamantium (0.2.0)
ice_nine (~> 0.11.0)
memoizable (~> 0.4.0)
aruba (0.6.1)
aruba (0.6.2)
childprocess (>= 0.3.6)
cucumber (>= 1.1.1)
rspec-expectations (>= 2.7.0)
Expand All @@ -34,19 +39,19 @@ GEM
timers (~> 4.0.0)
childprocess (0.5.5)
ffi (~> 1.0, >= 1.0.11)
codeclimate-test-reporter (0.4.3)
codeclimate-test-reporter (0.4.6)
simplecov (>= 0.7.1, < 1.0.0)
coderay (1.1.0)
concord (0.1.5)
adamantium (~> 0.2.0)
equalizer (~> 0.0.9)
coveralls (0.7.2)
multi_json (~> 1.3)
rest-client (= 1.6.7)
simplecov (>= 0.7)
term-ansicolor (= 1.2.2)
thor (= 0.18.1)
cucumber (1.3.17)
coveralls (0.7.3)
multi_json (~> 1.10)
rest-client (~> 1.7)
simplecov (~> 0.9.1)
term-ansicolor (~> 1.3)
thor (~> 0.19.1)
cucumber (1.3.18)
builder (>= 2.1.2)
diff-lcs (>= 1.1.3)
gherkin (~> 2.12)
Expand All @@ -56,41 +61,44 @@ GEM
docile (1.1.5)
equalizer (0.0.9)
ffi (1.9.6)
flog (4.3.0)
flog (4.3.1)
ruby_parser (~> 3.1, > 3.1.0)
sexp_processor (~> 4.4)
formatador (0.2.5)
gherkin (2.12.2)
multi_json (~> 1.3)
given_core (3.5.4)
given_core (3.6.0)
sorcerer (>= 0.3.7)
gli (2.11.0)
guard (2.10.1)
gli (2.12.2)
guard (2.11.1)
formatador (>= 0.2.4)
listen (~> 2.7)
lumberjack (~> 1.0)
nenv (~> 0.1)
notiffany (~> 0.0)
pry (>= 0.9.12)
shellany (~> 0.0)
thor (>= 0.18.1)
guard-bundler (2.0.0)
guard-bundler (2.1.0)
bundler (~> 1.0)
guard (~> 2.2)
guard-compat (0.3.0)
guard-rspec (4.4.2)
guard-compat (~> 1.1)
guard-compat (1.2.1)
guard-rspec (4.5.0)
guard (~> 2.1)
guard-compat (~> 0.1)
guard-compat (~> 1.1)
rspec (>= 2.99.0, < 4.0)
guard-rubocop (1.2.0)
guard (~> 2.0)
rubocop (~> 0.20)
hitimes (1.2.2)
ice_nine (0.11.1)
inch (0.5.7)
inch (0.5.10)
pry
sparkr (>= 0.2.0)
term-ansicolor
yard (~> 0.8.7.5)
json (1.8.1)
listen (2.8.3)
listen (2.8.5)
celluloid (>= 0.15.2)
rb-fsevent (>= 0.9.3)
rb-inotify (>= 0.9)
Expand All @@ -101,14 +109,14 @@ GEM
mime-types (2.4.3)
multi_json (1.10.1)
multi_test (0.1.1)
open4 (1.3.4)
paper_house (0.6.2)
POpen4 (~> 0.1.4)
rake
parser (2.2.0.pre.8)
nenv (0.2.0)
netrc (0.10.2)
notiffany (0.0.3)
nenv (~> 0.1)
shellany (~> 0.0)
parser (2.2.0.2)
ast (>= 1.1, < 3.0)
slop (~> 3.4, >= 3.4.5)
pio (0.8.1)
pio (0.11.2)
bindata (~> 2.1.0)
powerpack (0.0.9)
procto (0.0.2)
Expand All @@ -121,14 +129,13 @@ GEM
rb-fsevent (0.9.4)
rb-inotify (0.9.5)
ffi (>= 0.5.0)
rdoc (4.1.2)
json (~> 1.4)
reek (1.5.1)
reek (1.6.4)
parser (~> 2.2.0.pre.7)
rainbow (>= 1.99, < 3.0)
unparser (~> 0.1.16)
rest-client (1.6.7)
mime-types (>= 1.16)
unparser (~> 0.2.2)
rest-client (1.7.2)
mime-types (>= 1.16, < 3.0)
netrc (~> 0.7)
rspec (3.1.0)
rspec-core (~> 3.1.0)
rspec-expectations (~> 3.1.0)
Expand All @@ -138,22 +145,23 @@ GEM
rspec-expectations (3.1.2)
diff-lcs (>= 1.2.0, < 2.0)
rspec-support (~> 3.1.0)
rspec-given (3.5.4)
given_core (= 3.5.4)
rspec (>= 2.12)
rspec-given (3.6.0)
given_core (= 3.6.0)
rspec (>= 2.14.0)
rspec-mocks (3.1.3)
rspec-support (~> 3.1.0)
rspec-support (3.1.2)
rubocop (0.27.1)
rubocop (0.28.0)
astrolabe (~> 1.3)
parser (>= 2.2.0.pre.7, < 3.0)
powerpack (~> 0.0.6)
rainbow (>= 1.99.1, < 3.0)
ruby-progressbar (~> 1.4)
ruby-progressbar (1.7.0)
ruby_parser (3.6.3)
ruby-progressbar (1.7.1)
ruby_parser (3.6.4)
sexp_processor (~> 4.1)
sexp_processor (4.4.4)
sexp_processor (4.4.5)
shellany (0.0.1)
simplecov (0.9.1)
docile (~> 1.1.0)
multi_json (~> 1.0)
Expand All @@ -162,19 +170,20 @@ GEM
slop (3.6.0)
sorcerer (1.0.2)
sparkr (0.4.1)
term-ansicolor (1.2.2)
tins (~> 0.8)
thor (0.18.1)
term-ansicolor (1.3.0)
tins (~> 1.0)
thor (0.19.1)
thread_safe (0.3.4)
timers (4.0.1)
hitimes
tins (0.13.2)
unparser (0.1.16)
tins (1.3.3)
unparser (0.2.2)
abstract_type (~> 0.0.7)
adamantium (~> 0.2.0)
concord (~> 0.1.5)
diff-lcs (~> 1.2.5)
equalizer (~> 0.0.9)
parser (~> 2.2.0.pre.7)
parser (~> 2.2.0.2)
procto (~> 0.0.2)
yard (0.8.7.6)

Expand All @@ -192,6 +201,7 @@ DEPENDENCIES
guard-rspec
guard-rubocop
inch
phut!
rake
reek
rspec
Expand Down
27 changes: 26 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ patch_panel
[![Dependency Status](http://img.shields.io/gemnasium/trema/patch_panel.svg?style=flat)][gemnasium]
[![Inline docs](http://inch-ci.org/github/trema/patch_panel.png?branch=develop)][inch]

OpenFlow controller that emulates a software patch panel.

[travis]: http://travis-ci.org/trema/patch_panel
[coveralls]: https://coveralls.io/r/trema/patch_panel
[codeclimate]: https://codeclimate.com/github/trema/patch_panel
Expand All @@ -19,5 +21,28 @@ How to run

```
% bundle install
% bundle exec trema run lib/patch_panel.rb -c sample.conf
% bundle exec trema run lib/patch_panel.rb -c trema.conf
```


Configuration
-------------

When `patch_panel.rb` starts up, it will search for its configuration
file named `patch_panel.conf` in the current working directory. If you
want to specify a path to a configuration file, pass it to
`patch_panel.rb` as its argument:

```
% bundle exec trema run "lib/patch_panel.rb foobar.conf" -c trema.conf
```

A configuration file contains patching information. Each line has a
pair of port numbers like so:

```
1 2
3 4
```

The first line means that switch port #1 is connected to port #2.
Loading

0 comments on commit a8688fe

Please sign in to comment.