
apache2 をインストールして実行しています。設定ファイルをいじっていたら、次のことも見つかりました:https://httpd.apache.org/docs/2.2/vhosts/examples.html
先ほど貼り付けた Web サイトには、ユーザーが Web ブラウザーでその名前を入力してサイトを見つけられるように、サイトの名前を 'apache2' の設定ファイルで定義するのはそれほど簡単ではないと書かれています。また、使用中の DNS にサイトの URL とそれに一致する IP を知らせる必要がある (そのページで提案されているように) など、私の理解しているようなことが必要です。
現在、私は LAN 上で作業しており、Linux ボックスでクライアント PC にネットワーク IP 番号を与え、自身をデフォルト ゲートウェイとして設定しています。設定するには、DNS 構成をどこで確認すればよいですかwww.mywonderfulsite.com
-> 192.168.1.1
(Linux ボックス)
あるいはそう言うこともできる。
これを読んでいる皆さんが、私が何を達成しようとしているのか理解してくれることを願っています...
答え1
を参照してくださいman dnsmasq
。そこには次のように書かれています。
trusty (8) dnsmasq.8.gz
Provided by: dnsmasq-base_2.68-1_i386 bug
NAME
dnsmasq - A lightweight DHCP and caching DNS server.
SYNOPSIS
dnsmasq [OPTION]...
DESCRIPTION
dnsmasq is a lightweight DNS, TFTP, PXE, router advertisement and DHCP
server. It is intended to provide coupled DNS and DHCP service to a
LAN.
Dnsmasq accepts DNS queries and either answers them from a small,
local, cache or forwards them to a real, recursive, DNS server. It
loads the contents of /etc/hosts so that local hostnames which do not
appear in the global DNS can be resolved and also answers DNS queries
for DHCP configured hosts. It can also act as the authoritative DNS
server for one or more domains, allowing local names to appear in the
global DNS.
だから、(それぞれのクライアントに)追加すべきだと思う。/etc/hosts
192.168.1.1 www.mywonderfulsite.com
その他のエイリアスは、別々の行192.168.1.1
ではなく同じ行に記述する必要があります。/etc/hosts
同じIP アドレスは、混乱、困惑、フラストレーション、そして机に頭を打ち付ける原因になります。