Ask A Question

Notifications

You’re not receiving notifications from this thread.

Setup Ubuntu 16.04 Xenial Xerus Discussion

Chris Oliver asked in General
Kenneth Halsted Kenneth Halsted

Just ran everything perfectly. Now I just need to learn how to use Rails.

Reply
Peter David Carter Peter David Carter

There are so many coding tutorials out there with missing bits, or bits that half-work. Everything here worked first time. Good job!

Reply
Muhammed Rajeef M K Muhammed Rajeef M K

In case anybody is stuck at rake db:create,

Make sure Inside your databse.yml file, under default: you have the following ( right below pool)

host: localhost
username : your username
password : user's password

Reply

When I run "rails server" i see below stuff and doesnt seem to start listening in localhost:3000
Any ideas?
https://uploads.disquscdn.c...

Reply

Whenever I use the rails server command or ANY command, I get this - a deprecated warning, what do I do with this? Any way to fix it? And also, how do we uninstall rails if I used rbenv?

username@name:~/Desktop/Web/Rails/myapp$ rails server
/home/username/.rbenv/versions/2.4.0/lib/ruby/gems/2.4.0/gems/activesupport-5.0.1/lib/active_support/xml_mini.rb:51: warning: constant ::Fixnum is deprecated
/home/username/.rbenv/versions/2.4.0/lib/ruby/gems/2.4.0/gems/activesupport-5.0.1/lib/active_support/xml_mini.rb:52: warning: constant ::Bignum is deprecated
=> Booting Puma
=> Rails 5.0.1 application starting in development on http://localhost:3000
=> Run `rails server -h` for more startup options
/home/username/.rbenv/versions/2.4.0/lib/ruby/gems/2.4.0/gems/activesupport-5.0.1/lib/active_support/core_ext/numeric/conversions.rb:138: warning: constant ::Fixnum is deprecated
Puma starting in single mode...
* Version 3.7.0 (ruby 2.4.0-p0), codename: Snowy Sagebrush
* Min threads: 5, max threads: 5
* Environment: development
* Listening on tcp://0.0.0.0:3000
Use Ctrl-C to stop

Reply
Ruan Kovalczyk Ruan Kovalczyk

It is solved in Rails 5.0.2

Reply
shashank shandilya shashank shandilya

warning: constant ::Fixnum is deprecated
warning: constant ::Bignum is deprecated

i am getting these errors while executing rake command stackoverflow thread said this is the problem with ruby 2.4.0 can may i know how to downgrade my ruby gem

Reply
Mark Mbirira Mark Mbirira

thanks, this was useful!

Reply
Ronald Brenner Ronald Brenner

First of all: Great Guide!
Ive got a little different question going to PageFlow. As this is the best Rails/RoR guide ive found and pretty lost right now i thought i could give it a try here:
I followed every step described here, installed ruby 2.3.1p112 and rails 4.2.7.1
as i try running rails generate pageflow:install i get following error message:
/home/pageflow/.rbenv/versions/2.3.1/lib/ruby/gems/2.3.0/gems/pageflow-0.11.3/lib/pageflow/global_config_api.rb:17:in `config': Pageflow has not been configured yet (RuntimeError)

since my ruby know how is === 0 maybe one of you ran into the same problem or knows how to solve it? https://uploads.disquscdn.c...

Best regards,
Ronald

Reply

Great article, really helped a lot in installing ruby on rails and starting my first application.

Reply

/etc/nginx/sites-enabled/default is not available for me

Reply

Hey Chris, this was great for a beginner like me. Though, the only problem I had was with creating a new user for the postgres database as I get "could not change directory to "/home/whoarse": Permission denied". Not sure where to start with this??

Reply

Hey Chris, this was great for a beginner like me. Though, the only problem I had was with creating a new user for the postgres database as I get "could not change directory "/home/whaorse": Permission denied". Not sure where to start with this??

Reply
Darpan Patil Darpan Patil

Err:10 http://ppa.launchpad.net/fo... xenial/main amd64 Packages
404 Not Found
Ign:12 http://ppa.launchpad.net/fo... xenial/main i386 Packages
Ign:13 http://ppa.launchpad.net/fo... xenial/main all Packages
Ign:15 http://ppa.launchpad.net/fo... xenial/main Translation-en_IN
Ign:16 http://ppa.launchpad.net/fo... xenial/main Translation-en
Ign:17 http://ppa.launchpad.net/fo... xenial/main amd64 DEP-11 Metadata
Ign:18 http://ppa.launchpad.net/fo... xenial/main DEP-11 64x64 Icons
Err:20 http://ppa.launchpad.net/li... xenial/main amd64 Packages
404 Not Found

Reply

thanks

Reply
Ernesto Almeda (MTGONS5) Ernesto Almeda (MTGONS5)

Probably the easiest Setup I've came across. Good Job!

Reply
Matias Tarantini Matias Tarantini

I would recommend also installing ruby-dev:
`sudo apt-get install ruby-dev`

Reply

This has solved my current installation problem and some that I would have definitely run into.
Thanks Chris.

Reply
David Timony David Timony

Tried for two full nights to install rails on Ubuntu, this is the first site to explain step by step, so a HUGE Thank You! I'm now on my way up the learning curve.

Reply
Eduardo Medina Eduardo Medina

Why this way and not taking the packages from repositories? Is it due old versions and incompatibilities?

Reply

Usually the distros...
1) doesn`t have an updated version of ruby.
2) installs a system wide ruby. So, for an user to install a gem he would need sudo and also there wouldn`t have gem set isolation.
3) from 2), there is no version management, like rbenv and rvm.

Reply

Icing on the cake:
echo 'gem: --no-rdoc --no-ri' >> ~/.gemrc
gem install pry && echo 'alias irb=pry' >> ~/.bashrc

Reply
Join the discussion
Create an account Log in

Want to stay up-to-date with Ruby on Rails?

Join 81,842+ developers who get early access to new tutorials, screencasts, articles, and more.

    We care about the protection of your data. Read our Privacy Policy.

    Screencast tutorials to help you learn Ruby on Rails, Javascript, Hotwire, Turbo, Stimulus.js, PostgreSQL, MySQL, Ubuntu, and more.

    © 2024 GoRails, LLC. All rights reserved.