Is it possible to make my WAMP server connectable outside of my LAN? - wamp

Is it possible to make my WAMP server connectable outside of my LAN? Is it possible to host my own website for free and make it connectable from anywhere?

Yes it is possible.
You should point a domain to your external ip - find that entering google myip - example https://www.whatismyip-address.com/?check
On your DNS manager point your domain to your ip
On your router - if you have access you can forward all traffic on port 80 and 443 to your internal computer - which you can find using ipconfig /all (windows) or ifconfig (unix/osx) commands in CMD (windows) or Terminal (osx)
This works if you have a static ip (your isp will not change your ip)
If you can't change the port forwarding on the router from your isp you shoul ask them to put in bridge mode and you buy another router which will make all the dhcp and routing services.
Or you can use your router dns dynamic tools like no-ip.com or something similar to tell your changed address
and you will point your cname record to some domain like mydomain.no-ip.com
Or you can use https://ngrok.com/ which will expose your website on their domain

I solved the problem by disabling the firewall for port 80.
Go to Search on right side of windows.
search "firewall".
open the "firewall with advanced".
go to inbound rules.
click on "new rule".
select the "Port" option.
click "next"
select "TCP" option.
select "Specific local ports:".
type "80" in next text box
click next.
select the "Allow the connection".
click "next".
click "next".
give the name "Port 80 Allow Rule".
click "next".

Related

How to enable access to a web service hosted on GCP VM instance

