[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 433
  • Last Modified:

expose local webservice for testing

All is there a way to expose a web service I've created using VisualStudio.NET that runs locally on my PC to be consumed by CRM in the Cloud.  This is just for testing purposes.  Ultimately, I would make the web service available on a server using IIS, but for now, I'd like to expose my webserver that I run locally on my home PC to be able to be consumed by a cloud based CRM for testing and debugging.

Also, for training purposes what are some good web services that are exposed that I can use for training?  Google, Amazon, etc.?

Thanks for any help.
0
-Dman100-
Asked:
-Dman100-
  • 6
  • 5
1 Solution
 
Brandon LyonSenior Frontend DeveloperCommented:
There are really only two things you will need to do.

1. Find your external IP address
2. Make sure your router and/or firewall knows its acceptable for outside people to get inside your network and that it directs the correct port to the correct internal IP.

Admittedly step two can be quite difficult (or possibly easy) and the steps to do it depend entirely on how your local network is setup (what kind of router and/or firewall you have, how they are setup, what your OS is, what ports your server is running on, what server software you are running, etc).

If you want to deal with domain names things are going to get more complicated, which is why I suggested finding your external IP address. That way you can send them to your IP address for testing.

As long as your server is only temporary you shouldn't need to worry too much about step 3, securing your server.
0
 
-Dman100-Author Commented:
Hi Brandon, thanks for replying to my post!

I have a dynamic IP that gets assigned by my Internet provider, but I can hit one of the sites like whatismyip.com to get my current external IP address.  

My OS is Windows 7 Ultimate (professional edition).  I'm using a 4 port linksys wireless and Ethernet router.  Where do I expose my IP in the router settings?  I figure that is going to be the hard part?  I'm not much of a network guy and sure about what needs to be configured in the router settings.

Once I have that setup, how can I test that my web service is properly exposed over the internet for consumption?

Thanks for your help!
Regards.
0
 
Brandon LyonSenior Frontend DeveloperCommented:
To summarize, you have to tell your router to forward it's port 80 (where websites usually live) to the internal IP address of the computer the web server lives on.

I have no idea how up to date this link is, but I found this support site article from linksys. The difference would be that instead of FTP on 20 to 21 it would be web on port 80. http://kb.linksys.com/Linksys/ukp.aspx?pid=80&vw=1&articleid=3699 or perhaps this video https://www.youtube.com/watch?v=X5fUauwOuNo
0
Cyber Threats to Small Businesses (Part 1)

This past May, Webroot surveyed more than 600 IT decision-makers at medium-sized companies to see how these small businesses perceived new threats facing their organizations.  Read what Webroot CISO, Gary Hayslip, has to say about the survey in part 1 of this 2-part blog series.

 
-Dman100-Author Commented:
Hi Brandon, sorry for delay in responding.  I've been testing and trying to get my localhost publically accessible.

So, here is what I've done and hopefully you can help me figure out what I'm missing.  

First, I have IIS setup on my Windows 7 Ultimate (Professional version) PC.  Right now, I created one site on IIS and the DefaultSite that opens the iisstart.htm page.  I modified the hosts file so I can run multiple sites at once on the same port (80) using host names.  In my hosts file I added the line: 127.0.0.1    personalwebsite.  In the IIS manager, I edited the bindings and added "personalwebsite" as the host name, port 80 and * as the IP address.  When I open a browser and type in http://localhost it will open the iisstart.htm page.  If I type in http://personalwebsite it will open my personal website that I build in VisualStudio.  All good so far.  

On my local PC the IP is 192.168.1.101 and the router IP is 192.168.1.1.  I went into the router settings under Applications & Gaming  >> Port Range Forward and entered the following:

HTTP as the Application
80 as the start PORT
80 as the end PORT
Both for the protocol
192.168.1.101 as the IP address
and selected Enable

I went to my laptop, which is connected wirelessly to my network via my Linksys router.  I opened a command console and typed in: ping 192.168.1.101 and got a successful reply.  It hits my local PC fine.

If I type in the browser window: http://localhost/ or http://personalwebsite I get page unavailable.  

What am I missing?  I'm sure this is just user error on my part.  Right now, I'm just trying to access my personal website on my laptop on my local network and then see if I can hit it over the internet.  Then I can try and setup my webservice for testing.  

Again, this is just for testing purposes only.

Thanks for your help!
Regards.
0
 
Brandon LyonSenior Frontend DeveloperCommented:
Localhost and personalwebsite are names which are only available from the server computer and will never be available anywhere else, so the laptop wouldn't be able to access it there.

192.168.1.101 is an IP address which only exists within your local network and not to the outside world. The laptop would be able to access it, but someone who isn't using your router would not.

You will need to find what your server's IP address is according to the outside world. If you (on the server computer) go to a browser and google for "what is my ip" you will be able to find the external IP address, which is the URL you would give someone from outside your network in order to access that server.
0
 
-Dman100-Author Commented:
okay, so I'd put in the outside server IP for the port forwarding IP address?  

what would be the URL I'd type in to access the sites I have running locally on IIS?
0
 
Brandon LyonSenior Frontend DeveloperCommented:
No the forwarding address for the router would be telling it to forward requests from the outside world to an internal IP, which would be the 192.168.1.101. The IP you would type in to access the sites you have running would be whatever the other outside IP address is.
0
 
-Dman100-Author Commented:
If my outside IP address is: 207.119.23.150 and my site name is "personalwebsite" would the url be:

http://207.119.23.150/personalwebsite   ???

I cannot seem to hit the site no matter what I try?
0
 
Brandon LyonSenior Frontend DeveloperCommented:
The following statement assumes you're using server defaults developed in IIS using a standard folder structure. Otherwise, your server settings and folder structure can determine the URL.

The default URL maps to your root wwwroot folder. The contents of that folder would be the URL http://207.119.23.150/. The URL for c:\inetpub\wwwroot\websitename\childfolder\ would be http://207.119.23.150/websitename/childfolder/
0
 
-Dman100-Author Commented:
When I try and hit the site, I'm getting the error "connection has timed out".  The server at <MY EXTERNAL IP ADDRESS> is taking too long to respond.

Would that be related to a router setting or something outside of my control from my ISP?
0
 
Brandon LyonSenior Frontend DeveloperCommented:
It could be your ISP but it sounds to me like it might be a server configuration issue. Unfortunately I am not too familiar with how IIS servers work since I tend to use Apache.

Since this question isn't as much about web development as it is about server configuration or networking, you may want to request attention or edit this question in order to move it into a more appropriate topic area, such as http://www.experts-exchange.com/Software/Server_Software/Web_Servers/Microsoft_IIS/ or http://www.experts-exchange.com/Networking/Windows_Networking/.
0

Featured Post

Automating Your MSP Business

The road to profitability.
Delivering superior services is key to ensuring customer satisfaction and the consequent long-term relationships that enable MSPs to lock in predictable, recurring revenue. What's the best way to deliver superior service? One word: automation.

  • 6
  • 5
Tackle projects and never again get stuck behind a technical roadblock.
Join Now