AR ホームベーカリー

オイラのアウトプット用ホームベーカリー!

homebrew でインストールした httpd の使いかた

Docker 化できないフレームワークを使うハメになっているので、久しぶりにシステムワイドで色々入れている。

インストール

❯ brew install httpd

プロセス操作

起動
❯ brew services start httpd
停止
❯ brew services stop httpd
ステータス確認
❯ brew services info httpd

ドキュメントルート

  • /opt/homebrew/var/www

デフォルトポート

コンフィグファイル

The default ports have been set in /opt/homebrew/etc/httpd/httpd.conf to 8080 and in /opt/homebrew/etc/httpd/extra/httpd-ssl.conf to 8443 so that httpd can run without sudo.

❯ gls /opt/homebrew/etc/httpd/
total 100K
drwxr-xr-x  7 donbulinux admin 224 11 23  2022 .
drwxrwxr-x 25 donbulinux admin 800  9 22 19:10 ..
drwxr-xr-x 15 donbulinux admin 480  2  3  2023 extra
-rw-r--r--  1 donbulinux admin 21K 10  2 18:38 httpd.conf
-rw-r--r--  1 donbulinux admin 13K 10  2 18:38 magic
-rw-r--r--  1 donbulinux admin 60K 10  2 18:38 mime.types
drwxr-xr-x  4 donbulinux admin 128 11 23  2022 original
http
  • /opt/homebrew/etc/httpd/httpd.conf
https
  • /opt/homebrew/etc/httpd/extra/httpd-ssl.conf