Step 1: SSH into your server.
Step 2: Create second account for SSH. You’ll have to have Super User privileges
$ su -
$ adduser yournewuser
and it will ask you to add a password etc.
Step 3: Probably a good idea to logout of SSH and log back in with your new account, esp if it’s your only other account.
Step 4: Edit ssh_config, also as Super User
$ su -
$ nano /etc/ssh/sshd_config
Find the line for PermitRootLogin and make it look like this:
PermitRootLogin no
Step 5: Restart your SSH server. On Ubuntu, this is recommended by everybody
/etc/init.d/sshd restart
It doesn’t work for me, but this does:
/etc/init.d/ssh restart
Following tutorials around the net for installing ActiveAdmin, I encountered several errors.
First was this when trying to run rails generate active_admin:install:
/Users/user_name/.rvm/gems/ruby-1.9.2-p290/gems/rack-1.3.4/lib/rack/backports/uri/common_192.rb:53: warning: already initialized constant WFKV_
Solution is to add gem 'rack', '1.3.3' in your Gemfile to specify your rack version and then of course run bundle install to implement the other version.
The next one was when trying to run rake db:migrate, I got a bunch of errors like this:
warning: already initialized constant MAJOR
This was solved by running bundle exec rake db:migrate instead, which as I understand, effectively runs the migrate with the version of rake in your application’s directory.
Finally I got this one:
/Users/user_name/Sites/ruby/active_admin_example/config/initializers/session_store.rb:3: syntax error, unexpected ':', expecting $end
...sion_store :cookie_store, key: '_active_admin_example_sessio...
You should note that my application name was “active_admin_example” and this ended up being the culprit. Make sure you name your project with something not including the phrase “active_admin” or “activeadmin” or anything close to that. I’m a beginner to Rails and maybe this is an obvious bad practice when trying out new gems. It seems to be…
Hope this helps!