2014-04-10 12:09:21 +02:00
[](https://travis-ci.org/openSUSE/osem)
2014-04-09 17:05:34 +02:00
[](https://codeclimate.com/github/openSUSE/osem)
2014-04-09 17:27:17 +02:00
[](https://coveralls.io/r/openSUSE/osem)
2014-04-25 18:13:20 +02:00
[](https://hakiri.io/github/openSUSE/osem/master)
2013-10-30 17:55:29 +01:00
#OSEM
2013-08-14 18:18:50 +02:00
The Open Source Event Manager. An event management tool tailored to Free and Open Source Software conferences.
2012-09-22 00:40:18 -07:00
2014-04-08 21:02:10 +02:00
## Install OSEM
You can run rails apps in different modes (development, production). For more information
about rails and what it can do, see the [rails guides. ](http://guides.rubyonrails.org/getting_started.html )
2013-08-15 16:51:57 +02:00
2014-04-08 21:02:10 +02:00
### Run OSEM in development
2013-10-30 17:55:29 +01:00
1. Clone the git repository to the directory you want Apache to serve the content from.
```
git clone https://github.com/openSUSE/osem.git
```
2. Install all the ruby gems.
```
bundle install
```
2014-04-08 21:02:10 +02:00
3. Install ImageMagick from your distribution repository
2014-06-20 15:26:15 +03:00
4. Generate secret key for devise and the rails app with
2014-04-30 10:54:59 +05:30
```
rake secret
```
Look at config/config.yml.example.
5. Copy the sample configuration files and adapt them
2013-10-30 17:55:29 +01:00
```
cp config/config.yml.example config/config.yml
cp config/database.yml.example config/database.yml
2014-07-05 13:07:30 +03:00
cp config/secrets.yml.example config/secrets.yml
2013-10-30 17:55:29 +01:00
```
2014-04-08 21:02:10 +02:00
6. Setup the database
2013-10-30 17:55:29 +01:00
```
2014-04-08 21:02:10 +02:00
bundle exec rake db:setup
2013-10-30 17:55:29 +01:00
```
2014-04-30 10:54:59 +05:30
2014-04-08 21:02:10 +02:00
7. Run OSEM
2013-10-30 17:55:29 +01:00
```
2014-04-08 21:02:10 +02:00
rails server
2013-10-30 17:55:29 +01:00
```
2014-06-20 15:26:15 +03:00
8. Visit the APP at
2013-10-30 17:55:29 +01:00
```
2014-04-08 21:02:10 +02:00
http://localhost:3000
2013-10-30 17:55:29 +01:00
```
2014-04-08 21:02:10 +02:00
9. Sign up, the first user will be automatically assigned the admin role.
2013-10-30 17:55:29 +01:00
2014-06-20 15:26:15 +03:00
10. Use openID
In order to use the OpenID feature you need to register your application with the providers
(Google and Facebook) and enter their API keys in config/secrets.yml file, changing the existing sample values.
2014-06-20 20:13:56 +03:00
2014-06-20 15:26:15 +03:00
You can register as a devoloper with Google from https://code.google.com/apis/console#:access
2014-06-20 20:13:56 +03:00
You can register as a devoloper with Facebook from https://developers.facebook.com/,
by selecting from the top menu the option 'Apps' -> 'Create a New App'
Unless you add the key and secret for each provider, you will not be able to see the image that
redirects to the login page of the provider.
If you add a provider that does not require developers to register their application, you still need
to create two (2) variables, in config/secrets.yml
with the format of providername_key and providername_secret and add some sample text as their values.
Example:
myprovider_key = 'sample data'
myprovider_secret = 'sample data'
That is required so that the check in app/views/devise/shared/_openid.html.haml will pass and
the image-link to login using the provider will be shown.
2014-06-20 15:26:15 +03:00
2014-04-08 21:02:10 +02:00
### Run OSEM in production
We recommend to run OSEM in production with [mod_passenger ](https://www.phusionpassenger.com/download/#open_source )
and the [apache web-server ](https://www.apache.org/ ). There are tons of guides on how to deploy rails apps on various
base operating systems. Check Google ;-)
2013-10-30 17:55:29 +01:00
2014-04-08 21:02:10 +02:00
## Documentation
OSEM is extensively (some would say maniacally ;-) documented. You can generate a nice HTML documentation with ''rdoc''
2013-10-30 17:55:29 +01:00
```
2014-06-20 15:26:15 +03:00
bundle exec rdoc --op doc/app --all -f fivefish app
xdg-open doc/app/index.html
2013-10-30 17:55:29 +01:00
```
2014-04-09 01:37:59 +02:00
## Testing
2014-04-26 16:52:31 +02:00
We are using [rspec ](http://rspec.info/ )+[capybara ](http://jnicklas.github.io/capybara/ )+[factory girl ](https://github.com/thoughtbot/factory_girl ) to build test suite. You *should* run it continuously when you are developing, via:
2014-04-09 01:37:59 +02:00
```
2014-04-26 16:52:31 +02:00
bundle exec guard
2014-04-09 01:37:59 +02:00
```
2014-04-26 16:52:31 +02:00
This uses [spring ](https://github.com/rails/spring ) to provide a
[fast feedback loop for the red/green cycle ](http://bitzesty.com/blog/2013/05/enable-tdd-with-faster-ruby-on-rails-stack-reloading/ ).
2014-07-04 22:59:27 +02:00
2014-07-22 10:22:12 +02:00
## Style
We are using [rubocop ](https://github.com/bbatsov/rubocop ) as a style checker. It is running each time
Travis run its testing routine. If you want to run it locally just `bundle exec rubocop` .
You can read through current enabled rules in `.rubocop.yml` file. Explanations of the defined [rules ](http://rubydoc.info/github/bbatsov/rubocop/master/frames ) can be found in modules [Cop::Lint ](http://rubydoc.info/github/bbatsov/rubocop/master/Rubocop/Cop/Lint ) and [Cop::Style ](http://rubydoc.info/github/bbatsov/rubocop/master/Rubocop/Cop/Style ).
Additionally you can read through [community ruby style-guide ](https://github.com/bbatsov/ruby-style-guide ) to better understand core principles.
2014-07-04 22:59:27 +02:00
# Communication
GitHub issues are the primary way for communicating about specific proposed
changes to this project. If you have other questions feel free to subscribe to
the [opensuse-web@opensuse.org ](http://lists.opensuse.org/opensuse-web/ )
mailinglist, all OSEM contributors are on that list! Additionally you can use #osem channel
on freenode IRC.