 Hey everybody, this is Grant your friendly neighborhood OpenShift team member in this video I'm going to show you how to install the all-new Okd version 3.10 Okd is the origin community distribution of Kubernetes and it is the upstream source code for Red Hat OpenShift container platform So with all that being said let's go ahead and get started now in this Demonstration I'm going to install everything on a single host. That's how I run OpenShift for my local development environment So I thought that a lot of people may want to just try out Okd and run it in a single host fashion But not using something like MiniShift or OC cluster up Which is by far much easier to do but this install will give you the feel of a true Okd cluster just like if you had multiple masters multiple nodes as well So I am using Fedora 28 in this video And I am just I fell in in love fallen in love with Fedora 28 It is my main operating system distribution now So I recommend you give that a try as well So we're going to be using virtual box today. So let me go ahead and get that started up here and Let me minimize my Firefox here So what we're going to do is create a new virtual machine. So I'm going to scan click on new We're going to call this tech dope. That's the domain name that we're going to be using today And this is Linux and it's a Red Hat 64 bit distribution And as you can see I have 64 gigs of RAM in my main battle station here So we're just going to give this 32 We're going to create a virtual disk And we're going to click on create here File location. Let's give this Maybe a hundred and sixty. Let's just go two hundred two hundred gigs here or roughly here Let's see. We want the VDI type Dynamically allocated. Let's save this in our special VM folder here, which is a SSD that I have mounted. So I want to make sure it goes on to that SSD I'm going to click on create. That's going to create the virtual machine Preferences and properties for me. Let's go in and just set a few other settings here mainly networking I want it to be bridged so it gets its own IP address And Under storage I want to mount a live CD for the install And I'm going to install sent us seven minimal install click ok Now we're going to boot this bad boy up and see what happens And click my mouse in there. Let's stretch the screen out a little bit so you can see it Let's see. How do we make this? Scale is it scaled mode maybe no There we go Make this bigger so you can see it. I'll close this warning right here So now sent us the install is booting up and we're just going to walk through the sent us Seven install real quick here should just take a minute Yes, we're English so click continue So now it's just validating that we have the install source and we're going to set up our Installation destination so you can see that virtual drive that I've created. We're going to use that I'm going to configure partitioning myself Click on done. I'm going to create just a standard partition and I'm going to add a Swap partition so I'll select swap and I'm just going to give it a gig Hopefully I don't ever hit the swap and then we're going to give it a root partition here And we're going to use the rest of the available space 187 gigs at that mount point click on done click on accept changes and We should be almost ready. Last thing we want to do is enable networking So click that it's going to connect to the bridge Network and we can see it has an IP address of dot one four So I'm going to click on done there click on begin installation now. This is going to go ahead and Install sent us for me. It takes just a minute here and Remember the IP address was dot one four. Okay So while this is finishing up the install. Let's actually go back to Firefox and go to my router My router is one nine two one six eight zero dot one and I'm going to log in here Now this is an ASUS router and I'm running a custom Merlin firmware It's not relevant to this video, but on most routers. You have the option of port forwarding So I must like virtual server port forwarding and Let me delete the previous ones I had here for tech dope and we're gonna call this service name tech dope and The port range is going to be eight four four three local IP addresses one on two one six eight dot zero dot 14 local port eight four four three So what I'm doing here is I'm setting it up So on my external IP address if it gets a request on port eight four four three It'll actually forward that to an internal host behind my net and networking so that it can resolve These IP addresses, so let me add another one here and this one is going to be port four four three and The last one we need to do is port 80 So you need to forward eight four four three four four three and 80 Add that one now. We're going to click apply and my router is going to apply those changes Let's scoot back over to the install. It's almost done. It's performing post installation setup tasks at this point So we'll let that finish Now after we get this installed. I'm also going to show you how I set up my DNS server To resolve tech dope dot IO to my open shift instance and Let's go ahead and set a root password. I think that's what it's waiting on me I think the install is actually finished and Let me create a quick user account here make it administrator so I can sue do done there and Still performing those post installation setup tasks So let me go ahead and show you a few other things on the DNS stuff while that's finishing So I'm going to go to if can fig if What's my IP address there is a site always use but I'm forgetting it right now off the top of my head It's a it's a good one to you. I think it's ifco or something like that But anyway, my public IP address is this so now if I go over to my Gandhi account That's what I set my records up to use my a record C name Things like that Okay, so let me log in to Gandhi here and I am going to pause the video just for a second so I can actually Look up my username and password. So I'll be right back My username is G Shipley put my password in Don't save it and Gandhi is just the domain name register that I use So let's look at our domains here and You can see I have tech dope.io, so I'm gonna click on that Then I'll select the DNS records and you can see a couple things here Remember, this is my IP address six five one nine oh one five four dot two three And so what I've done is I've set up my a record my at for Six five one nine oh one five four dot two three So it's going to point to that IP address that I get from my ISP the other thing I set up is a console a record and a app stock console a record now What's most important here is this wild card this star which is a C name that points to apps console And we need that because when we deploy applications on OpenShift It deploys it creates a new URL on the fly based on the app name and namespace And so having that wild card DNS entry there will allow all of the pods that I Deploy and expose a service for to be accessible on the internet as well So sent us Was installed so we're gonna reboot it here, and then we're gonna SSH in and start the install process All right, we're gonna boot back up to sent us here and now sent us is booted up So let's go ahead and open up a new terminal window here I'll make the font a little bigger for you so you can see and I'm just gonna SSH route at one nine two one six eight dot zero dot fourteen and I'm going to authenticate here now the first thing I always do on a new system is young Update and this is gonna download any updated Patches or packages that have been released since I downloaded that minimal install CD or actually pin that was created. So we're getting a hundred and seventy-seven Megs of updates and so this is gonna fix any security Vulnerabilities that were discovered after that latest snapshot or that latest minimal CD was created or image was created So make sure that I have a up-to-date system before I begin the install process And so I do have a gigabit internet so this the download went fast As you can see and now it's going through and updating all of the packages And it looks like I'm getting a new kernel here as well three dot ten We're halfway done now. It's cleaning up and then after this finishes. I also Like to install get right off the bat as well Just because I'm going to actually clone a repository that I'm going to use to install OpenShift on All right, that's been finished. So let's go ahead and young install get This is gonna install the get revision control system All right. So now let's go back to Firefox and Let's go ahead and go to my get hub repo get hub.com slash g ship Lee and I can solve OpenShift so often that I have actually created my own automation on top of the Ansible Playbook and so I do have Instructions here on how to do this, but I'm just gonna get clone my repo here And this is basically going to create a new directory called install sent OS and inside of this I have a shell script called install OpenShift now this has Been the work of many I think 15 different people have contributed to this So thank you to everybody who has Submitted pull requests for this. It is an interactive installer but under the covers it is just making sure that all of the Required RPM packages are installed It's automating the creation of the inventory file It lets you set variables whether you want to install metrics and things like that But under the covers what's really happening is this just running the Ansible playbook that ships as part of OpenShift. So let's go ahead and run this I'll clear my screen will do install OpenShift and it's going to ask me for the domain I want to use now. I want to use a custom domain tech dot IO But if you don't have a custom domain just use the NIP dot IO that's defaulted there You can also create your first OpenShift user here So I'm going to create one called G shively with the password of password OpenShift version. I'm going to use the okd version 3.10 and It has my IP address I'm gonna set the port and now it's going to go off and install OpenShift in automated fashion Or sorry okd in an automated fashion And at the end of this I should have an okd installation Running 3.10 which is the latest version with logging the metrics and a username created as well Now this process takes about 20 minutes. So we'll see it's about 415 right now So in the interest of time, I'm going to go ahead and pause this video And then I will pick it back up once the install finishes Alright, I think we're just about done with the install. It's 4.33 So it's been about 18 minutes so far. So we should be finishing up here anytime now if you A word of warning here. I am the only one that's ever ran across this which is why I started recording here For some reason, I don't know if it's the way I'm setting up the VM or what but sometimes this task verifying that the Master node is up Or that the controller plane is up just times out for me The first time if you run into that let me know If you did it exactly like I did and the way to fix it though It is if you do see that problem and the install airs out It's just to run the installer again And it fixes itself up and I'm not sure if it's a bug in my install script or something wonky I'm doing could be my SSD. I have no idea. It could be something on my network But like I said, I'm a lot of people use my script that I have here And I'm the only one that's ever seen that problem So let me know if you see it as well But we should be finishing up here just any second and as part of this install. I Also create 200 persistent volumes Which was a request on GitHub that we have some persistent volumes right out of the gate so you will see that That's being created as well at the very end All right, so the install was actually finished and it's creating the persistent volumes now What I was thinking about during the install, you know, this was taken a little bit longer than normally I said 20 minutes and we've been going on, you know, 27 minutes and I was thinking about that the only Difference this time that may be impacting performance that you may want to think about Because I was thinking about how I created this virtual machine And if we look at my settings the thing I forgot to do that I normally always do is assign it More processors. So in this case, I just left it the default So even though my processor has eight threads and four cores only gave it one of those So it's actually just operating on it on the single thread. So that may have impacted performance on the install just a bit Just something to think about I'll probably change this if I actually end up using this system and assign it more cores for my actual open shift install But everything is up and running now and we can see that it gave me my login command here And so let's go ahead and log in to the API the ok day API on the command line So I am definitely logged in now So I can do OC new project demo project and then I'll actually create a new project for me Now what this illustrates is that it is actually using that custom domain name that I applied So if we open up HTTPS console.techcope.io colon 8443 We should be able to log in now by default it Generates a self-signed certificate if you want to use your own security certificate Let me know in the comments and I'll create a video showing you how to install open shift with a Real SSL server. We can see here that we're looking at the brand new Okd 3.10 install. So let me go ahead and log in here and Bam there we go. Here's the service catalog and this is the brand new Okd, so let's go ahead and deploy something just to make sure that everything is up and running Let's just do a PHP app here for simplicity sake. I'm in the service catalog now. Let's add this to the What do I call it demo project we have a couple versions of php available php test Let's do github. Actually, let me get a php repo here github.com G ship lead Without a T on the end Let me go to my Repositories here simple php Clone this go over here paste that in and this is going to use the source to image project to create a Container for me on the fly So we can see that this build is running It's cloning the repo down here and we can also see that we have an error getting metrics. So why is that? That's because the metric system uses a custom or a I don't want to call it a bogus, but a Self as self signed SSL sir So I actually have to notify my browser to accept that certificate So if I click on that link once and add the exception I will no longer see that now metrics is still coming up because this install just finished So when that finish is coming up, we will be able to see metrics now and We can see that it is building my container still we can click on view full log here And it's pushing the layers the push is successful We can see that the pod is getting deployed now should be turning blue. There we go It's all up and running and here is that URL you often my tech dot IO we click that and we can see sure enough that everything is is up and running as Expected so that is how quick and easy you can install a full okd environment on a bare metal machine Or a virtual machine Using the scripts that I wrote if you want to take advantage of that or you can use the Ansible installer which again, I'm just using under the covers Now another quick thing that you may be interested in is The reason I clone this repo right if I go on to the Install sent OS I go into OpenShift Ansible. There's some examples in here With the additional Let me find it here CD rolls OpenShift And I think it's in files again examples and Three dot ten Well, if I could do it here three ten There we go. All right, and then into image streams we can see we have some image streams here Let me print that working directory for you out. It's a mouthful But it's in OpenShift Ansible's rolls OpenShift example files examples three ten image streams And if you wanted to add some additional image streams or templates you can do that here So you can do OC create dash f image streams sent us and you can see that it created dot net HTTBD Jenkins, Mongo, MySQL, Node.js and Wildfly We could go into XPass streams if you wanted to create some of those let's say maybe we want Tomcat or whatever the case may be you can install those as well with the OC create command So I hope you enjoyed this video. I hope you get okd up and running on your own local machine Whether that's bare metal or whether that's a virtual machine. Thanks a lot for watching