Google Professional Cloud Developer – Developing on Google Cloud Platform
3. Devops on GCP Part 2
Let’s talk about Cloud Endpoints. Now, Cloud Endpoints is an area on the exam that should be pretty straightforward for most folks that do have a development background, and any architect that has design services from top to bottom or from end to end, however you want to look at it. But with that said, Cloud Endpoints, the main thing to get out of this part of the module is to make sure that you understand that it’s essentially an API gateway. It’s also important to know, too, that it uses an ingenx. It’s a genuine based proxy that is. And the goal is to help enable you to create a web back end. You’re going to use this for your web and mobile clients, and it has an assortment of tools and libraries, and you could deploy this with App Engine as well. Now, when we look at Cloud Endpoints, there’s a few things that I just want to point out as well. The goal of Cloud Endpoints should enable your customer to reduce their development cycle.
And it allows your customer to use, for example, specific Google Cloud services such as App Engine, Cloud Datastore, Cloud Pub, Sub, et cetera, and create basically a mobile application as efficiently as possible. When it comes to cloud DevOps tools. I’m going to recommend you go over to this Google page here and it goes through a good amount of the tools that we’ve already talked about in the course, and we’ll be talking about for that matter as well, depending on where you’re at in the course and if you jump the route or not. But the reality is that you want to focus on tools that enable developers to use Google Cloud as effectively and efficiently as possible.
And this is going to include Stackdriver APIs, also Cloud Endpoints, Deployment Manager, Cloud Marketplace, a lot of other tool sets that could be used for developers to make their life easier. So go over to this page here just to make sure that you understand what is available and how they all come together, because the case study questions is really going to challenge you on how everything should come together according to Google. And that’s really the goal. Okay, let’s go ahead and do a couple of test tips here. I’ve got, I think, two pages of test tips for this module. You want to make sure that you understand the tools and services with GCP to create a CI pipeline. In other words, you want to make sure that you have a GitHub. You use Cloud Build, you send it over to development and then over to production. Just one example. It could be as simple or complex as possible. You could also use third party solutions as well, like Jenkins, if you so choose a lot of other things out there. A lot of customers may not want to use Google solutions.
They might want to use Chef or Puppet or whatever, who knows? But in a nutshell. You just want to know how to put one together. Specifically, though, with Google Cloud Services, you want to know as well how to deploy isolated application environments. For example, when you’re creating development, production, test QA, do you want to have each of the, let’s say, departments, let’s say they’re an organization in your company, whatever you may want to call development, production, test QA, they may be under the same umbrella, I don’t know. But with that said, you just want to make sure that you create a project for each and that they have the right permissions. For example, the developers have access to development, the production engineers only have access to production, and then you determine how you need to develop that strategy to put together staging and production. For example, another area that was tested was blue green deployment models.
Again, go to that link I provided you. It’ll talk all about AB testing blue green, couple of terms that you’ll likely have heard of, but the reality is that you could use, for example, app engine and split your traffic if you so choose. To validate how things work. You could also use Kubernetes as well. Another thing is you could use, for example, an App engine security scanner, and that will help enable you to reduce errors. For example, in a CI pipeline. I have a couple of whiteboards coming up on some of this to help bring it all together. Let’s go ahead and move on.
4. Cloud Source Repositories Demo
Now in this demo, I’d like to walk you through what Cloud Source repositories is and how you can connect, for example, your GitHub to the Google Cloud source repositories. So what we’d like to do is go to the console and then go to down to where it says tools. Let’s go down to where it says Source repositories. Now this is going to bring us over to a separate page. You can see that it goes out of the console. Before you get started, I’d advise you to read the documentation. Basically this is going to be a GitHub on Google Cloud is what it is. It’s going to allow you as a developer to develop and maintain your source code locally in Google Cloud. You can connect up still to your GitHub or your bit bucket, whatever you’re using and support at the time. I do know that down the road that they’ll add more capability. There’s still a lot of functions that are still sort of what I would call in beta or alpha mode. But let’s go ahead and get started here and I’m going to go ahead and create a repository. Now we have two options. I could create a new repository or I could connect to an external repository either or if we go to new, it’s going to ask us to call this whatever we want and then we go through and create. What I like to do is in this exercise actually connect to my GitHub and just show you how that works.
So let’s go ahead and go. Continue. Well, I want to select the project that I want to tie in this external repository to. Going to go ahead and select the one that I was working in. I could also create a new project as well that would probably be recommended because if you create a project that’s going to provide essentially some pretty decent what do we call, protections, in the sense that if you don’t need to. Try not to keep this in the same project with your production and other QA apps or whatever you may be doing. Try to keep this in a separate project for segmentation purposes. Remember that projects are not only a way to maintain separate billing or not just separate billing, but what I’m trying to get at is that it’s a manner for you to be able to protect not only your resources, but also your billing and management of your billing. So a lot of great benefits there. All right. And then what I want to do is select the provider. I’m going to go ahead and use GitHub.
Now what’s going to happen here is I’ve got a consent to allow Cloud Source repositories to connect to GitHub. Now it basically gives you some best practices, some information here as well. It’s going to use open authentication. It’s going to go ahead and connect to GitHub and it says go ahead and add my username password. So I’m going to go ahead and add my info and sign in and it helps type the right password. Now, as you can see, I have my information here and it’s basically saying it found my account found repositories as well, my organization. So I’m going to go ahead and authorize this. You can see it’s using Open off at the corner. Now you can see that it brings up my repository here. And let me see. Let’s go ahead and pick one of these with some chain code in there. So I’m going to go ahead and select that and then let me maximize my screen here a little bit because it’s a little bit hard to see down the bottom here. Give me 1 second to adjust. Okay. Now you should be able to see this. Now again, I have a limited screen space for best resolution. So let’s see. So I’m going to go ahead and just select let’s see, let’s select one of the Marbles ones. Okay, so Marbles is essentially a hyperledger fabric demo application that I could just use. I’m going to go ahead and connect.
As you can see, it’s fairly simple to do this and it’s going to take a little bit of time. It’s warning us as you would expect. So what it’s going to do now is it’s essentially going to connect and it’s sort of similar to what you would do with GitHub is you’d fork over your GitHub back over to your GitHub repository and this is essentially what it’s doing. It’s going ahead and forking over that specific repository that I selected. So we’ll come back to this when it’s done and check it out. Okay, so my Cloud Source repositories basically the repository that I cloned from my GitHub, the Marbles app is right here. It did copy over. It took approximately 25 minutes to copy this all over. It’s probably about 80 to 100 meg from what I remember. So it’s fairly good size. So it definitely took a little time. And I go over here, look at a source code and you see that’s in Go.
So pretty cool. I’m able to bring over repository, could also search it as well. And then if I want, I can also open this up in Cloud Shell and you’ll see that when it opens up, I’ll be able to edit this in Cloud Shell. You can see there’s cloning this and bringing it all up. It’s unpacking it. With that said, this is going to take a little bit of time. So you can see that it has my source code there. My Python Doc samples app engine is copied over as well Nodes. So that again, it’s pretty cool. So I’m able to do a lot with this automatically essentially. And you can see that it brings over samples as well.
Okay, so I’ll go ahead and leave that. So I have my Cloud Source repository copied over and this enables me now to tie in other services, which is actually really cool because now I could go use cloud build and then deploy from here if I want. With that said, that’s about all that I had with this. You can see that I have my source code over here, chain code that is for block chain application. And then actually a couple of things to point out too. You can see there that I have different branches.
If I click there, you can see that the branches for this was basically deprecated, essentially. And it keeps track of all this automatically for you, just like you would expect on GitHub. And if I want, I can go back to GitHub and it brings me over GIB to that application that I just copied over. With that said, let’s move on. Hopefully this is useful to your pipeline. With that said, you can go ahead and play around with this as well.
5. Cloud Build Demo
Let’s talk about cloud build. Now Cloud Build is an application that Google Cloud has come out with to really enable developers to build tests and deploy applications in the cloud, specifically Google Cloud. Now what we want to do is go down here and go over to Tools, which is right here, and then select Cloud Build. Now you can see under build history I have two builds, one failed, one was successful. When I go over here you can see that it tells me the build ID, tells me any relevant information, the build steps that it went through. It looks like this was a python app flask pip. There it is. And again you go ahead and sort through that. Now I can also create a trigger and a trigger is sort of a cool thing because that’s going to let us basically create essentially like what’s called a web hook in the web world, it’s just a trigger that’s going to kick off when a requirement is met. For example, if you have development groups updating the repositories and there’s any changes that are sent out, it’ll set a trigger based on that GitHub or repository that you select.
So that’s really cool. So if it matches what you set, it’ll go ahead and kick off and automatically apply those changes to the image. So again, fairly straightforward. So let’s create a trigger. Now this I believe is still in alpha mode or beta mode. Yeah, it’s in beta mode. So generally my experience with beta mode solutions is that they’re usually pretty good, but you may see some inconsistencies, especially with some of the features. Sometimes are there, sometimes they’re not, but in general they work pretty well. Usually it seems like with Google Cloud that these additional services that are in beta mode or features as well could be in beta mode for six to seven months sometimes. So don’t take it as like it’s unstable to use, it’s just that the level support that’s provided versus a production ready app is a little different anyway. So I think this is actually worth looking at.
So let’s go ahead and create a trigger. What we want to do is we have a couple choices. I could have it basically look at source repositories, my bit bucket or a GitHub. I’m going to go ahead and select repository, going to go continue. Now it actually found my repository that I had copied over from GitHub. I’m going to go continue. What it’s going to do now is going to allow me to set basically a trigger based on the variables that I want to put in the setting for. I could basically have it build the configuration either or with cloud build I could use a docker file as well. And again, I have several choices. I could also match any branch.
Now in the Cloud source repositories module, I showed you how you could figure out the branches. There’s a drop down here that will tell you. So you could select what branch of that repository that you want to basically trigger on. If I go over here and configure that however I want, I could basically specify the config file, et cetera. There’s a lot more to this, so I just wanted to go ahead and create a quick trigger to show you. And now I have my trigger and it’s pointing to the marbles application right there that I copied over from essentially GitHub to cloud source repositories.
With that said, I could add another trigger and I could select again cloud source repositories. I could select the same one if I want, create a different trigger. I could just go back, add a trigger from GitHub and then it basically will ask me do I consent? Go continue. And you can see that will bring up the repositories that are available. Go continue. And again I could go create a trigger based on whatever requirements that I so choose. With that said, simple enough I think for now, let’s go ahead and move on to the next module.
6. Demo Gcloud Commands
Now in the course download should be a command line list, and it’s a PDF document that you can download to help put together the commands that are part of the objectives of the course and also the exam. Now, we’re going to definitely only need to know a lot of Gcloud commands. Now, through the course, I’m going to cover a lot of these commands, such as around changing projects and describing your project, how to use the emulators, how to set up your IDE environment. But I have pretty much all the commands that you would want to know for this exam. Fairly well documented. We absolutely need to know Kubernetes and G Cloud container commands, and we’ll definitely need to practice, again, some of these before we take the exam. We certainly will expect to get these.
They’ll be one or two SQL commands and then Cloud Spanner as well. And then lastly, there’s a couple of commands for Cloud pub, Sub, BigQuery. Some things we want to do to create a data set. We’ll definitely need to go through that. And then if we scroll down Cloud Build, we’ll need to learn that as well. And app engine. So that’s the main focus areas. Now, for those that have not used Gcloud, this is part of the SDK.
I have several demos on the SDK coming up, so we’ll go through that. But for those that have not installed the SDK and have it on your desktop locally, you go over here to Cloud Shell, and Cloud Shell will bring up a virtual machine. It’s a ten megabit virtual machine instance. Essentially, it’s free, it’s part of Google Cloud, and we could go ahead and just list our projects, for example, that shows us our projects. And we definitely will need to learn G Cloud and the commands that are part of the SDK G Cloud suite, and that also includes BigQuery and gsutil and Kubernetes as well. So definitely get some practice around this sheet. I won’t go through every command.
However, we will go through most of these in the course. The reality is, again, there’s a lot of commands. The best way to learn these commands is to type them out, figure out how they work. They’re really easy. Overall, gcloud is really simple. I call it like a light version of Linux. So with that said, let’s move on. Make sure you do download the PDF in the content distribution part of the course, and I hope to see it further on in the course. Let’s move on.
Interesting posts
The Evolving Role of ITIL: What’s New in ITIL 4 Managing Professional Transition Exam?
If you’ve been in the IT service management (ITSM) world for a while, you’ve probably heard of ITIL – the framework that’s been guiding IT professionals in delivering high-quality services for decades. The Information Technology Infrastructure Library (ITIL) has evolved significantly over the years, and its latest iteration, ITIL 4, marks a substantial shift in… Read More »
SASE and Zero Trust: How New Security Architectures are Shaping Cisco’s CyberOps Certification
As cybersecurity threats become increasingly sophisticated and pervasive, traditional security models are proving inadequate for today’s complex digital environments. To address these challenges, modern security frameworks such as SASE (Secure Access Service Edge) and Zero Trust are revolutionizing how organizations protect their networks and data. Recognizing the shift towards these advanced security architectures, Cisco has… Read More »
CompTIA’s CASP+ (CAS-004) Gets Tougher: What’s New in Advanced Security Practitioner Certification?
The cybersecurity landscape is constantly evolving, and with it, the certifications that validate the expertise of security professionals must adapt to address new challenges and technologies. CompTIA’s CASP+ (CompTIA Advanced Security Practitioner) certification has long been a hallmark of advanced knowledge in cybersecurity, distinguishing those who are capable of designing, implementing, and managing enterprise-level security… Read More »
Azure DevOps Engineer Expert Certification: What’s Changed in the New AZ-400 Exam Blueprint?
The cloud landscape is evolving at a breakneck pace, and with it, the certifications that validate an IT professional’s skills. One such certification is the Microsoft Certified: DevOps Engineer Expert, which is validated through the AZ-400 exam. This exam has undergone significant changes to reflect the latest trends, tools, and methodologies in the DevOps world.… Read More »
Certified Cloud Security Professional (CCSP): Exam Content and Salary Insights
As the digital landscape continues to expand and evolve, cloud security has become a top priority for businesses moving their operations online. In this fast-paced world, safeguarding data in the cloud is not just a necessity—it’s a vital component of a company’s success. If you’re looking to carve out a career in this high-demand, ever-evolving… Read More »
Cryptocurrency and Blockchain Certification: A Guide to Career Opportunities
Cryptocurrency and blockchain have moved beyond mere buzzwords – they’re transforming industries, disrupting traditional systems, and creating a wave of career prospects. If you’re eager to ride this wave and position yourself at the forefront of this technological revolution, certification is your key to unlocking the door. But where do you start? In this guide,… Read More »