2017-03-25 11 views
0

私は約1ヶ月間レールを勉強していて、レール上でルビーを使って最初の単純な静的なウェブサイトを作成しました。それはlocalhost:3000でうまく機能します。なぜ私のウェブサイトは英雄に配備されていないのですか?

私はすべてのファイルをGitHubにプッシュし、GitHubとherokuを使用してサイトを展開する方法についていくつかのYoutubeビデオに従ってきました。私はそれらを使用して私が得たいくつかのエラーを解決し、最終的にサイトを展開することができました。

しかし、私が得るのは、それが私のサイトであることを示すような一種のウェルカムページです。 "Heroku。あなたの新しいアプリへようこそ。"それに書かれています。私は行方不明の最終段階は何ですか?どうして私のウェブサイトが見えないのですか?

以下

は、アプリケーションログ、次のとおりです。ここで

2017-03-22T20:20:58.057644+00:00 app[api]: Release v1 created by user *******@******.com 

2017-03-22T20:20:58.063330+00:00 app[api]: Release v2 created by user *******@******.com 

2017-03-22T20:20:58.189041+00:00 app[api]: Release v2 created by user *******@******.com 

2017-03-22T20:31:55.915631+00:00 heroku[router]: at=info code=H81 desc="Blank app" method=GET path="/" host=vast-shelf-39597.herokuapp.com request_id=d69fedea-d149-4836-b349-aa490c3b9654 fwd="88.11.201.253" dyno= connect= service= status=502 bytes= protocol=https 

2017-03-22T20:31:56.290278+00:00 heroku[router]: at=info code=H81 desc="Blank app" method=GET path="/favicon.ico" host=vast-shelf-39597.herokuapp.com request_id=0c5752c0-b960-443e-8f07-0c2346055ff9 fwd="88.11.201.253" dyno= connect= service= status=502 bytes= protocol=https 

2017-03-24T18:44:37.424270+00:00 heroku[router]: at=info code=H81 desc="Blank app" method=GET path="/" host=vast-shelf-39597.herokuapp.com request_id=62e3ddce-34e5-4fb2-892b-2ae9cf5ca93d fwd="88.11.201.253" dyno= connect= service= status=502 bytes= protocol=https 

2017-03-24T18:44:37.811237+00:00 heroku[router]: at=info code=H81 desc="Blank app" method=GET path="/favicon.ico" host=vast-shelf-39597.herokuapp.com request_id=7a5b7d99-1b83-406d-bdc2-c68c3d5efa33 fwd="88.11.201.253" dyno= connect= service= status=502 bytes= protocol=https 

2017-03-24T18:44:55.237261+00:00 heroku[router]: at=info code=H81 desc="Blank app" method=GET path="/" host=vast-shelf-39597.herokuapp.com request_id=4057726f-e2b9-464b-a970-b37306051e63 fwd="88.11.201.253" dyno= connect= service= status=502 bytes= protocol=https 

2017-03-25T20:29:38.837541+00:00 heroku[router]: at=info code=H81 desc="Blank app" method=GET path="/" host=vast-shelf-39597.herokuapp.com request_id=47282fae-e30f-43d1-be52-808c956cad7b fwd="88.11.201.253" dyno= connect= service= status=502 bytes= protocol=https 

2017-03-25T21:10:30.120292+00:00 heroku[router]: at=info code=H81 desc="Blank app" method=GET path="/" host=vast-shelf-39597.herokuapp.com request_id=94863f09-962f-49d5-90db-c0fbf7ac0c8a fwd="88.11.201.253" dyno= connect= service= status=502 bytes= protocol=https 

2017-03-26T11:07:07.914421+00:00 heroku[router]: at=info code=H81 desc="Blank app" method=GET path="/" host=vast-shelf-39597.herokuapp.com request_id=c3fac4f9-8786-493c-a859-05690842ca89 fwd="88.11.201.253" dyno= connect= service= status=502 bytes= protocol=https 

は私のルートファイルです:ノー、「根」と欠けているものがあると思いますか?

Rails.application.routes.draw do 
    get 'handm/home' 
    get 'handm/about' 
    get 'handm/contact' 
    get 'handm/industries' 
    get 'handm/languages' 
    get 'handm/services' 
+1

デプロイメントのスクリーンショットとherokuアプリ名 –

+0

を送信できますか?また、Herokuログを投稿します(ビューログをクリックするとアプリにアクセスできます)。 – Gerry

+0

私のアプリがgit repoのルートにないので、私はこれを起こしました。私はherokuにプッシュしました –

答えて

1

デプロイは問題ありません。

アプリケーションのルートルートを設定する必要があります。ルートルートとは、ユーザーが最初にあなたのアプリケーションにアクセスしたときに移動するルートです。

必要に応じてルートファイルを変更するだけでなく、最初のものに必要なルートをhomeとします。

変更この

get 'handm/home' 

この

root 'handm#home' 

へのgitにプッシュして、Herokuのにデプロイすることを確認します。

+0

Ok素晴らしい、私はいくつかの進歩を遂げました。あなたが提案した変更を行うと、ホームページがWebブラウザに表示されます。しかし、2つの小さなことがあります。まず、他のページはクリックされたときに表示されません。このページが存在しないというエラーページが表示されます。第二に、ウェブサイトのアドレスは、Herokuによって生成されたアドレスです。私はドメイン名を購入し、それを変換する方法を見つけることができません。ありがとう。 – Owen

+0

はいあなたは確かにそれを行うことができます –

+0

私はどのように答えを受け入れますか?別のスレッドを開始します – Owen

関連する問題