-
Notifications
You must be signed in to change notification settings - Fork 43
Lab: Deploying EKS Microservices using Jenkins
In this lab we will be doing below steps:
- We will build the docker image and push it to ECR.
- Then Pull the image on Spinnaker and try to do deployments with the help of Spinnaker.
Before starting working on the Lab, Make sure you are sharing your GITHUB Token
and YOUR_TEAM_NAME
with Instructor of the workshop so that they can add your account in Spinnaker from the back-end.
Now Fork the Spinnaker-Study Repository into your Public Github account and then clone it to your local.
Notice the manifests/deploy-microservice.yml file, and see the Deployment, and the Service.
Now we need to make updates on the all the files present under manifests
directory and replace mild-temper
with YOUR-NAME
or YOUR-TEAM-NAME
.
After making the updates you are good to push your code back to your repository.
-
Open Jenkins and login with the
username: spinnaker
andpassword: timeisluxury
-
Click on New Item, and a
Pipeline Job
in Jenkins -
Name your job
<YOUR-TEAM-NAME>-microservice
, and click Ok -
Under
Build Triggers
, selectPoll SCM
, and in the text area enter* * * * *
. -
Under Pipeline, change Definition to
Pipeline Script from SCM
. -
Change SCM to
Git
, and enter your repository URL that you cloned for your team i.e. Spinnaker-Study repository -
Save and Build the Job and see if your docker image is getting push to ECR or not.
-
Open Spinnaker, this is not secure so don’t place any personal information.
-
Once there create an Application with the
name
:<YOUR-TEAM-NAME>-microservice
-
Add
your email
asOwner Email
-
In
Repo Type
, Choosegithub
. -
In
Repo Project
, EnterForked Repo Link
. -
In
Repo Name
, EnterName of your repositoey
. -
In
Cloud Providers
, ChooseKUBERNETES
. -
Create an instance port of 80
-
Click on
Create
to create the Application
Now you should inside the Application that you have created.
-
Click on Pipelines, and click on "Configure a new pipeline"
-
Under Pipeline Name, name it "ToStaging"