質問をすることでしか得られない、回答やアドバイスがある。

15分調べてもわからないことは、質問しよう!

新規登録して質問してみよう
ただいま回答率
85.47%
Ruby

Rubyはプログラミング言語のひとつで、オープンソース、オブジェクト指向のプログラミング開発に対応しています。

Q&A

解決済

4回答

6264閲覧

rubyのサーバー起動について

tidavest

総合スコア595

Ruby

Rubyはプログラミング言語のひとつで、オープンソース、オブジェクト指向のプログラミング開発に対応しています。

0グッド

2クリップ

投稿2015/03/18 11:06

編集2015/03/18 12:42

rubyにwebrickというサーバー起動ツールが、標準添付されているということで、コマンドプロンプトに、rails serverと打ち込んだのですが、いろいろ文字が出てきて、おそらく起動できませんでした。ブラウザにhttp://localhost:3000/と入力しても、何も表示されませんでしたので、どうすればサーバーを起動できますでしょうか。教えてください。

ruby 2.0.0p643 (2015-02-25) [i386-mingw32]

C:\Documents and Settings\demonstration>rails server
DL is deprecated, please use Fiddle
Usage:
rails new APP_PATH [options]

Options:
-r, [--ruby=PATH] # Path to the Ruby bina
ry of your choice
# Default: C:/Ruby200/b
in/ruby.exe
-m, [--template=TEMPLATE] # Path to some applicat
ion template (can be a filesystem path or URL)
[--skip-gemfile], [--no-skip-gemfile] # Don't create a Gemfil
e
-B, [--skip-bundle], [--no-skip-bundle] # Don't run bundle inst
all
-G, [--skip-git], [--no-skip-git] # Skip .gitignore file
[--skip-keeps], [--no-skip-keeps] # Skip source control .
keep files
-O, [--skip-active-record], [--no-skip-active-record] # Skip Active Record fi
les
-S, [--skip-sprockets], [--no-skip-sprockets] # Skip Sprockets files
[--skip-spring], [--no-skip-spring] # Don't install Spring
application preloader
-d, [--database=DATABASE] # Preconfigure for sele
cted database (options: mysql/oracle/postgresql/sqlite3/frontbase/ibm_db/sqlserv
er/jdbcmysql/jdbcsqlite3/jdbcpostgresql/jdbc)
# Default: sqlite3
-j, [--javascript=JAVASCRIPT] # Preconfigure for sele
cted JavaScript library
# Default: jquery
-J, [--skip-javascript], [--no-skip-javascript] # Skip JavaScript files

[--dev], [--no-dev] # Setup the application

with Gemfile pointing to your Rails checkout
[--edge], [--no-edge] # Setup the application
with Gemfile pointing to Rails repository
[--skip-turbolinks], [--no-skip-turbolinks] # Skip turbolinks gem
-T, [--skip-test-unit], [--no-skip-test-unit] # Skip Test::Unit files

[--rc=RC] # Path to file containi

ng extra configuration options for rails command
[--no-rc], [--no-no-rc] # Skip loading of extra
configuration options from .railsrc file

Runtime options:
-f, [--force] # Overwrite files that already exist
-p, [--pretend], [--no-pretend] # Run but do not make any changes
-q, [--quiet], [--no-quiet] # Suppress status output
-s, [--skip], [--no-skip] # Skip files that already exist

Rails options:
-h, [--help], [--no-help] # Show this help message and quit
-v, [--version], [--no-version] # Show Rails version number and quit

Description:
The 'rails new' command creates a new Rails application with a default
directory structure and configuration at the path you specify.

You can specify extra command-line arguments to be used every time 'rails new' runs in the .railsrc configuration file in your home directory. Note that the arguments specified in the .railsrc file don't affect the defaults values shown above in this help message.

Example:
rails new ~/Code/Ruby/weblog

This generates a skeletal Rails installation in ~/Code/Ruby/weblog. See the README in the newly created application to get going.

C:\Documents and Settings\demonstration>

気になる質問をクリップする

クリップした質問は、後からいつでもMYページで確認できます。

またクリップした質問に回答があった際、通知やメールを受け取ることができます。

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

tomomo

2015/03/18 12:04

おそらく? その"いろいろ文字が出てきて"の中にエラーメッセージが含まれていると思われ、それを載せたほうが回答がつくと思います。あと使用しているOSやrubyのヴァージョンなども。
tidavest

2015/03/18 12:25

DL is deprecated,please use fiddle.と最初に表示され、あとからずらずらと文字が表示されます。使っている、OSは、XPのサービスパック3 rubyのバージョンは、2.0.0.0p643です。宜しくお願いします。
jollyjoester

2015/03/18 12:36

そのずらずらもコピペでぜひ載せていただきたく。そこが大事なところです。
tidavest

2015/03/18 12:43

タグを追加いたしました。お願いします。
tidavest

2015/03/18 13:06

すいません。実行されたスクリプト中に DL を使っているところがあるはずなので、 そこを Fiddle に書き直す必要があります。 ここの部分をどうやるのか教えていただけますでしょうか。
guest

回答4

0

ベストアンサー

質問に記載されている情報だけから察するに単にプロジェクトを作ってないようにも見受けられました。
作って、移動して、起動すればいいのではないかと。。。

lang

1# 例えば"demo"というプロジェクトを作る。 2rails new demo 3 4# プロジェクトの直下に移動する。 5cd demo 6 7# サーバーを起動する。 8rails s

DL is ナンタラの部分が経験ないので起動にどのような影響を与えるのかはわからないですが、少なくとも質問で記載されているメッセージ(状況)は変わるかと。

投稿2015/03/18 17:06

tomomo

総合スコア430

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

tidavest

2015/03/21 14:16

そうですね。ありがとうございます。
guest

0

おそらくtomomoさんの回答で解決するとして、railsやるならVM立てたほうが何かとやりやすい気もします。rails-dev-boxがGithubに公開されているので、構築自体は何回かコマンド打つだけでできるので。

投稿2015/03/23 14:42

kenixi

総合スコア91

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

0

参考:

投稿2015/03/18 13:51

katoy

総合スコア22324

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

0

ここに同様の質問をして解決された方がいるようです。参照ください。
https://teratail.com/questions/1411

上記の回答のやり方以外にもRubyのバージョンを1.9に落としてもうまくいくかもしれません。

投稿2015/03/18 12:53

編集2015/03/18 13:08
jollyjoester

総合スコア1585

バッドをするには、ログインかつ

こちらの条件を満たす必要があります。

tidavest

2015/03/18 13:05

どうもありがとうございます。
guest

あなたの回答

tips

太字

斜体

打ち消し線

見出し

引用テキストの挿入

コードの挿入

リンクの挿入

リストの挿入

番号リストの挿入

表の挿入

水平線の挿入

プレビュー

15分調べてもわからないことは
teratailで質問しよう!

ただいまの回答率
85.47%

質問をまとめることで
思考を整理して素早く解決

テンプレート機能で
簡単に質問をまとめる

質問する

関連した質問