phpの勉強中です。
「確かな力が身につく PHP「超」入門」という参考書を使用しています。
後半のチャプターで制作物を公開するパートまで行ったのですが
vagrant upがうまくできず ブラウザ「google chrome」にうまく繋がってくれません。
何をどうしたらいいのかお教え頂きたいです。
該当のソースコード
vagrant up
試したこと
VirtualBoxとVagrantをアンインストールして再度インストールしても変化なしです。
補足情報(FW/ツールのバージョンなど)
VirtualBoxとVagrantはどちらもバージョンは最新です。
vagrantFileは参考書のコードをそのまま使用していました。
###追記 実施後
回答ありがとうございます。
vagrant up
vagrant ssh
$ sudo apt update -y
$ sudo apt install -y apache2
$ sudo apachectl status を実施しました。
下記が実行結果です。
ターミナル
vagrant@vagrant-ubuntu-trusty-64:~$ sudo apachectl status
Apache Server Status for localhost (via 127.0.0.1)
Server Version: Apache/2.4.7 (Ubuntu)
Server MPM: event
Server Built: Apr 18 2018 15:36:26
Current Time: Saturday, 18-Aug-2018 14:58:42 UTC
Restart Time: Saturday, 18-Aug-2018 14:58:23 UTC
Parent Server Config. Generation: 1
Parent Server MPM Generation: 0
Server uptime: 19 seconds
Server load: 0.15 0.07 0.06
Total accesses: 0 - Total Traffic: 0 kB
CPU Usage: u0 s0 cu0 cs0
0 requests/sec - 0 B/second -
1 requests currently being processed, 49 idle workers
PID Connections Threads Async connections
total accepting busy idle writing keep-alive closing
10369 0 yes 0 25 0 0 0
10370 0 yes 1 24 0 0 0
Sum 0 1 49 0 0 0
___________W..............
................................................................
......................
Scoreboard Key:
"_" Waiting for Connection, "S" Starting up, "R" Reading Request,
"W" Sending Reply, "K" Keepalive (read), "D" DNS Lookup,
"C" Closing connection, "L" Logging, "G" Gracefully finishing,
"I" Idle cleanup of worker, "." Open slot with no current process
vagrant@vagrant-ubuntu-trusty-64:~$
以上です。
already runningが出ているかは不明ですが
Apace2 Ubuntu Default Pageへはアクセスできました。
ここから下の階層へアクセスするにはどうすればいいんでしょうか?
現在
ホーム→vagrantフォルダ→htmlフォルダ(vagrantFile,bootstrap.sh同階層)→phpフォルダ→chapter2フォルダ→phpファイル
という構造になっています。
参考書では
http://localhost:8080/php/chapter2/welcome.php
とブラウザで開くとphpファイルが開くようなのですがApace2 Ubuntu Default Pageのページからurlを追加してみてもNot Foundでした。
これはファイルの保存先が間違えているのでしょうか?
回答1件
あなたの回答
tips
プレビュー
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。
2018/08/18 11:15
退会済みユーザー
2018/08/18 11:20
2018/08/18 11:55
退会済みユーザー
2018/08/18 11:57
退会済みユーザー
2018/08/18 12:39
2018/08/18 15:21
退会済みユーザー
2018/08/18 15:23
退会済みユーザー
2018/08/18 16:04
2018/08/19 00:52
退会済みユーザー
2018/08/19 02:05
2018/08/19 04:41