環境:AWS EC2 amazonlinux2
composer install
を終えてApacheにプロジェクトのパスを通す作業を行おうとしています。
sudo vi /etc/httpd/conf/httpd.conf
を入力して変更するとされるDocumentRoot
(
DocumentRoot "/var/www/<プロジェクトディレクトリ>/public"
)
を探しているのですが見つかりません。
表示されるものは以下の通りです。
# This is the main Apache HTTP server configuration file. It contains the # configuration directives that give the server its instructions. # See <URL:http://httpd.apache.org/docs/2.4/> for detailed information. # In particular, see # <URL:http://httpd.apache.org/docs/2.4/mod/directives.html> # for a discussion of each configuration directive. # # Do NOT simply read the instructions in here without understanding # what they do. They're here only as hints or reminders. If you are unsure # consult the online docs. You have been warned. # # Configuration and logfile names: If the filenames you specify for many # of the server's control files begin with "/" (or "drive:/" for Win32), the # server will use that explicit path. If the filenames do *not* begin # with "/", the value of ServerRoot is prepended -- so 'log/access_log' # with ServerRoot set to '/www' will be interpreted by the # server as '/www/log/access_log', where as '/log/access_log' will be # interpreted as '/log/access_log'. # # ServerRoot: The top of the directory tree under which the server's # configuration, error, and log files are kept. # # Do not add a slash at the end of the directory path. If you point # ServerRoot at a non-local disk, be sure to specify a local disk on the # Mutex directive, if file-based mutexes are used. If you wish to share the # same ServerRoot for multiple httpd daemons, you will need to change at # least PidFile. # ServerRoot "/etc/httpd"
やったこと
・http://httpd.apache.org/docs/2.4/mod/directives.htmlをチェックしましたが膨大過ぎて何を読めばいいか分かりませんでした。
・そもそもDocumentRootの変更が反映されないなどのエラーが多くて検索にヒットしませんでした(力不足です、すみません)
回答1件
あなたの回答
tips
プレビュー