If you have been keeping an eye on this blog, you might notice that the Kubernetes application which I am building is coming to a finish. Well, I am happy to announce you that this is indeed correct. In the 4th week of my internship, I managed to fully migrate an application consisting out of multiple components, to a Kubernetes Cluster.
Absolutely not, this first migration has taught me a lot of the Kubernetes world. The biggest lesson that I have learned is the fact that the possibilities are endless with Kubernetes. This project was a good journey to learn me the basics of Kubernetes and to set me up on following the road to becoming a “Kubernetes hero” as it sparked my interest.
Now don’t be scared, this won’t be the last blog post as my Kubernetes struggles will continue with the next application that is up for migration. That’s right, the point of this internship is to migrate 3 fully working applications onto a single Kubernetes cluster, so for now we have 1 down with 2 more to go.
As this was the biggest application of the 3, meaning that it contained the most components, it became quiet the challenge to migrate so I am kind of happy that I can move on to a new project. I still do have the feeling that I owe you, the reader, a last farewell of this project.
At first glance, this dashboard might not be quiet clear as to what it is trying to convey but i’ll try my best to explain.
On this dashboard you can see the most important statistics regarding the vacancies and candidatures of the registered profiles. You might wonder which vacancies and candidatures that I am talking about. This application is basically a recruitment tool where candidates and open vacancies are collected and combined together with. It’s a tool that is used internally in the company to link profiles with fitting job vacancies.
After finalizing all the details of this Kubernetes deployment, I took a week long holiday as it’s also a part of my internship. During this week I kind of cleared my head and took a break on working on some of the tasks of my internship. I had caught up with some friends and enjoyed my little break whilst I was rebuilding my energy to tackle on the next challenge.
Now the trend in this blog will continue as my next application is also a tool that is used internally. I won’t reveal much info about the application for now but throughout the next blog posts you will probably get some hints on what kind of tool it is. Like the recruitment tool I began building a deployment of the backend, to say that this had an unexpected start was a slight understatement. An important part of Kubernetes is the fact that all the deployments are based on Docker images. When I found out the backend of this application was also based on a Spring boot application, I was kind of relieved because it meant that the deployment will look a lot like my previous Spring boot deployment. Sadly, I was not so relieved afterwards because I also found out that there was no Docker image available of this application.
I had worse problems throughout this journey so surely building a Docker image from a Spring boot application couldn’t be that hard. Fortunately, it wasn’t. After consulting with my mentor Jan, I had received enough pointers to have a good start on this application. Because the Spring boot application is a Gradle project, it was as easy as defining a Jib plugin into the build file and a few minutes later I had deployed a functioning Docker image to our Nexus repository. If only every task in this internship was as easy as this one.
After a while, I had a fully functioning Spring boot deployment of the 2nd application running. This went smoothly as it resembled the first application a lot . The next step would be deploying the database. To make things a bit interesting, the database for this application was a MongoDB database. I had a little bit of prior knowledge of MongoDB so I didn’t think I would have any problems on deploying and working on this component. The deployment of the database went fairly easy, not much configuration needed and pretty straight forward. Exactly the same as the Angular deployment.
After the deployment, I will need to fill the database with some initial data so I would have login credentials to access the application. It doesn’t seem as a hard task but I spend a whole day figuring out how I could import a dump of the database to the Kubernetes MongoDB. I even asked the help of Maarten, a developer who works on the internal application, to help me brainstorm on this problem. Just like when Frodo and Sam were climbing mount Doom, me and Maarten were climbing stackoverflow threads looking for an answer. We tried every possible flag of the mongorestore command to import the dump file but to no avail. At the end of the day when we almost were ready to give up, I noticed a small problem in a path of our file and it finally worked. The internal application had filled with login data whilst Maarten and I were cheering as like we just threw the ring into Mount Doom.
The last few weeks were really rewarding as I managed to fully finish one application whilst almost finishing a 2nd one. It also makes me notice that my internship is nearly halfway done. The learning curve has been steep but fun nonetheless and I can’t wait for my next challenge.