diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 62c0bf27..ec8376ce 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -169,6 +169,18 @@ config.ichain_force_test_username = "testuser" # set email of 'testuser' config.ichain_force_test_attributes = {:email => "testuser@example.com"} ``` + +### Using OpenID in developement +OSEM supports [OpenID](https://openid.net/) logins via [OmniAuth](https://github.com/omniauth/omniauth) and related provider specific gems. OmniAuth provides the ablity to define per-provider mock accounts for testing. The supported providers are Facebook, Google, openSUSE and GitHub. If you want to use the OSEM provided mock accounts you need to set the appropriate `OSEM_PROVIDER_KEY` and `OSEM_PROVIDER_SECRET` environment variables to a non empty string in the `.env` file. + +e.g. +``` +OSEM_GITHUB_KEY='sample' +OSEM_GITHUB_SECRET='sample' +``` + +If you don't already have a `.env` file you can use the `dotenv.example` as a template. + ## Labels for issues and PRs ...and what they mean! diff --git a/INSTALL.md b/INSTALL.md index 02b496eb..9cbfafcc 100644 --- a/INSTALL.md +++ b/INSTALL.md @@ -43,6 +43,8 @@ There are a couple of environment variables you can set to configure OSEM. Check | OSEM_FACEBOOK_SECRET | *string* | OMNIAUTH Developer Secret for Facebook | OSEM_GITHUB_KEY | *string* | OMNIAUTH Developer Key for GitHub | OSEM_GITHUB_SECRET | *string* | OMNIAUTH Developer Secret for GitHub +| OSEM_SUSE_KEY | *string* | OMNIAUTH Developer Key for openSUSE +| OSEM_SUSE_SECRET | *string* | OMNIAUTH Developer Secret for openSUSE | OSEM_SMTP_ADDRESS | smtp.opensuse.org | The smtp server to use | OSEM_SMTP_PORT | *int* | The port on the smtp server | OSEM_SMTP_USERNAME | *string* | The user for the smtp server @@ -69,7 +71,7 @@ $ bundle exec rake logo:reprocess ``` ### openID -In order to use [openID](http://openid.net/) logins for your OSEM installation you need to register your application with the providers ([Google](https://code.google.com/apis/console#:access), [GitHub](https://github.com/settings/applications/new) or [Facebook](https://developers.facebook.com/)) and enter their API keys, changing the existing sample values, in `config/secrets.yml` file, or in your environment variables found in *.env.production* file. +In order to use [openID](http://openid.net/) logins for your OSEM installation you need to register your application with the providers ([Google](https://code.google.com/apis/console#:access), [GitHub](https://github.com/settings/applications/new) or [Facebook](https://developers.facebook.com/)) and enter their API keys in the environment variables found in your *.env* file(s). ## Recurring Jobs Open a separate terminal and go into the directory where the rails app is present, and type the following to start the delayed_jobs worker for sending email notifications. diff --git a/dotenv.example b/dotenv.example index ec2715ea..0c852658 100644 --- a/dotenv.example +++ b/dotenv.example @@ -37,6 +37,10 @@ OSEM_FACEBOOK_SECRET='' OSEM_GITHUB_KEY='' OSEM_GITHUB_SECRET='' +# OMNIAUTH Developer KEY/Secret for SUSE/openSUSE +OSEM_SUSE_KEY='' +OSEM_SUSE_SECRET='' + # STRIPE Publishable/Secret keys # test keys for development mode, live for production mode STRIPE_PUBLISHABLE_KEY=''