logo

NJP

ServiceNow DevOps Manually Approved Deployment

Import · Aug 04, 2022 · video

[Music] hey everyone it's justin thank you for watching in this video we're going to continue our devops conversation this is going to be a parallel video to submitting or making a change and that following a process and following the pipeline and creating changes in servicenow what's different in this one is that we're not going to have a work item associated with our change in azure devops and our change policy is configured to say hey if there's no work item we're not going to auto approve the change we're going to assign that to the change management group to approve so let's get started on it i'm in azure devops and in the previous video we went and created a work item we're purposely not going to do that this time and what i'm going to do is i'm going to go straight to the repo and i'm going to create a branch right so those are you the developers you know this is a no no you're not supposed to do this but i'm going to go straight in there and i'm going to create a new branch and start working on this so we'll just give it a name demo branch with no work item and uh we're going to base on the main one and look i'm not going to link this branch to a work item right so i'm really doing stuff i shouldn't do it's not best practice and that's why we're going to follow a different change policy so if i open that branch this is similar to the last one i'm just going to come in here and make a change to this one and i'll just say no work item for these changes should not auto approve my chain all right so i'm going to commit that and i'm not going to associate again any work item with this i'm just going to go ahead and commit and make sure that's in the system now something i didn't show in my last video is the commits within servicenow so i can get straight to that um that particular information within the platform just by going straight to them so i don't have to go through the change request i don't have to go through um the uh the application itself i could just go straight to them and so i'm going to go ahead and search on my name here and uh that way i get past all this demo data that's in this particular instance and i have a commit here that was done just you know just now if i open it up i'm going to see servicenow already sees what i did right so i have a branch in here called demo branch with no work item right so it already knows it's there i'm going to come back to azure devops and what we're going to do same as before we're going to create a pull request which that means we're going to merge this branch back to the main branch right so that's when our pipeline gets called we again are not going to associate a work item with it so we're going to go ahead and create it and once it's created i'm going to complete it using this complete button here at the top and that will go ahead and start the pipeline running within azure devops not going to customize the message or anything and i'm clicking on this complete merge button right down here on the bottom right and that was what is going to kick off my pipeline so if i go to pipelines here in azure devops we can see it's in progress there's something going on i've got this one that's in progress now and it's in the build phase notice here again related items there are no work items there are no artifacts related to this particular pipeline run and that build phase has started so servicenow should know about this by at this point so i'm going to come back in here we're going to go back to our pipeline ui so i'm going to open my pipeline within servicenow and then navigate over to the pipeline ui and that's going to show this build step it went ahead and completed so we can see here yes it went ahead and completed an azure devops so they're in sync there now it should start at number 52 so i'm looking at these numbers and the pipeline history right here so my build was number 51 so i'm looking for a 52 i'm going to hit the refresh button to get that refresh and we should see a 52 when i do that i do and i have a test up that did complete so that should correspond again with what we're seeing over in azure devops and it does notice my deploy stuff though it's still in progress it has not turned green it hasn't comple hasn't been completed yet so let's take a look at this deploy step in service now just to show you i'm going to click on it and show it's still not done if we view this change you're going to see something different than you saw in this other video look at this this change is waiting for approval it did not auto approve this change it's not moving forward the pipeline is stopped it's going to stay in this deploy state until forever or we hit a timeout and you can configure a timeout within your within your pipelines but i'm going to go ahead and scroll down and show you this actually got assigned to a group change management and then caleb and the change manager or in that particular group so this is not going to move forward this is not going to go until we do that so just to emphasize that you know click off and click on and refresh it we're going to view that change we're going to see it's still pending approval i'm going to show you that pipeline is still in deploy so it hasn't moved forward now let's go ahead and approve it we're going to say hey we looked at this we're fine right click and i'm going to approve and now it will go ahead and proceed and if we were to sit here and watch the notes actually it went really fast you can see once it went the once it got approved it automatically went from scheduled um to no one from authorized to scheduled and then from scheduled to implement so now the devops flow is picking back up and running with that we should see at this point the pipeline has probably realized that the change got approved and it did so we see here that it turned green so we're good on this side if we go back to service now we should see that after this implement step it'll go to a review step it just did right there live while i was talking so we are in the review step if i go ahead and close this change request and just click off and click on we should see that this turned green on this deploy step and we actually have a stopped date and time for that particular deployment so the big differentiator between this video and the last video is we did not associate a work item with the chat with the commit we made in azure devops and because of the change policy we have configured it did not auto approve the change it assigned it to a group someone to review manually before that pipeline completed so as i said in my original video when i introduced devops introduction you can accelerate the change process and you can slow down the change process there's good reasons to do both and hopefully this video and the previous one helped illustrate how you can do that with servicenow i hope you found this video helpful if you did please like please subscribe or share it with somebody you think might be interested in devops and until next time don't forget to always be learning [Music] you

View original source

https://www.youtube.com/watch?v=N2cKyuID9Cc