LoginSignup
0
0

More than 3 years have passed since last update.

Ubuntuにてrails6.0の環境構築(備忘録)

Last updated at Posted at 2020-02-15

Ruby on Rails 6.0を、以下記事を参考にさせていただきながら、環境構築をしました。(厳密にいうとまだできてませんが)
備忘録として残す&誰かのお役に立てれば&なぜ最後だけできないのか誰か教えてほしい、ということで書きます。

参考記事はこちら

やったこと

上記記事どおりに環境構築。

git clone https://github.com/sstephenson/rbenv.git ~/.rbenv

上記実施時に

fatal: destination path 'パス名' already exists and is not an empty directory.

って出て困惑しましたが、すでにあるから置けないよってことらしいので気にせず実施。

未解決の部分

すべて実施し、よっしゃあ最後だ!終わった!と思って起動しようとしたところ、

:~/dev/sample$ rails s -b 0.0.0.0
/パス名/versions/2.6.2/lib/ruby/gems/2.6.0/gems/railties-6.0.2.1/lib/rails/app_loader.rb:53: warning: Insecure world writable dir /パス名/versions/2.6.2 in PATH, mode 040777
=> Booting Puma
=> Rails 6.0.2.1 application starting in development
=> Run `rails server --help` for more startup options
Puma starting in single mode...
* Version 3.12.2 (ruby 2.6.2-p47), codename: Llamas in Pajamas
* Min threads: 5, max threads: 5
* Environment: development
* Listening on tcp://0.0.0.0:3000
Use Ctrl-C to stop

との表示。やったか!?

無題.png

はい。ポートが開いてないのかと思ってufwのコマンドも試してみたが弾かれ。iptablesは更新したんだけども。。。

:~/dev/sample$ sudo ufw allow 3000/tcp
WARN: initcaps
[Errno 2] iptables v1.6.1: can't initialize iptables table `filter': Table does not exist (do you need to insmod?)
Perhaps iptables or your kernel needs to be upgraded.

初心者で本当にわからないのでわかる人いたらご教示願います。。。

2020/02/06 追記

いけました。rails sで起動して、localhostに繋げばいいだけやった。あほすぎて恥ずかしい。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0