I have default website with lots of virtual directory all clients access to websites by using IP_ADDRESS/virtual_directory
next I have demo site use DNS like www.demo.company.com I would like to create web site that access by domain name and want to keep default website work so I create
new website binding with
new_website : www.demo.company.com on *:80
default_website : on *:80
when I access www.demo.company.com it always go to default_website not new_website. How can I access www.demo.company.com to new_website and keep default_website runnign with IP_ADDRESS thank you
after looking for solution, IIS support hosting this situation by default
the problem is I config wrong host name
I have
sub1.domain1.com bind to 203.xx.xx.xxx but I bind it as
new_website = www.sub1.domain.com on *:80
and I still have
default_website = *:80
so when I enter website by sub1.domain.com IIS looking for sub1.domain.com and not found, then it match *:80 and go to default_website
Related
There is a website on ISS 10 on windows server 2019.
Default web site and one other.
I have not made any configuration of thoses websites and IIS. It's a crm product, all default settings.
I made a bind with https port and certificate on two websites.
On local network, when i go to https://local_net_adress, it redirect from default website to other site.
From Internet, when i go to https://public_adress, i m not redirected, it shows me default IIS webpage.
Here's my squid configuration from this website :
(squid in reverse proxy is operationnal for exchange webmail and many other apache websites.)
# ----- xxxxxx -----
cache_peer xx.xx.xx.xx parent 443 0 no-query originserver ssl sslflags=DONT_VERIFY_PEER login=PASS name=srv-xxx
acl myacl url_regex -i ^https://public_url/.*$
cache_peer_access srv-xxx allow myacl
cache_peer_access srv-xxx deny all
http_access allow myacl
never_direct allow myacl
miss_access allow myacl
Is issue on squid or IIS?
Ok It's working now.
It was on IIS bindings.
To work, i had to delete binding from default website AND DO NOT PUT hostname on binding for the other website.
Problem solved.
Currently I have a golang app that is serving at X.X.X.X:443. Suppose my domain name is example.com. I want to link example.com to X.X.X.X:443. I tried entering this into A Record but it doesn't allow me to use port. Therefore, I currently use URL Redirect Record. I tried to link CNAME Record to this URL Redirect Record but to no avail. It just keeps showing my ip address instead of example.com.
I don't mind having example.com:443.
Can I know how should I solve this problem? Is it supposed to be solved on the DNS side? Some suggest that I must host on port 80. Is it true?
According to the documentation (https://cloud.google.com/appengine/docs/standard/go/tools/local-devserver-command)
the parameter to change the host is : --admin_host=ADMIN_HOST
Definition is : "Host name to which the local development server's administration console should bind (default: localhost)."
I have a NAS at home (Windows Server 2012) which I've been using the last few months for hosting my own website. Before that, I had the Windows Essentials role server installed with the remote web access on (wich requires from IIS) but I had to turn it down because my last processor couldn't handle it.
Now I've changed it, I want to set it all up in the cleanest way, but there's no way I can make it work.
As far as I'm concerned, It´s easier to change the Apache´s ports than IIS ones so I changed them to 8079 and 8443. My new ISP provider doesn´t offer static IP so I´m using dynu as a dynamic DNS service.
I set a virtualhost with the following values:
# Listen for virtual host requests on all IP addresses
NameVirtualHost *:8079
<VirtualHost *:8079>
DocumentRoot "C:\xampp183\htdocs\mywebsite"
ServerName mywebsite.com
ServerAlias www.mywebsite.com
</VirtualHost>
The firewall and my router are configured properly (I can reach my default gateway through "dnsname.dynu.com") but when I go to the domain.com control panel and I try to set "dnsname.dynu.com" as a private server throws an error. I redirected the 80 port to 8079 at the dynu's control panel but keeps throwing the error.
I guess the next step is configuring a CNAME pointing to my serverAlias but I can't make it work and I'm not sure if this is the best way to do it.
I hope you can help me.
Thanks!
For the default Web Site in IIS I have the following binding on the default website:
I have the following binding on the site I want to access:
When I access the site in the browser with localhost/hostname, I'm pointed to C:\inetpub\wwwroot*hostname*. I have another site set up with a hostname binding that uses the same values for Port and IP Address and it points to the right place (a different folder on my C: drive). I'm running my site locally and I have the correct hostname entry in my hosts file. I don't want to create two separate virtual directories under a single website, I want the sites to be available as separate websites. What am I missing?
When you use the hostname feature in iis, you cant use localhost to access the site any more.
Instead use http://myhostname and setup myhostname to point to 127.0.0.1 in your hosts file.
If you want to access the site via localhost, that implies you need to make a virtual directory, or "application" in iis.
I want to change my hosts file to redirect a web address to my site...
normally I would just do... ping mysite.com then in the hosts file, if the IP came out as 99.99.99.99, I'd write...
99.99.99.99 siteiwanttoredirect.com
But in this case my site is on virtual shared hosting... which means the IP I get back from the ping is the same as a few other sites and if I type that IP in the address bar, www.mysite.com won't come up. Here's a bit more details: someone who asked a question about why pinging it wouldn't give the correct IP.
So what I would like to know is... if you're on virtual shared hosting, how can you specify redirects to your site in the hosts file?
Thanks,
Matt
You cannot. With the hosts file you can change the IP address, but your shared hosting provider needs the HTTP Host header to be set up correctly -- which in your case will still be siteiwanttoredirect.com and not mysite.com . Your hosting provider will therefor not know who's site to show.
What you could do is redirect to some host you control (f.i. localhost) and run a proxy server there. If you set up Apache on your machine, with a virtual host for siteiwanttoredirect.com which does a reverse proxy to mysite.com , it should work.
This is handled via the host header of the website, and not anything on your local machine, like your hosts file.
I would make sure your host has that set up, then as long as people visit your sit via the website name, and not IP, everything should work.
On a shared host, the website you get is determined by the domain name you ask for thanks to the Host HTTP header. For this to work properly the web server needs to be configured correctly so it knows what website to serve in response to which Host request - this is usually called 'Add-on Domains' on CPanel driven shared hosting.