it's built on the Microsoft stack, you have many choices on how you can host your site. You can go
to a commercial hostor and just by hosting and they'll set everything up for you. And
typically you publish through FTP or something like that. That's one way more common way maybe
would be to host it yourself within your own data center. Maybe you're a large Corporation,
you run your own servers, you can host it there. Another really popular and growing trend is to
host your site in Microsoft Azure. And we'll see how to do that later. In this particular video,
we're going to talk about how do you set up your own hosting on your own servers.
So there's two steps. We're going to host our website in Is. Let's check out a few things
before we actually get there. So you can see that we can run our website. And here's a cheesy little
Wacky Web World website and you'll see that we can host it here. It seems to be running on a server,
and that's true in the development mode. So if we go down here, you can see this is Is
Express. This is fine for development, but it won't do for production hosting. It just
doesn't have all the capabilities and things you need. This Is for testing and development.
It's not a production web server. What you need is iOS. So in order to install iOS, you have to
go and add those features to Windows. Typically, they're not installed by default on Windows 81,
which I have here. You can go to turn Windows features on and off and you'll see Internet
Information Services, or Is, as we call it for short. And you want the application server
features for ASP. Net. And you probably want the web management tools, the ISS Management console,
so you can actually work with the thing. Now if you do this on Windows Server,
typically you do a slightly different way to install this. You go and add roles to your
server. So you need to add two roles. You need to add the application server and the web server for
iOS. So either way you get it installed. Once you have it up, you'll be able to run Is. So we
come over here and just type iOS for Internet Information Service Manager and open this up.
So imagine this is a remote machine we could remote desktop to or something like that. We'd
like to create a new website. This is in our own data center, right? So we can say add website
super easy. We give it a name. This is just a friendly name. It could be anything you like,
but let's pretend we're going to host our Wacky Web World site from Wackywebworld.com or something
like that. Okay. So we'll come over here and we'll say this will just be Wackywebworld.com,
something like that. Let me copy that. We'll need a few places, then we need to pick the application
pool. You can see it's going to create one. This is basically the process that your site runs in
and over here in the physical path. We can put it somewhere. I typically like to put this onto
a second drive. I wouldn't really choose the CD drive. It may be drive D. We'll call this www.
Over here and within there I'd probably create something along the name of the site. Because you
might have many sites hosted on your server, this is easy to do, as you'll see in just a second.
So what you'll do is you'll go map from your domain host people that control your domain
name. You'll go to your DNS settings and map them to the server, whatever its IP addresses.
And then the server will see the inbound request in the URL for a particular host, and it will
differentiate between different server, different websites using that. So we'll just put this here.
All right, so now we can come over here and talk to our site.
I've already mapped that domain to this local machine, so I can go to Wackywebworld.com and
it runs for a second. It says error. You can't list this directory. That's because
we haven't published our site. So if we want to publish our site, we have a couple of options.
We can come over here and right click and say publish. This is great. Or we
could just copy these files, but we'll end up with extra stuff,
the CS files and various other compilation artifacts that really don't belong there.
So what I'm going to do is I'm going to say I want to publish this website,
and for now we're just going to use a local custom one here. This will just be a local publish or
whatever you're going to call it. And this is just going to be published to the file system.
Maybe this is a network share or something in our world. I put this over here on DWWW.
Wackywebworld. So we'll just put it there, say next we want to publish release. You typically
don't want to publish the debug build. We could say clean out that area if you wish, so that if
we remove the file, it's also later removed from the server and so on. Now we can just hit publish.
You'll see down here, it's going to do a copy copied over here. Let's just try that link again,
refresh and give it a moment to wake up. Hello, Wackywebworld. Wackywebworld.com is online and our
site is published. So there's really nothing different about doing this locally or to a
network share that some server is exposing. If you're going to push this somewhere farther out,
you very well may use the different hosting option. Sorry, different publishing option here.
We might want to create a new custom profile, call whatever and pick Web deploy. But we need to set
web deploy up on the server. It's super easy to do but it's something you have to download and
install. Don't have that set up and do it locally. It's kind of silly to show you that way. In
another video when we talk about Azure I'll show you how to use web deploy to publish to Azure.
All right so that's how you set up iOS. Take your website and publish to it. You can either
just copy the files sometimes it's FTP really the best way is to use web deploy because it kind of
does the web config compilation transformations and all that kind of stuff that's you need done
and it drops it right where it needs to be. You can even tell it after it's done. Going to
open up a particular page like this one to make sure your site is working when it's published.