bigbluebutton_rails 0.0.6 → 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitignore +1 -1
- data/CHANGELOG.rdoc +8 -0
- data/Gemfile +13 -7
- data/Gemfile.lock +112 -86
- data/README.rdoc +26 -80
- data/Rakefile +2 -1
- data/TODO_08 +13 -0
- data/app/controllers/bigbluebutton/rooms_controller.rb +9 -9
- data/app/controllers/bigbluebutton/servers_controller.rb +1 -1
- data/app/models/bigbluebutton_room.rb +16 -14
- data/app/models/bigbluebutton_server.rb +1 -1
- data/app/views/bigbluebutton/rooms/_form.html.erb +1 -1
- data/app/views/bigbluebutton/rooms/external.html.erb +3 -3
- data/app/views/bigbluebutton/rooms/invite.html.erb +3 -3
- data/app/views/bigbluebutton/servers/_form.html.erb +1 -1
- data/bigbluebutton_rails.gemspec +2 -2
- data/lib/bigbluebutton_rails/version.rb +1 -1
- data/spec/controllers/bigbluebutton/rooms_controller_spec.rb +42 -37
- data/spec/factories/bigbluebutton_room.rb +3 -1
- data/spec/models/bigbluebutton_room_db_spec.rb +34 -0
- data/spec/models/bigbluebutton_room_spec.rb +452 -457
- data/spec/models/bigbluebutton_server_db_spec.rb +14 -0
- data/spec/models/bigbluebutton_server_spec.rb +162 -176
- data/spec/rails_app/.gitignore +2 -1
- data/spec/rails_app/db/seeds.rb +16 -4
- data/spec/rails_app/features/activity_monitor_servers.feature +53 -0
- data/spec/rails_app/features/config.yml.example +13 -0
- data/spec/rails_app/features/create_rooms.feature +17 -0
- data/spec/rails_app/features/create_servers.feature +17 -0
- data/spec/rails_app/features/destroy_rooms.feature +12 -0
- data/spec/rails_app/features/destroy_servers.feature +11 -0
- data/spec/rails_app/features/edit_rooms.feature +26 -0
- data/spec/rails_app/features/edit_servers.feature +24 -0
- data/spec/rails_app/features/join_external_rooms.feature +61 -0
- data/spec/rails_app/features/join_mobile.feature +10 -0
- data/spec/rails_app/features/join_rooms.feature +117 -0
- data/spec/rails_app/features/list_and_show_rooms.feature +18 -0
- data/spec/rails_app/features/list_and_show_servers.feature +16 -0
- data/spec/rails_app/features/step_definitions/activity_monitor_servers_step.rb +102 -0
- data/spec/rails_app/features/step_definitions/common_steps.rb +99 -3
- data/spec/rails_app/features/step_definitions/create_rooms_steps.rb +38 -0
- data/spec/rails_app/features/step_definitions/{bigbluebutton_server_steps.rb → create_servers_steps.rb} +11 -6
- data/spec/rails_app/features/step_definitions/destroy_rooms_steps.rb +17 -0
- data/spec/rails_app/features/step_definitions/destroy_servers_steps.rb +15 -0
- data/spec/rails_app/features/step_definitions/edit_rooms_steps.rb +15 -0
- data/spec/rails_app/features/step_definitions/edit_servers_steps.rb +15 -0
- data/spec/rails_app/features/step_definitions/join_mobile_steps.rb +5 -0
- data/spec/rails_app/features/step_definitions/join_rooms_steps.rb +49 -0
- data/spec/rails_app/features/step_definitions/list_and_show_rooms_steps.rb +11 -0
- data/spec/rails_app/features/step_definitions/list_and_show_servers_steps.rb +11 -0
- data/spec/rails_app/features/support/configurations.rb +34 -0
- data/spec/rails_app/features/support/content.rb +27 -7
- data/spec/rails_app/features/support/env_custom.rb +21 -0
- data/spec/rails_app/features/support/factories/bigbluebutton_server_integration.rb +5 -0
- data/spec/rails_app/features/support/hooks.rb +14 -0
- data/spec/rails_app/features/support/locales.rb +18 -0
- data/spec/rails_app/features/support/paths.rb +25 -10
- data/spec/rails_app/features/support/selectors.rb +26 -0
- data/spec/rails_app/features/support/templates.rb +241 -0
- metadata +43 -20
- data/spec/factories/integration/bigbluebutton_server_integration.rb +0 -8
- data/spec/integration_conf.yml.example +0 -5
- data/spec/rails_app/features/join_external_bigbluebutton_rooms.feature +0 -19
- data/spec/rails_app/features/manage_bigbluebutton_rooms.feature +0 -9
- data/spec/rails_app/features/manage_bigbluebutton_servers.feature +0 -9
- data/spec/rails_app/features/step_definitions/bigbluebutton_room_steps.rb +0 -64
- data/spec/rails_app/features/support/env_gem.rb +0 -10
- data/spec/rails_app/features/support/forms.rb +0 -12
- data/spec/support/integration/integration_conf.rb +0 -16
data/.gitignore
CHANGED
data/CHANGELOG.rdoc
CHANGED
@@ -1,3 +1,11 @@
|
|
1
|
+
== 0.1.0
|
2
|
+
|
3
|
+
* First version with support to BigBlueButton 0.8:
|
4
|
+
* The support is still very basic: you can use the gem with BBB 0.8 but not all features are supported yet, such as pre-upload of slides and anything related to recordings.
|
5
|
+
* Updated bigbluebutton-api-ruby to 0.1.0 to support BBB 0.8.
|
6
|
+
* Added several integration tests.
|
7
|
+
* Several small bug fixes
|
8
|
+
|
1
9
|
== 0.0.6
|
2
10
|
|
3
11
|
* After fetch_meetings, the rooms that are not found in the DB are *not* saved by default anymore.
|
data/Gemfile
CHANGED
@@ -2,15 +2,9 @@ source 'http://rubygems.org'
|
|
2
2
|
|
3
3
|
gemspec
|
4
4
|
|
5
|
-
group :development
|
6
|
-
gem "rspec-rails"
|
7
|
-
gem "factory_girl"
|
5
|
+
group :development do
|
8
6
|
gem "sqlite3-ruby"
|
9
|
-
gem "generator_spec"
|
10
|
-
gem "shoulda-matchers"
|
11
7
|
gem "forgery"
|
12
|
-
gem "cucumber-rails"
|
13
|
-
gem "database_cleaner"
|
14
8
|
gem "rdoc"
|
15
9
|
gem "rails_best_practices"
|
16
10
|
end
|
@@ -19,4 +13,16 @@ group :test do
|
|
19
13
|
if RUBY_VERSION >= "1.9"
|
20
14
|
gem 'simplecov', '>= 0.4.0', :require => false
|
21
15
|
end
|
16
|
+
|
17
|
+
gem "cucumber-rails"
|
18
|
+
gem "database_cleaner"
|
19
|
+
gem "shoulda-matchers"
|
20
|
+
gem "factory_girl"
|
21
|
+
gem "generator_spec"
|
22
|
+
gem "rspec-rails"
|
23
|
+
gem "bbbot-ruby", :git => "git://github.com/mconf/bbbot-ruby.git"
|
24
|
+
|
25
|
+
gem "capybara-mechanize", "0.3.0.rc3" # allows remote requests
|
26
|
+
gem "launchy"
|
27
|
+
gem "capybara-webkit" # best option found for js
|
22
28
|
end
|
data/Gemfile.lock
CHANGED
@@ -1,20 +1,26 @@
|
|
1
|
+
GIT
|
2
|
+
remote: git://github.com/mconf/bbbot-ruby.git
|
3
|
+
revision: 83f3ccf88aa355260a791eb450a8d73f94049053
|
4
|
+
specs:
|
5
|
+
bbbot-ruby (0.0.1)
|
6
|
+
|
1
7
|
PATH
|
2
8
|
remote: .
|
3
9
|
specs:
|
4
|
-
bigbluebutton_rails (0.0
|
5
|
-
bigbluebutton-api-ruby (~> 0.0
|
6
|
-
rails (>= 3.0.
|
10
|
+
bigbluebutton_rails (0.1.0)
|
11
|
+
bigbluebutton-api-ruby (~> 0.1.0)
|
12
|
+
rails (>= 3.0.0)
|
7
13
|
|
8
14
|
GEM
|
9
15
|
remote: http://rubygems.org/
|
10
16
|
specs:
|
11
17
|
abstract (1.0.0)
|
12
|
-
actionmailer (3.0.
|
13
|
-
actionpack (= 3.0.
|
18
|
+
actionmailer (3.0.11)
|
19
|
+
actionpack (= 3.0.11)
|
14
20
|
mail (~> 2.2.19)
|
15
|
-
actionpack (3.0.
|
16
|
-
activemodel (= 3.0.
|
17
|
-
activesupport (= 3.0.
|
21
|
+
actionpack (3.0.11)
|
22
|
+
activemodel (= 3.0.11)
|
23
|
+
activesupport (= 3.0.11)
|
18
24
|
builder (~> 2.1.2)
|
19
25
|
erubis (~> 2.6.6)
|
20
26
|
i18n (~> 0.5.0)
|
@@ -22,133 +28,149 @@ GEM
|
|
22
28
|
rack-mount (~> 0.6.14)
|
23
29
|
rack-test (~> 0.5.7)
|
24
30
|
tzinfo (~> 0.3.23)
|
25
|
-
activemodel (3.0.
|
26
|
-
activesupport (= 3.0.
|
31
|
+
activemodel (3.0.11)
|
32
|
+
activesupport (= 3.0.11)
|
27
33
|
builder (~> 2.1.2)
|
28
34
|
i18n (~> 0.5.0)
|
29
|
-
activerecord (3.0.
|
30
|
-
activemodel (= 3.0.
|
31
|
-
activesupport (= 3.0.
|
35
|
+
activerecord (3.0.11)
|
36
|
+
activemodel (= 3.0.11)
|
37
|
+
activesupport (= 3.0.11)
|
32
38
|
arel (~> 2.0.10)
|
33
39
|
tzinfo (~> 0.3.23)
|
34
|
-
activeresource (3.0.
|
35
|
-
activemodel (= 3.0.
|
36
|
-
activesupport (= 3.0.
|
37
|
-
activesupport (3.0.
|
40
|
+
activeresource (3.0.11)
|
41
|
+
activemodel (= 3.0.11)
|
42
|
+
activesupport (= 3.0.11)
|
43
|
+
activesupport (3.0.11)
|
44
|
+
addressable (2.2.6)
|
38
45
|
arel (2.0.10)
|
39
|
-
bigbluebutton-api-ruby (0.0
|
40
|
-
|
46
|
+
bigbluebutton-api-ruby (0.1.0)
|
47
|
+
xml-simple (>= 1.1.1)
|
41
48
|
builder (2.1.2)
|
42
|
-
capybara (1.
|
49
|
+
capybara (1.1.2)
|
43
50
|
mime-types (>= 1.16)
|
44
51
|
nokogiri (>= 1.3.3)
|
45
52
|
rack (>= 1.0.0)
|
46
53
|
rack-test (>= 0.5.4)
|
47
|
-
selenium-webdriver (~>
|
54
|
+
selenium-webdriver (~> 2.0)
|
48
55
|
xpath (~> 0.1.4)
|
49
|
-
|
56
|
+
capybara-mechanize (0.3.0.rc3)
|
57
|
+
capybara (~> 1.1.0)
|
58
|
+
mechanize (~> 2.0.0)
|
59
|
+
capybara-webkit (0.7.2)
|
60
|
+
capybara (< 1.2, >= 1.0.0)
|
61
|
+
childprocess (0.2.3)
|
50
62
|
ffi (~> 1.0.6)
|
51
63
|
colored (1.2)
|
52
|
-
cucumber (1.
|
64
|
+
cucumber (1.1.4)
|
53
65
|
builder (>= 2.1.2)
|
54
66
|
diff-lcs (>= 1.1.2)
|
55
|
-
gherkin (~> 2.
|
67
|
+
gherkin (~> 2.7.1)
|
56
68
|
json (>= 1.4.6)
|
57
|
-
term-ansicolor (>= 1.0.
|
58
|
-
cucumber-rails (1.
|
59
|
-
capybara (>= 1.
|
60
|
-
cucumber (
|
61
|
-
nokogiri (>= 1.
|
62
|
-
database_cleaner (0.
|
63
|
-
diff-lcs (1.1.
|
69
|
+
term-ansicolor (>= 1.0.6)
|
70
|
+
cucumber-rails (1.2.1)
|
71
|
+
capybara (>= 1.1.2)
|
72
|
+
cucumber (>= 1.1.3)
|
73
|
+
nokogiri (>= 1.5.0)
|
74
|
+
database_cleaner (0.7.0)
|
75
|
+
diff-lcs (1.1.3)
|
64
76
|
erubis (2.6.6)
|
65
77
|
abstract (>= 1.0.0)
|
66
|
-
factory_girl (2.
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
generator_spec (0.8.
|
71
|
-
rails (
|
78
|
+
factory_girl (2.3.2)
|
79
|
+
activesupport
|
80
|
+
ffi (1.0.11)
|
81
|
+
forgery (0.5.0)
|
82
|
+
generator_spec (0.8.4)
|
83
|
+
rails (< 4.0, >= 3.0)
|
72
84
|
rspec-rails
|
73
|
-
gherkin (2.
|
85
|
+
gherkin (2.7.1)
|
74
86
|
json (>= 1.4.6)
|
75
|
-
haml (3.1.2)
|
76
87
|
i18n (0.5.0)
|
77
|
-
json (1.
|
78
|
-
|
88
|
+
json (1.6.3)
|
89
|
+
launchy (2.0.5)
|
90
|
+
addressable (~> 2.2.6)
|
79
91
|
mail (2.2.19)
|
80
92
|
activesupport (>= 2.3.6)
|
81
93
|
i18n (>= 0.4.0)
|
82
94
|
mime-types (~> 1.16)
|
83
95
|
treetop (~> 1.4.8)
|
84
|
-
|
85
|
-
|
86
|
-
|
87
|
-
|
96
|
+
mechanize (2.0.1)
|
97
|
+
net-http-digest_auth (>= 1.1.1, ~> 1.1)
|
98
|
+
net-http-persistent (~> 1.8)
|
99
|
+
nokogiri (~> 1.4)
|
100
|
+
webrobots (>= 0.0.9, ~> 0.0)
|
101
|
+
mime-types (1.17.2)
|
102
|
+
multi_json (1.0.4)
|
103
|
+
net-http-digest_auth (1.2)
|
104
|
+
net-http-persistent (1.9)
|
105
|
+
nokogiri (1.5.0)
|
106
|
+
polyglot (0.3.3)
|
107
|
+
progressbar (0.9.2)
|
108
|
+
rack (1.2.4)
|
88
109
|
rack-mount (0.6.14)
|
89
110
|
rack (>= 1.0.0)
|
90
111
|
rack-test (0.5.7)
|
91
112
|
rack (>= 1.0)
|
92
|
-
rails (3.0.
|
93
|
-
actionmailer (= 3.0.
|
94
|
-
actionpack (= 3.0.
|
95
|
-
activerecord (= 3.0.
|
96
|
-
activeresource (= 3.0.
|
97
|
-
activesupport (= 3.0.
|
113
|
+
rails (3.0.11)
|
114
|
+
actionmailer (= 3.0.11)
|
115
|
+
actionpack (= 3.0.11)
|
116
|
+
activerecord (= 3.0.11)
|
117
|
+
activeresource (= 3.0.11)
|
118
|
+
activesupport (= 3.0.11)
|
98
119
|
bundler (~> 1.0)
|
99
|
-
railties (= 3.0.
|
100
|
-
rails_best_practices (
|
120
|
+
railties (= 3.0.11)
|
121
|
+
rails_best_practices (1.7.1)
|
101
122
|
activesupport
|
102
123
|
colored
|
103
124
|
erubis
|
104
|
-
haml
|
105
125
|
i18n
|
106
|
-
|
107
|
-
|
108
|
-
railties (3.0.
|
109
|
-
actionpack (= 3.0.
|
110
|
-
activesupport (= 3.0.
|
126
|
+
progressbar
|
127
|
+
sexp_processor
|
128
|
+
railties (3.0.11)
|
129
|
+
actionpack (= 3.0.11)
|
130
|
+
activesupport (= 3.0.11)
|
111
131
|
rake (>= 0.8.7)
|
112
132
|
rdoc (~> 3.4)
|
113
133
|
thor (~> 0.14.4)
|
114
|
-
rake (0.9.2)
|
115
|
-
rdoc (3.
|
116
|
-
|
117
|
-
|
118
|
-
rspec-
|
119
|
-
rspec-
|
120
|
-
|
121
|
-
rspec-
|
134
|
+
rake (0.9.2.2)
|
135
|
+
rdoc (3.12)
|
136
|
+
json (~> 1.4)
|
137
|
+
rspec (2.7.0)
|
138
|
+
rspec-core (~> 2.7.0)
|
139
|
+
rspec-expectations (~> 2.7.0)
|
140
|
+
rspec-mocks (~> 2.7.0)
|
141
|
+
rspec-core (2.7.1)
|
142
|
+
rspec-expectations (2.7.0)
|
122
143
|
diff-lcs (~> 1.1.2)
|
123
|
-
rspec-mocks (2.
|
124
|
-
rspec-rails (2.
|
144
|
+
rspec-mocks (2.7.0)
|
145
|
+
rspec-rails (2.7.0)
|
125
146
|
actionpack (~> 3.0)
|
126
147
|
activesupport (~> 3.0)
|
127
148
|
railties (~> 3.0)
|
128
|
-
rspec (~> 2.
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
childprocess (>= 0.1.9)
|
135
|
-
ffi (>= 1.0.7)
|
136
|
-
json_pure
|
149
|
+
rspec (~> 2.7.0)
|
150
|
+
rubyzip (0.9.5)
|
151
|
+
selenium-webdriver (2.15.0)
|
152
|
+
childprocess (>= 0.2.1)
|
153
|
+
ffi (~> 1.0.9)
|
154
|
+
multi_json (~> 1.0.4)
|
137
155
|
rubyzip
|
138
|
-
sexp_processor (3.0.
|
139
|
-
shoulda-matchers (1.0.0
|
140
|
-
simplecov (0.4
|
141
|
-
|
142
|
-
|
143
|
-
|
156
|
+
sexp_processor (3.0.9)
|
157
|
+
shoulda-matchers (1.0.0)
|
158
|
+
simplecov (0.5.4)
|
159
|
+
multi_json (~> 1.0.3)
|
160
|
+
simplecov-html (~> 0.5.3)
|
161
|
+
simplecov-html (0.5.3)
|
162
|
+
sqlite3 (1.3.5)
|
144
163
|
sqlite3-ruby (1.3.3)
|
145
164
|
sqlite3 (>= 1.3.3)
|
146
|
-
term-ansicolor (1.0.
|
165
|
+
term-ansicolor (1.0.7)
|
147
166
|
thor (0.14.6)
|
148
167
|
treetop (1.4.10)
|
149
168
|
polyglot
|
150
169
|
polyglot (>= 0.3.1)
|
151
|
-
tzinfo (0.3.
|
170
|
+
tzinfo (0.3.31)
|
171
|
+
webrobots (0.0.12)
|
172
|
+
nokogiri (>= 1.4.4)
|
173
|
+
xml-simple (1.1.1)
|
152
174
|
xpath (0.1.4)
|
153
175
|
nokogiri (~> 1.3)
|
154
176
|
|
@@ -156,12 +178,16 @@ PLATFORMS
|
|
156
178
|
ruby
|
157
179
|
|
158
180
|
DEPENDENCIES
|
181
|
+
bbbot-ruby!
|
159
182
|
bigbluebutton_rails!
|
183
|
+
capybara-mechanize (= 0.3.0.rc3)
|
184
|
+
capybara-webkit
|
160
185
|
cucumber-rails
|
161
186
|
database_cleaner
|
162
187
|
factory_girl
|
163
188
|
forgery
|
164
189
|
generator_spec
|
190
|
+
launchy
|
165
191
|
rails_best_practices
|
166
192
|
rdoc
|
167
193
|
rspec-rails
|
data/README.rdoc
CHANGED
@@ -14,14 +14,29 @@ Features:
|
|
14
14
|
* Server activity monitor
|
15
15
|
|
16
16
|
Planned features:
|
17
|
-
* Friendly URLs (e.g. http://somewhere.com/my-server/my-room)
|
17
|
+
* Friendly URLs (e.g. http://somewhere.com/my-server/my-room)
|
18
18
|
* Limit the number of users per room and rooms per server
|
19
19
|
* Server administration (modify config.xml, use bbb-conf, etc.)
|
20
|
-
* Load balancing
|
21
20
|
* Decouple servers-rooms to allow server selection on-the-fly
|
21
|
+
* Load balancing
|
22
22
|
|
23
23
|
For more future features and issues check {our google code page}[http://code.google.com/p/mconf/issues/list?can=2&q=label%3AComponent%20label%3ABigBlueButtonRails].
|
24
24
|
|
25
|
+
== Supported BigBlueButton versions
|
26
|
+
|
27
|
+
The current version of this gem supports *all* the following versions of BigBlueButton:
|
28
|
+
|
29
|
+
* 0.8: Currently in the beta3 stage. It can be used with BBB 0.8 but not all features are supported yet, such as pre-upload of slides and anything related to recordings. See {TODO_08}[https://github.com/mconf/bigbluebutton_rails/blob/api-0.8/TODO_08].
|
30
|
+
* 0.7: Including 0.7, 0.71 and 0.71a.
|
31
|
+
|
32
|
+
== Supported ruby versions
|
33
|
+
|
34
|
+
Tested in rubies:
|
35
|
+
|
36
|
+
* ruby-1.8.7
|
37
|
+
* ruby-1.9.2
|
38
|
+
* ree-1.8.7
|
39
|
+
|
25
40
|
== Installation
|
26
41
|
|
27
42
|
You can install the latest version of BigbluebuttonRails using RubyGems:
|
@@ -48,18 +63,7 @@ The routes to BigbluebuttonRails can be generated with the helper <tt>bigbluebut
|
|
48
63
|
|
49
64
|
bigbluebutton_routes :default
|
50
65
|
|
51
|
-
|
52
|
-
bigbluebutton_routes :room_matchers
|
53
|
-
resources :spaces do
|
54
|
-
bigbluebutton_routes :room_matchers
|
55
|
-
end
|
56
|
-
end
|
57
|
-
|
58
|
-
The first line generates the default routes. You need to call it at least once to generate the following routes:
|
59
|
-
|
60
|
-
bigbluebutton_routes :default
|
61
|
-
|
62
|
-
It generates routes scoped with 'bigbluebutton'. These routes look like:
|
66
|
+
It will generate the default routes. You need to call it at least once and the routes will be scoped with 'bigbluebutton'. They will look like:
|
63
67
|
|
64
68
|
/bigbluebutton/servers
|
65
69
|
/bigbluebutton/servers/default-server/rooms/my-room
|
@@ -70,23 +74,23 @@ You can customize the scope name and also make the routes point to custom contro
|
|
70
74
|
bigbluebutton_routes :default, :scope => 'webconference', :controllers => { :servers => 'custom_servers', :rooms => 'custom_rooms' }
|
71
75
|
bigbluebutton_routes :default, :scope => '' # to remove the scope
|
72
76
|
|
73
|
-
If you customize the controllers as in the first line in the example above, be warned that every route generated after this will
|
74
|
-
be using these controllers!
|
75
|
-
|
76
77
|
You may also want shorter routes to access conference rooms. For that, use the option <tt>room_matchers</tt>:
|
77
78
|
|
78
79
|
bigbluebutton_routes :room_matchers
|
79
80
|
|
80
|
-
|
81
|
-
|
81
|
+
resources :users do
|
82
|
+
bigbluebutton_routes :room_matchers
|
83
|
+
end
|
84
|
+
|
85
|
+
It creates routes to the actions used to access the conference room, so you can allow access to webconference rooms using URLs such as:
|
82
86
|
|
83
87
|
http://myserver.com/server-name/room-name/join
|
84
88
|
http://myserver.com/user-name/public-room/join
|
85
89
|
http://myserver.com/ziltoid-room/join
|
86
90
|
|
87
|
-
|
91
|
+
For more information see:
|
88
92
|
|
89
|
-
|
93
|
+
* {How to: Routes}[https://github.com/mconf/bigbluebutton_rails/wiki/How-to:-Routes]
|
90
94
|
|
91
95
|
=== User authorization, permissions and assumptions
|
92
96
|
|
@@ -106,71 +110,13 @@ and you can reimplement them in your application controller to change their beha
|
|
106
110
|
* {How to: Integrate with Devise}[https://github.com/mconf/bigbluebutton_rails/wiki/How-to:-Integrate-with-Devise]
|
107
111
|
* {How to: Integrate with CanCan}[https://github.com/mconf/bigbluebutton_rails/wiki/How-to:-Integrate-with-CanCan]
|
108
112
|
|
109
|
-
== How it works
|
110
|
-
|
111
|
-
=== Overview
|
112
|
-
|
113
|
-
BigbluebuttonRails has two entities: servers and rooms. Servers can have multiple rooms, that belong to a server and can also belong to any other model.
|
114
|
-
You can make a room belong to a user, for example.
|
115
|
-
|
116
|
-
Every server has an associated API object (using the gem bigbluebutton-api-ruby) used to access the BigBlueButton server.
|
117
|
-
The server controller has only the standard CRUD actions defined by Rails.
|
118
|
-
|
119
|
-
The rooms controller also have the CRUD actions, plus some specific actions to join, end, and check if a meeting is currently running in the room.
|
120
|
-
These extra actions will be explained bellow.
|
121
|
-
|
122
|
-
A room model has methods to fetch and send information to the BBB server. They are simple API calls, but the "fetch" methods check the response and store
|
123
|
-
data from it, while the "send" methods just make the API call. You can, for example, use <tt>fetch_meeting_info</tt> to get information about the meeting
|
124
|
-
(will trigger the API call <tt>getMeetingInfo</tt>). The data parsed from the response wil be stored in the model and can be accessed using it's attributes.
|
125
|
-
|
126
|
-
All methods in the models that trigger any API call are documented with "Triggers API call" and the API functions that are called. Be aware that they
|
127
|
-
can throw a BigBlueButtonException.
|
128
|
-
|
129
|
-
=== RoomsController
|
130
|
-
|
131
|
-
==== <tt>running</tt> and <tt>end</tt>
|
132
|
-
|
133
|
-
These are pretty simple actions. <tt>running</tt> returns a json indicating if the conference is running or not, while <tt>end</tt> ends the meeting.
|
134
|
-
|
135
|
-
==== <tt>join_mobile</tt>
|
136
|
-
|
137
|
-
This is an action that simply renders a view with a {QR code}[http://code.google.com/apis/chart/image/docs/gallery/qr_codes.html] and a link to join the
|
138
|
-
conference from a mobile device. The link and the QR code point to links using the protocol "bigbluebutton://", so it can be associated with a native mobile
|
139
|
-
application that will open the conference (such as the {Android client for BigBlueButton}[https://github.com/mconf/mconf-mobile]).
|
140
|
-
|
141
|
-
==== <tt>join</tt>, <tt>invite</tt> and <tt>auth</tt>
|
142
|
-
|
143
|
-
The actions used to redirect a user to join a room are <tt>join</tt> and <tt>invite</tt>, while <tt>auth</tt> is used by <tt>invite</tt> to authenticate
|
144
|
-
the user. Basic differences:
|
145
|
-
|
146
|
-
* <tt>invite</tt> renders a view to ask for a user name and a password. It is used to enable <b>anonymous users</b> to join a room or
|
147
|
-
to define the user role using the <b>room password</b> instead of the <tt>bigbluebutton_role</tt> method.
|
148
|
-
* It first checks <tt>bigbluebutton_role</tt> to see if the current user already has a role in the target room.
|
149
|
-
* In case it has (see {controller_methods.rb}[https://github.com/mconf/bigbluebutton_rails/blob/master/lib/bigbluebutton_rails/controller_methods.rb] for more info), redirects to <tt>join</tt>.
|
150
|
-
* Otherwise:
|
151
|
-
* If there is a user logged, uses <tt>bigbluebutton_user().name</tt> as the user name. Otherwise, ask the user to type a name.
|
152
|
-
* <tt>join</tt> requires a <b>logged user</b> and uses <tt>bigbluebutton_role</tt> to get the role for this user
|
153
|
-
* It redirects the user straight to the meeting if the join is successful.
|
154
|
-
* In case there's no role associated with the current user, falls back to <tt>invite</tt> to ask for a password.
|
155
|
-
|
156
|
-
Internally, they use the same algorithm:
|
157
|
-
|
158
|
-
* If the user is a moderator:
|
159
|
-
* If the room is not created yet, creates it.
|
160
|
-
* Redirects the user to the meeting as a moderator.
|
161
|
-
* If the user is not a moderator (a normal attendee):
|
162
|
-
* If the meeting is running, redirects the user to the meeting as an attendee.
|
163
|
-
* Otherwise:
|
164
|
-
* <tt>join</tt> renders the join view, to wait for a moderator before joining the conference. The page will continuously pool the server to check if the meeting is running. When it starts, it redirects the user to the conference.
|
165
|
-
* <tt>invite</tt> renders the invite view again and shows a warning informing that the meeting is not running. The user must re-submit the form to try again.
|
166
|
-
|
167
113
|
== Contributing/Development
|
168
114
|
|
169
115
|
Fork this repository, clone your fork and start by installing the dependencies:
|
170
116
|
|
171
117
|
bundle install
|
172
118
|
|
173
|
-
Edit <tt>spec/integration_conf.yml.example</tt> and set values for an existent BigBlueButton server. Save it as <tt>spec/integration_conf.yml</tt>. You will need it to run the integration tests.
|
119
|
+
Edit <tt>spec/rails_app/features/integration_conf.yml.example</tt> and set values for an existent BigBlueButton server. Save it as <tt>spec/integration_conf.yml</tt>. You will need it to run the integration tests. For more information see the page [Testing](https://github.com/mconf/bigbluebutton_rails/wiki/Testing) in our wiki.
|
174
120
|
|
175
121
|
Prepare the rails_app used for tests:
|
176
122
|
|