I built a web app, that runs and listens on port 5000 using .netcore (default app in VS).
I created a VM instance on GCP, and allowed http and https traffic in the configuration.
I ran the app, and used the exteral ip(which I succeeded to ping) to access it from the browser:
http://:5000
But I got no response, this should have opened the site.
I added a firewall rule to allow traffic but still didn't help:
I'm sure many people encountered this, any help?
I have the same opinion as #Iñigo, it could be the firewall.
You can create the rule with the following command:
gcloud compute --project=my-project firewall-rules create rule-for-netcore --direction=INGRESS --priority=1000 --network=default --action=ALLOW --rules=tcp:5000 --source-ranges=0.0.0.0/0
The output should be something like:
Creating firewall...⠹Created [https://www.googleapis.com/compute/v1/projects/my-project...l/firewalls/rule-for-netcore].
Creating firewall...done.
NAME NETWORK DIRECTION PRIORITY ALLOW DENY DISABLED
rule-for-netcore default INGRESS 1000 tcp:5000 False
Edit 1
Also you need to open the port in your windows firewall:
From the Start menu, click Control Panel, click System and Security, and then click Windows Firewall. Control Panel is not configured for 'Category' view, you only need to select Windows Firewall.
Click Advanced Settings.
Click Inbound Rules.
Click New Rule in the Actions window.
Click Rule Type of Port.
Click Next.
On the Protocol and Ports page click TCP.
Select Specific Local Ports and type a value something like 5000-5010 (this is only an example you need to add the ports needed)
Click Next.
On the Action page click Allow the connection.
Click Next.
On the Profile page click the appropriate options for your environment.
Click Next.
On the Name page enter a name of like “Open port for test”
Click Finish.
Restart the Instance.
At the end you would see the rule like this:
You can consult the following link for more information.
The firewall is dropping your traffic.
You should open port 5000, not http(port 80) or https(port 443).

Can't open HTTPS 443 Port on Amazon Lightsail VPS - Ubuntu 16.04 Base OS

This is a fresh VPS instance created on Amazon's Lightsail. By default the SSH 22 and HTTP 80 ports are open and I'd like to add the HTTPS 443 port. In the past this hasn't been a problem.
Now, when I go to the "Networking" tab and click on "Edit" or "Add another" and select "HTTPS", it adds port 443, but I'm unable to click the "Save" button. It's basically an unclickable button. It just does nothing. If I click "edit" and then "save" it works fine but that's only before I add the HTTPS port. Is there something I'm missing?
In the past I was able to open this port before on Ubuntu 16.04 installations.
Solution: It seems the port screen is rather broken. Enter "Custom" and type in the port number manually. In this case 443 and it'll switch to HTTPS automatically.

How can I connect to my ubuntu server via http?

I have started using AWS t2.micro virtual machine. I installed apache2 and curl on it. If I type curl localhost on the ubuntu machine, it gives me the correct page. How do I now connect to the ubuntu machine with http from windows and fetch the same page?
Modify the security group of that instance(virtual machine) adding to inbound rules: port 80, Protocol tcp and source (IP to accept connection from) either the static IP address of the windows computer or 0.0.0.0/0 (any IP address).
I have fixed the issue by doing this in AWS:
Open EC 2 Dashboard
Open Instances
Click the instance I want to connect to
Scroll down to description and look at "Security Groups"
Look at the name of security group, mine was "launch-wizard 3"
On the sidebar, go to Network & Security > Security Groups
Find security group name (for me it was launch-wizard3), click on it and look down below where it says inbound, click on it.
Click edit
add rule
Type: HTTP, Source: anywhere
Save
Connect to your public ip and it should work.

Access localhost on Google Cloud instance using External IP

There are many similar questions to this on SO, but none of the solutions I saw really solved my issue completely. I'm doing test runs for a website framework hosted on the Google Cloud Platform.
By default, the website is hosted on http://localhost:2800 And I know the external IP of the instance I'm running it on. How can I access the hosted website through a browser on my local machine? Do I use virtual hosts / port forwarding etc.?
go to your VPC firewall
https://console.cloud.google.com/networking/firewalls
and create a firewall rule to allow traffic on your desired tcp port
Create a Firewall Rule for SQL Server
Configure a firewall rule to allow traffic on port 1433 so other clients can connect to the newly created SQL Server instance over the public internet:
In the Developers Console main menu, go to the Firewall rules section.
OPEN THE FIREWALL RULES
Click the Add firewall rule button.
Name the new firewall rule allow-tcp-1433.
Set Source Filter to IP Ranges.
For Source IP Ranges enter 0.0.0.0/0. This value allows access by all IP addresses.
Warning: This configuration leaves your SQL Server instance open to traffic from everyone, everywhere. It is used only for demonstration purposes. In production environments, restrict access to only those IP addresses that need access.
For Allowed protocols and ports enter tcp:1433.
Click the Create button to create the firewall rule.
Set firewall rules for you google cloud project with following properties:
Target: all instances
Direction: ingress
Source IP ranges: 0.0.0.0/0
Ports and protocols: allow all
Then Depending on your framework, set allowed_host to externalIP or "*" .
For example - In Django, in settings.py set ALLOWED_HOSTS = ["*"]
Now run server on specific 0.0.0.0:[your_port]
For example in django - Python manage.py runserver 0.0.0.0:8000
After this note down you instance external IP address and then in your browser :- goto
[external-IP:[your_port]]
you have to go VPC network, then add firewall to allow your port. then don't forget to select [All intances in the network] (see pic). because, by default its value is [Spesified by tags].
and you can access that instance to its External IP
Try your [externalip]:[port] This worked for me in Amazom ec2.
example: 31.181.171.141:2800

How to view website launched in Amazon EC2 instance?

I have followed the steps provided by Amazon EC2. I have installed a wordpress website in the EC2 Instance.
My public DNS is given as ec2-xx-xxx-xx-xxx.us-west-2.compute.amazonaws.com/
and Public IP is also given as xx-xxx-xx-xxx.
How to view the website from any other machine?
Note:
EC2 Instance is created and running now.
I can view it in the localhost as well as public DNS in the EC2 instance using RDP. (http://ec2-xx-xxx-xx-xxx.us-west-2.compute.amazonaws.com/)
If you can see the web site from the EC2 instance, but not from other machines, there is probably one of the following things wrong:
The DNS entry is not available or is wrong. Since you can RDP using that entry, this can't be the cause.
Access to the correct port is being blocked by the security group or firewall. Since the instructions you referenced specifically say to make sure that both port 80 (HTTP) and 3389 (RDP) are open, and you know that is true from port 3389, this isn't likely, but is possible. Make sure that there are security group rules for both port numbers that look the same.
The Windows server itself is refusing to allow outside access to port 80 on that address. This is unlikely, but not impossible, and the instructions specify that you should "disable Internet Explorer Enhanced Security Configuration", and at the end cover "Making Your WordPress Site Public". Make sure that the web server isn't configured to only respond to requests from localhost (127.0.0.1) and that there are no Windows firewall rules blocking port 80.
I think that the likeliest problem is number 2, above. Perhaps you forgot to open port 80 in the security group, or typed a different port number or a different address range to open it to.