Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8638169
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T10:39:32+00:00 2026-06-12T10:39:32+00:00

We have used Devise + OmniAuth as authentication mechanism to authenticate user with facebook,

  • 0

We have used Devise + OmniAuth as authentication mechanism to authenticate user with facebook, twitter and openid. Now we need to integrate Refinery CMS into our existing application.

Requirement:
The home page of application has Signup/Signin buttons with some static content. On Signing in, user is able to access restricted area. We want to add a link to access Refinery CMS on a restricted page. It should not ask for any credential again.

We followed following links to integrate Refinery CMS:

  1. http://refinerycms.com/guides/with-an-existing-rails-app
  2. http://refinerycms.com/guides/with-an-existing-rails-31-devise-app

Now after starting server, when we hit http://localhost:3000 it redirects to http://localhost:3000/refinery/users/register. User should be able to see home page with public content. User can access refinery CMS(through /help) only after user authenticate himself with any supported services.

Here is snap of config/routes.rb

mount Refinery::Core::Engine, :at => '/'
...
devise_for :users, :controllers => { :omniauth_callbacks => "users/omniauth_callbacks", registrations: "registrations" }
....
root :to => "home#index"

config/application.rb

config.autoload_paths += Dir["#{config.root}/lib/**/"] # to load files from lib directory, including subfolders

    config.before_initialize do
      require 'refinery_patch'
      require 'restrict_refinery_to_refinery_users'
    end

    include Refinery::Engine
    after_inclusion do
      [ApplicationController, ApplicationHelper].each do |c|
        c.send :include, ::RefineryPatch
      end

      ::Refinery::AdminController.send :include, ::RestrictRefineryToRefineryUsers
      ::Refinery::AdminController.send :before_filter, :restrict_refinery_to_refinery_users
    end

We are beginner. Any help would be appreciable.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T10:39:33+00:00Added an answer on June 12, 2026 at 10:39 am

    we followed http://sdownie.com/blogs/integrating-refinery-rails-3-2-into-your-existing-rails-app which worked.

    We had some issues which were discussed here.

    https://groups.google.com/d/topic/refinery-cms/G5twqi0uTHs/discussion
    https://groups.google.com/d/topic/refinery-cms/w-4VrfPewQY/discussion

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I used devise and omniauth-facebook in my Rails 3 app for Facebook authentication, based
I have an application which integrates with facebook via oauth2 devise/warden/omniauth. Everything works find
We have used Shibboleth to authenticate users. It works great. The issue is that
I'm developing Rails application and I have to use authentication. I installed devise gem
I have a rails app that is using Devise, with a User model, no
I currently have an app that uses regular Devise authentication for logging in and
I have a Rails 3 application using Devise for authentication. In addition to the
I am using the devise gem, and I have had user registration working in
Currenntly, my application is designed using Devise for authentication. I have it so when
Im using devise with omniauth for signing in users with facebook. I want them

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.