AWS EC2 instance showing IIS Page on Public IP even though localhost shows WAMP - wordpress

I created a Windows 2016 Base EC2 Instance and installed IIS on it. But soon realized that I have to run WAMP to host PHP sites so I installed WAMP and stopped IIS service and everything was working fine.
Then I made a few changes to the site (It's a Wordpress site) and published it and since then the public IP is showing IIS page.
I have tried renamed iisstart.html to iisstart (to trick system into
thinking the file doesn't exist) from IIS folder but the public IP
is still showing IIS page.
I have tried restarting the instance machine. Localhost is showing my wordpress site but public/elastic IP shows IIS.
I have tried restarting WAMP, no luck.
I don't know how is it possible that IIS page is shown even when the file is renamed.
I have tried creating an Elastic IP as well but didn't worked.

Ok! So the issue is fixed! Now posting solution for anyone who will reach here (maybe my future self)
There was no issue with AWS EC2 or WAMP. The issue was in importing Wordpress.
When I imported Wordpress the Site Address and Wordpress Address changed to localhost. Due to which the IP was redirecting to localhost of destination machine.
Solution:
After you import your Wordpress, goto wp-admin -> Settings (in Side Bar)
And change the Site Address and Wordpress Address to the public/elastic IP of your instance.
Then clear Cache/Cookie on your destination machine and revisit the IP. It should work. (It did in my case)

Related

Wordpress website can be acces outside LAN, but no internally UBUNTU SERVER

So I have a problem and I do not really think it has anything to do with the apache2 settings.
I have installed a wordpress website on my local server computer.
Now, I can acces phpmyadmin and anything BUT the wordpress websites.
This ofcourse makes me think its WORDPRESS and not the webservers fault.
Permalinks in wordpress are set to www.mydomain.com
Im trying to load the website from: 192.168... Localhost and my external IP. but it just sits there loading.
And when I try to acces the website from my phone/outside the local networks, the website works completely fine!
I have been working on the website for a while now and I can't really do a re-install.
Anyone know what could cause this problem?

IIS Wordpress Not accepting connections from internet

I recently setup a wordpress website on IIS.
I configured the website and it is working on the local machine. I can browse pages and get to the wordpress admin.
I also configured IIS with the correct site binding, host name and ip address.
However from the internet I can not reach the website. It's as if the wordpress site is not listening to or IIS is not passing along traffic from the internet. And just to make sure it wasn't an issue with IIS. I setup a second website on that server that is accessible from the web. That one is working.
Any anyone has any ideas I'd appreciate it.
After doing some testing.
In this case. The wordpress site would not respond or map to the correct domain name on the main ip address of the server.
After adding a second IP address on the nic card and mapping that in IIS the website worked properly.
It was a very strange situation. It should of just worked on the main IP. But it didn't. shrug.

Acessing WordPress locally on different network

I've been having trouble accessing my local wordpress project on different network. The site just keeps loading, and I can't even access the admin panel. I inspected the net panel. It's showing this IP instead of 'localhost' or my real local IP. Since I'm new to wordpress I would like to hear some solutions to this problem.
EDIT: The problem was in the Database. That IP was stored in options table.
I used interconnectit to change the '192.168.0.12' to 'localhost' and I can confirm that it works now.
To run wordpress on your local pc you should have a server installed, for example wamp server.
If this step is fine, make sure that you are masking correctly localhost with this ip at hosts file (C:\Windows\System32\drivers\etc).
Finally, if you are moving wordpress from another location, make sure that all db records (especially on wp_options table) have the url changed.
For sharing project hosted localhost over network, you can use Ngrok

Being redirected to 127.0.0.1 from Wordpress/Apache installation with AMPPS

I have installed AMPPS (Apache + MysQL) with Wordpress on a Windows 10 computer to quickly setup a website. The website is working fine locally.
Now, the problem that I have occurs when I try to access the website from another computer.
When I enter the server IP ( http://219.223.239.3/ ) on another computer, a main webpage show with the main directories:
This indicates that the other computer can connect to the server.
However, when I try to access the WordPress subdirectory on the server ( http://219.223.239.3/wp/ ), it redirects to http://127.0.0.1/wp/ and the webpage does not show. Hence, it seems that there is some configuration problem with WordPress or Apache.
To try to solve the problem, in Wordpress, I went to Settings>General, and I have set the "Wordpress Address" and "Site Addresss" to http://219.223.239.3/. Moreover, I have edited the Apache configuration file to change "ServerName" to 219.223.239.3:80. But it still does not work.
Otherwise, all the settings should be the default settings of AMPPS.
I am not very familiar with Apache.
Does anyone knows how to solve this issue?
Check the wp-config.php file in the root of your wp folder. I had the exact same problem and it turned out the credentials for establishing a connection to the MySQL database I had running locally were incorrect.
In the Ampps management console (typically located at localhost/ampps/ in your brower), open up PHPMyAdmin and check the user credentials for the database connection.

Drupal Multisite, MAMP and SVN Best Practices?

I successfully set-up Drupal Multisites with:
site1.domain.com
site2.domain.com
site3.domain.com
using Virtualhosts and editing the etc/hosts with MAMP on my localhost. I then deployed it using SVN (it deploys automatically) on the live site.
The Problem: when I type "Site1.domain.com" because it goes to my localhost instead of my live site. Is there anyway to avoid this? (apart from renaming the subdomain, because it speeds up deployment)
Just check your virtual host settings in httpd.conf file, are you using IP address to redirect them?
And if its directing to your localhost, just check your host file, if might be redirecting because of that

Resources