0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

ubuntu 24.04 LTSで自宅サーバー構築(Apache2の設定)

Last updated at Posted at 2024-08-10

初期費用無料、月額990円から、高速・多機能・高安定レンタルサーバー『エックスサーバー』

taisuke@ubuntuserver:~$ sudo apt -y install apache2
taisuke@ubuntuserver:~$ sudo vi /etc/apache2/conf-enabled/security.conf
#12行目 : 変更
ServerTokens Prod
taisuke@ubuntuserver:~$ sudo vi /etc/apache2/mods-enabled/dir.conf
DirectoryIndex index.html index.htm
taisuke@ubuntuserver:~$ sudo vi /etc/apache2/apache2.conf
#70行目 : サーバー名追記
ServerName ご自身の自宅サーバーのドメイン名
taisuke@ubuntuserver:~$ sudo vi /etc/apache2/sites-enabled/000-default.conf
#11行目 : 管理者のメールアドレスを変更
ServerAdmin メールアドレス
taisuke@ubuntuserver:~$ sudo systemctl restart apache2
ローカルホスト または任意のクライアントコンピューターから Web ブラウザーで [http://(サーバーのホスト名 または IP アドレス)/] にアクセスします。 以下のようなページが表示されれば OK です。
apache.jpg
初期費用無料、月額990円から、高速・多機能・高安定レンタルサーバー『エックスサーバー』

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?