I'm on an EC2 instance and have a domain
domain.com linked to the EC2 nameservers and it happily is serving my pages if I type
domain.com in the URL.
However when the page is served it resolves the url to:
Using apache I've set up the following VirtualHost, following examples provided at http://httpd.apache.org/docs/2.0/dns-caveats.html
Listen 80 NameVirtualHost 18.104.22.168:80 <VirtualHost 22.214.171.124:80> DocumentRoot /var/www/html/directory ServerName domain.com # Other directives here ... <FilesMatch "\.(ico|pdf|flv|jpg|jpeg|png|gif|js|css|swf)$"> Header set Cache-Control "max-age=290304000, public" </FilesMatch> </VirtualHost>
However I'm not getting any changes to how the URL is displayed.
This is the only VirtualHost configured on this site and I've confirmed its the one being used as I've managed to break it a number of times whilst experimenting with the configuration.
The route53 entries I have are:
domain.com A 126.96.36.199 domain.com NS ns-11.awsdns-11.com ns-111.awsdns-11.net ns-1111.awsdns-11.org ns-1111.awsdns-11.co.uk domain.com SOA ns-11.awsdns-11.com. awsdns-hostmaster.amazon.com. 1 1100 100 1101100 11100