<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Developers @ Asurion</title>
    <description>The latest articles on DEV Community by Developers @ Asurion (@devsatasurion).</description>
    <link>https://dev.to/devsatasurion</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Forganization%2Fprofile_image%2F5892%2F812715f7-2cc4-4e2b-b99b-ff0b8c9bf908.png</url>
      <title>DEV Community: Developers @ Asurion</title>
      <link>https://dev.to/devsatasurion</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/devsatasurion"/>
    <language>en</language>
    <item>
      <title>All the MongoDB Commands that You Need to Know</title>
      <dc:creator>Kaye Alvarado</dc:creator>
      <pubDate>Fri, 24 Jan 2025 08:44:45 +0000</pubDate>
      <link>https://dev.to/devsatasurion/all-the-mongodb-commands-that-you-need-to-know-dlm</link>
      <guid>https://dev.to/devsatasurion/all-the-mongodb-commands-that-you-need-to-know-dlm</guid>
      <description>&lt;p&gt;Here is a collection of common NoSQL queries and the mongodb commands needed for them:&lt;/p&gt;

&lt;h3&gt;
  
  
  1. Exact Match
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Collection Name:&lt;/strong&gt; users&lt;br&gt;
&lt;strong&gt;Object  Field:&lt;/strong&gt; first_name&lt;br&gt;
&lt;strong&gt;Search for:&lt;/strong&gt; Kaye&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;db.getCollection&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s1"&gt;'users'&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;.find&lt;span class="o"&gt;({&lt;/span&gt;&lt;span class="s2"&gt;"first_name"&lt;/span&gt;:&lt;span class="s2"&gt;"Kaye"&lt;/span&gt;&lt;span class="o"&gt;})&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  2. Like Match
&lt;/h3&gt;

&lt;p&gt;&lt;strong&gt;Collection Name:&lt;/strong&gt; users&lt;br&gt;
&lt;strong&gt;Object  Field:&lt;/strong&gt; last_name&lt;br&gt;
&lt;strong&gt;Search for:&lt;/strong&gt; varad&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;db.getCollection&lt;span class="o"&gt;(&lt;/span&gt;&lt;span class="s1"&gt;'users'&lt;/span&gt;&lt;span class="o"&gt;)&lt;/span&gt;.find&lt;span class="o"&gt;({&lt;/span&gt;&lt;span class="s2"&gt;"last_name"&lt;/span&gt;:/varad/&lt;span class="o"&gt;})&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



</description>
      <category>database</category>
      <category>development</category>
    </item>
    <item>
      <title>All the Git Commands that You Need to Know</title>
      <dc:creator>Kaye Alvarado</dc:creator>
      <pubDate>Tue, 07 Jan 2025 05:29:52 +0000</pubDate>
      <link>https://dev.to/devsatasurion/all-the-git-commands-you-need-to-know-caj</link>
      <guid>https://dev.to/devsatasurion/all-the-git-commands-you-need-to-know-caj</guid>
      <description>&lt;p&gt;Here is a collection of common scenarios of code management and the git commands needed for them:&lt;/p&gt;

&lt;h3&gt;
  
  
  1. Clone a repository to your local branch
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;git clone https://github.com/&amp;lt;organization&amp;gt;/&amp;lt;repository_name&amp;gt;.git
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  2. Check if the current state of your local branch
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;git status
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  3. Commit a change from your local to the remote repository
&lt;/h3&gt;

&lt;p&gt;After doing edits (add/update/delete) to the files in your local repository, you can make them available to other developers by pushing your changes to the remote branch. First, stage the changes:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;git add &amp;lt;path&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;&lt;strong&gt;Alternatives&lt;/strong&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;code&gt;git add --all&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;git add .&lt;/code&gt;&lt;/li&gt;
&lt;li&gt;&lt;code&gt;git add ../subpath&lt;/code&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;You can then add a commit message to your check-in. Some developer teams follow the &lt;a href="https://www.conventionalcommits.org/en/v1.0.0/#summary" rel="noopener noreferrer"&gt;Conventional Commit&lt;/a&gt; specification  when adding commit messages, which dovetails &lt;a href="https://semver.org/" rel="noopener noreferrer"&gt;SemVer&lt;/a&gt; and makes it easier to publish release notes based on widely known standards.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;git commit -m "commit message"
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;After adding a commit messsage, you can then push the change to a remote repository. If the &lt;em&gt;remote_branch_name&lt;/em&gt; already exists in the remote repository, a simple &lt;code&gt;git push&lt;/code&gt; command will do.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;git push -u origin &amp;lt;remote_branch_name&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  4. Revert to a previous commit in the remote branch
&lt;/h3&gt;

&lt;p&gt;There are times when you accidentally push a commit to an incorrect remote branch and wishes to revert to a previous commit. You can follow the following steps in order to do this.&lt;br&gt;
First identify the commit id by checking the git history&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;git log
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You can then switch your local to an older &lt;code&gt;commit_id&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;git reset --hard &amp;lt;commit_id&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Then, force push the current state of the branch to the remote branch. Make sure that there are no restrictions in the remote branch against force pushes.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;git push -f origin &amp;lt;remote_branch_name&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  5. Reset commit history in a git repository
&lt;/h3&gt;

&lt;p&gt;These sequence of steps will essentially reset the git commit history of the remote repository by overwriting the main branch (which contains all commit history) with a fresh branch that contains all the files of the main branch:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;git checkout --orphan temp-branch
git add -A
git commit -m "reset history"
git checkout main
git reset --hard temp-branch
git branch -D temp-branch
git push -f origin main
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  6. Deleting local and remote branches
&lt;/h3&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;[for local branch]
git branch -D [branch-name]
[for remote branch]
git push origin -d [branch-name]
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  7. Squash multiple commits
&lt;/h3&gt;

&lt;p&gt;View the list of commits in the current branch with &lt;code&gt;git log&lt;/code&gt;, then identify the start of the commit that needs to be squashed.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;222bb33  Adjust tests
99aa111  add feature
def5678  fix: type
abc1234  initial commit
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;In the results above, I want to combine the commits from &lt;code&gt;def5678&lt;/code&gt; to &lt;code&gt;222bb33&lt;/code&gt; to a single commit. With this,  start interactive rebase with the commit before the first in the range which should be &lt;code&gt;abc1234&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;git rebase -i abc1234
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;In the editor that opens, change the top commit as &lt;code&gt;pick&lt;/code&gt; and change the subsequent ones that needs to be squashed to that commit as &lt;code&gt;squash&lt;/code&gt;. Then, save and exit.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;pick def5678  fix: type
squash 99aa111  add feature
squash 222bb33  Adjust tests
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Push to the remote branch.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;git push --force-with-lease
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;p&gt;And that's it! Let me know if you have questions in any of the use-cases!&lt;/p&gt;

&lt;p&gt;Are there any other common scenarios in code management that is useful to you? Leave them at the comment section for others!&lt;/p&gt;

</description>
      <category>git</category>
      <category>github</category>
    </item>
    <item>
      <title>K8s QuickBites: Helm Basics</title>
      <dc:creator>Kaye Alvarado</dc:creator>
      <pubDate>Mon, 26 Aug 2024 01:12:00 +0000</pubDate>
      <link>https://dev.to/devsatasurion/k8s-quickbites-helm-basics-25hj</link>
      <guid>https://dev.to/devsatasurion/k8s-quickbites-helm-basics-25hj</guid>
      <description>&lt;p&gt;Hey there! Welcome to another quick bites blog on Kubernetes. Read time, 2 minutes! I like to keep it short and serve as quick references only when doing common tasks as a K8s administrator.&lt;/p&gt;

&lt;p&gt;The focus of this discussion is on &lt;em&gt;Helm&lt;/em&gt;. &lt;/p&gt;

&lt;h2&gt;
  
  
  What is Helm?
&lt;/h2&gt;

&lt;p&gt;Think about bringing up an end-to-end application in Kubernetes with multiple yaml files that includes various resources such as deployments, service accounts, secrets, and others. A simple application would have some complexity in management, but as it becomes larger, it would be very difficult to manage. This is what helm is trying to solve.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://helm.sh/" rel="noopener noreferrer"&gt;&lt;em&gt;Helm&lt;/em&gt;&lt;/a&gt; is nothing but a package manager for Kubernetes. Helm is used to manage Charts, which are packages of pre-configured Kubernetes resources making application management in Kubernetes way easier.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F6xmkbmiugut9c8cuat5l.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F6xmkbmiugut9c8cuat5l.png" alt="Image description" width="410" height="407"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Installation of helm is pretty straightforward and options can be viewed &lt;a href="https://helm.sh/docs/intro/install/" rel="noopener noreferrer"&gt;here&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;
  
  
  Basic Helm Commands
&lt;/h2&gt;

&lt;p&gt;First, search and download from a helm repository to your local machine. You can also update it if it already exists.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;$helm search repo &amp;lt;repository&amp;gt;
$helm repo update &amp;lt;repository&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;To view the existing repositories on your local machine, you can use the list command&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;$helm ls 
NAME         CHART VERSION   APP VERSION.  DESCRIPTION                                       
chart/name   1.0.0           1.0.0         App Description
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Install Helm Charts
&lt;/h2&gt;

&lt;p&gt;You can install a helm chart overriding the default values with a values.yaml file.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;$helm install &amp;lt;chart&amp;gt; &amp;lt;repo&amp;gt; -n &amp;lt;namespace&amp;gt; -f &amp;lt;path to values.yaml file&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Once installed, you can then verify the deployments, daemonsets, or other resources that was installed&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;$kubectl get deploy -n &amp;lt;namespace&amp;gt;
$kubectl get ds -n &amp;lt;namespace&amp;gt;
$kubectl get pods -n &amp;lt;namespace&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;You can also use the values used in the helm installation and modify this for a later update&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;$helm get values &amp;lt;release-name&amp;gt; -n &amp;lt;namespace&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Upgrade Helm Charts
&lt;/h2&gt;

&lt;p&gt;Everytime you upgrade a helm chart, a revision is added and this allows you to easily rollback to a previous version if an upgrade becomes problematic. List the versions with the list command (for the current deployed chart), or the history command.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;$helm list -n &amp;lt;namespace&amp;gt;
NAME   NAMESPACE  REVISION  UPDATED     STATUS   CHART  
chart  namespace  2         &amp;lt;datetime&amp;gt;  deployed chart-1.0.0
$helm history &amp;lt;chart&amp;gt; -n &amp;lt;namespace&amp;gt;
REVISION    UPDATED                     STATUS      CHART                   APP VERSION DESCRIPTION     
1           Thu May 23 18:53:23 2024    superseded  chart-0.9.9 0.9.9       Install complete
2           Mon Jun  3 19:52:28 2024    superseded  chart-1.0.0 1.0.0       Upgrade complete
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;To rollback to a previous version, you can use the rollback command&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;$helm rollback &amp;lt;chart&amp;gt; &amp;lt;version&amp;gt; -n &amp;lt;namespace&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;There may be times when a simple upgrade will fail due to a major change in the helm package. An option here is to do an uninstall and install.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;$helm uninstall &amp;lt;chart&amp;gt; -n &amp;lt;namespace&amp;gt;
$helm install &amp;lt;chart&amp;gt; &amp;lt;repo&amp;gt; -n &amp;lt;namespace&amp;gt; -f &amp;lt;path to values.yaml file&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;






&lt;p&gt;...and that's it! Happy helming! 😄&lt;/p&gt;

</description>
      <category>kubernetes</category>
      <category>helm</category>
      <category>cncf</category>
      <category>devops</category>
    </item>
    <item>
      <title>Don't Dead End Your Dev Career: Using Communication to Amplify Your Possibilities</title>
      <dc:creator>Bradston Henry</dc:creator>
      <pubDate>Thu, 22 Aug 2024 14:06:37 +0000</pubDate>
      <link>https://dev.to/devsatasurion/dont-dead-end-your-dev-career-using-communication-to-amplify-your-possibilities-8nn</link>
      <guid>https://dev.to/devsatasurion/dont-dead-end-your-dev-career-using-communication-to-amplify-your-possibilities-8nn</guid>
      <description>&lt;p&gt;&lt;strong&gt;NOTE TO READER FROM AUTHOR:&lt;/strong&gt;&lt;br&gt;
&lt;em&gt;This blog is primarily intended for Developers and Software Engineers looking for new ways to improve their career growth potential and attraction to possible future employers.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;This is a practical approach to differentiating yourself from amongst your peers and is a brief summary of learnings I have gained from my experience as an Engineer, Software Developer, Team Lead, Interviewer, and Manager. I hope this information is as helpful to you, as it has been for me.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Thanks for reading and enjoy!&lt;/em&gt;&lt;/p&gt;




&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fm1wr0bw1jd98vqp0ihh7.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fm1wr0bw1jd98vqp0ihh7.png" alt="Bradston standing on a stage with a microphone in hand addressing a crowd" width="800" height="810"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;As a self-taught software developer, a developer relations manager and an aspiring and ever-growing writer, I've always clung to the belief that it's &lt;code&gt;"All about what you do, not what you say"&lt;/code&gt;. &lt;/p&gt;

&lt;p&gt;That your 'work' should speak for itself, and that 'words' are "nice", but offer very little real value in a tangible sense.&lt;/p&gt;

&lt;p&gt;But as I near my 10th year in the tech industry, I've discovered that the adage, &lt;code&gt;“Talk is cheap”&lt;/code&gt; may not be as true as I once thought it was.&lt;/p&gt;

&lt;p&gt;But that the real adage, especially for my fellow developers and software engineers, should be, &lt;code&gt;“Talk isn't cheap, Talk is ESSENTIAL”&lt;/code&gt;.&lt;/p&gt;




&lt;h2&gt;
  
  
  Do What You Say and Say What You Do
&lt;/h2&gt;

&lt;p&gt;As I look back on my software development career and my overall journey that has brought to where I am now, I have started to recognize a specific skill that has helped me to stand out amongst my peers. That skill is...&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;The ability to communicate clearly and effectively to those who I work with and those who I engage with, on any level.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;I've truly come to realize, that the key to continued success is simply the ability to “talk” or, more aptly said, &lt;strong&gt;communicate&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;My capacity to express my ideas clearly, if not always succinctly, has allowed me to convey my technical skills and abilities while adeptly navigating the minutia of the complex dynamics that come with intra-organizational functional growth.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“Wait?!? What did you just say?!?”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Essentially, having the ability to communicate has allowed me to showcase my technical skills more readily, while allowing me to navigate the difficulties that come with pursing “that promotion” or that position that I desire.&lt;/p&gt;

&lt;p&gt;Having the acumen to speak on my technical ability to diverse audiences has made it a “no brainier” to hire me (or promote me) over candidates with similar skill sets and experience.&lt;/p&gt;

&lt;p&gt;I haven't just “walked the walk”, I've “talked the talk”.&lt;/p&gt;

&lt;p&gt;Over time, I've discovered that one of the most important skills needed to have an impactful career in software engineering, is &lt;strong&gt;the ability to communicate well&lt;/strong&gt;.&lt;/p&gt;




&lt;h2&gt;
  
  
  "But I'm a Talented Software Engineer, Shouldn't my Skills Speak for Themselves?"
&lt;/h2&gt;

&lt;p&gt;In a perfect world, humans would be able to easily identify exactly who is the best person for any given role by just simply looking at them.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“Yup! They’ll be the perfect accountant. I can see it in their eyes”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;But in reality, determining competency and the ability to perform is a complex task. Finding the best person for any given role or opportunity can be incredibly difficult. &lt;/p&gt;

&lt;p&gt;Great things (and even great people) are not easy to recognize, without something “speaking on its behalf”.&lt;/p&gt;

&lt;p&gt;Let's take the cautionary tale of the movie &lt;em&gt;Elemental&lt;/em&gt;. &lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F5j469ez8xk2giglzy0wh.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F5j469ez8xk2giglzy0wh.jpg" alt="Elemental | ©2023 Disney/Pixar. All Rights Reserved" width="800" height="333"&gt;&lt;/a&gt; &lt;em&gt;©2023 Disney/Pixar. All Rights Reserved.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Elemental&lt;/em&gt;, a Disney Pixar movie that was released in the summer of 2023, has the unfortunate honor of having the &lt;a href="https://www.cbr.com/elemental-pixar-worst-opening-box-office/" rel="noopener noreferrer"&gt;2nd worst box office opening&lt;/a&gt; for the animation studio &lt;em&gt;Pixar&lt;/em&gt;, since the release of &lt;em&gt;Toy story&lt;/em&gt; in 1995. &lt;/p&gt;

&lt;p&gt;But oddly enough, &lt;em&gt;Elemental&lt;/em&gt; currently has a &lt;a href="https://www.rottentomatoes.com/m/elemental_2023" rel="noopener noreferrer"&gt;93% audience score&lt;/a&gt; on Rotten Tomatoes, which shows that the movie was not just enjoyed by those who saw it, but loved.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;So what happened to &lt;em&gt;Elemental&lt;/em&gt;?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Rua Fay at &lt;em&gt;Cinemasters&lt;/em&gt; does a great job of summarizing the events that lead to the fiasco in &lt;a href="https://www.cinemasters.net/post/how-pixar-s-marketing-failed-elemental" rel="noopener noreferrer"&gt;her blog&lt;/a&gt;, but in short, Disney didn't do a great job at marketing the movie. The movie's marketing focused on the wrong elements (pun not intended) of the &lt;em&gt;Elemental&lt;/em&gt; while targeting a niche audience.&lt;/p&gt;

&lt;p&gt;Luckily, &lt;em&gt;Elemental&lt;/em&gt; ended up &lt;a href="https://screenrant.com/elemental-box-office-bomb-success-comeback/" rel="noopener noreferrer"&gt;finding its audience&lt;/a&gt; and performing better at the box office (keeping it from being a financial loss for Disney), but it's success was massively hindered by what was communicated about it.&lt;/p&gt;

&lt;p&gt;It wasn't successful at the box office because of its quality as a movie.&lt;/p&gt;

&lt;p&gt;It was less successful because of &lt;em&gt;what Disney communicated about it&lt;/em&gt;.&lt;/p&gt;

&lt;p&gt;So take a moment and ponder... &lt;/p&gt;

&lt;p&gt;What do you communicate about yourself to others you work with? &lt;/p&gt;

&lt;p&gt;How well do you communicate the value you bring to the table?&lt;/p&gt;

&lt;p&gt;And lastly..&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Are the only people who know your capabilities, competencies and strengths, those who have worked with you directly and/or those who have managed you directly?&lt;/em&gt;&lt;/p&gt;




&lt;h2&gt;
  
  
  Breaking the Curse of the 'Silent Engineer'
&lt;/h2&gt;

&lt;p&gt;Even if you're currently not doing well in the realm of communicating your skills and what you have to offer, I want to ensure you that it's never too late to make a change.&lt;/p&gt;

&lt;p&gt;You may not believe this (if you were to follow my career, watch my behaviors and have awareness of the activities I engage in) but I'm an introvert who suffers from social anxiety. &lt;/p&gt;

&lt;p&gt;When I was younger, I found managing social scenarios immensely difficult. Though I've grown substantially through out the years, I sometimes still feel incredibly anxious doing simple social things; like raising my hand to answer a question in a classroom setting. &lt;/p&gt;

&lt;p&gt;But my personal weaknesses and my general social preferences, have very little to do with my ability to communicate and express myself in a professional setting.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F31m0ntjdf6yczqx0pcqb.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F31m0ntjdf6yczqx0pcqb.jpg" alt="Man Wearing Black and White Stripe Shirt Looking at White Printer Papers on the Wall" width="800" height="533"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;So how does a software developer grow in their communication skills and set themselves apart for more opportunities to flourish in their career?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Well, here are a few things I recommend doing to help yourself grow and build your communications skills:&lt;/p&gt;

&lt;h3&gt;
  
  
  1. Create a "Personal Elevator Pitch"
&lt;/h3&gt;

&lt;p&gt;&lt;em&gt;If you only had 30-60 seconds to communicate what value you bring to the table as an engineer, what would you say?&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;If you can't answer the above question easily, spend some time crafting a succinct way to express your value. Think through how you would explain what you have to offer to a person who could have a direct impact on your career growth. &lt;/p&gt;

&lt;p&gt;Once you do that, practice sharing your elevator pitch with those you trust. Get feedback on you're communicating and refine your messaging.&lt;/p&gt;

&lt;p&gt;Having an elevator pitch in mind better prepares you to express the value you have to offer at anytime, in any place, at any length. &lt;/p&gt;

&lt;p&gt;Also, as an added benefit, it helps to build confidence and better define your personal strengths.&lt;/p&gt;

&lt;h3&gt;
  
  
  2. Find a mentor to help with communication skills
&lt;/h3&gt;

&lt;p&gt;Finding a person who is willing to guide you on your journey of growth in communication is crucial. Your mentor doesn't have to be a software engineer and your mentor doesn't have to work with you. &lt;/p&gt;

&lt;p&gt;Your mentor should be someone you trust, you admire and who has the experience to help you navigate your path to success. Someone you can ask honest questions, get genuine feedback, and who will encourage you throughout the process. &lt;/p&gt;

&lt;p&gt;In all honesty, a mentor can truly be a "cheat code" when it comes to building skills you lack. Having a mentor(s) is an absolute game-changer to achieving success and growth in communication. &lt;/p&gt;

&lt;p&gt;If you don't have a mentor, reach out to someone you think of highly today, and start the conversation.&lt;/p&gt;

&lt;h3&gt;
  
  
  3. Practice, Practice, Rehearse
&lt;/h3&gt;

&lt;p&gt;Sadly, there is no shortcut to building stronger communication skills, BUT there is a method that works almost every time in helping you be a better communicator; &lt;strong&gt;practice&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;In the &lt;a href="https://www.linkedin.com/posts/bradston-henry_developers-developeradvocacy-blogging-activity-6947264322779717632-QScJ" rel="noopener noreferrer"&gt;Asurion Developer Advocacy Program&lt;/a&gt;, this is one of the topics I hone in on in my lesson on Public Speaking. &lt;/p&gt;

&lt;p&gt;A key component of successful communication is confidence. In order to build confidence, you must first build competence. And to build competence, you &lt;strong&gt;must&lt;/strong&gt; practice. &lt;/p&gt;

&lt;p&gt;Practice can come in many forms: Speaking in the mirror to yourself, preparing a presentation with a colleague, joining &lt;a href="https://www.toastmasters.org/" rel="noopener noreferrer"&gt;Toastmasters&lt;/a&gt;, or creating a podcast. (&lt;em&gt;Note: This is not an exhaustive list&lt;/em&gt;)&lt;/p&gt;

&lt;p&gt;But what's most important is intentionally taking time to work on communicating ideas more effectively in a "safe space", where you can make mistakes and grow.&lt;/p&gt;

&lt;p&gt;As they say, "Practice makes perfect", and building communication skills is no exception. &lt;/p&gt;

&lt;h3&gt;
  
  
  4. Speak up! Advocate For Yourself!
&lt;/h3&gt;

&lt;p&gt;This is hands down one of the most important lessons I was taught in the latter half of my career (from one of my mentors). &lt;/p&gt;

&lt;p&gt;Advocating for yourself is understanding that it is absolutely &lt;strong&gt;your responsibility&lt;/strong&gt; to own you career and speak up for yourself.&lt;/p&gt;

&lt;p&gt;No matter how great your support system, &lt;strong&gt;noone&lt;/strong&gt;, and I mean &lt;strong&gt;noone&lt;/strong&gt;, will ever be able to advocate for you as well as yourself. &lt;/p&gt;

&lt;p&gt;When you believe you are able to do something, say it.&lt;/p&gt;

&lt;p&gt;When you get a new certification or achieve a new accomplishment, share it. &lt;/p&gt;

&lt;p&gt;If you feel you are not getting opportunities for growth and advancement that you believe you deserve, speak up about it.&lt;/p&gt;

&lt;p&gt;This specific principle has been one of the keys to my personal career success. I would not have achieved what I have to this point in my career, without truly adopting this principle. &lt;/p&gt;

&lt;h3&gt;
  
  
  5. Watch the Masters
&lt;/h3&gt;

&lt;p&gt;If you really want to become great at communication, watch and emulate those who are already great at it.&lt;/p&gt;

&lt;p&gt;Sometimes, the best way to learn and grow is to imitate. By watching an individual who is recognized by their peers and community as a strong communicator, you have the opportunity to pick up on obvious and subtle skills that makes them great.&lt;/p&gt;

&lt;p&gt;Also, make sure to watch a diverse set of communicators and see if you can learn the common tactics and approaches they all use. Sometimes, it's hard to recognize what makes any particular individual great without having a greater perspective on different communication styles. &lt;/p&gt;

&lt;p&gt;And if possible, consider asking one of those "masters" if they'd be willing to be your mentor. You never know, you might just get lucky!&lt;/p&gt;

&lt;h3&gt;
  
  
  6. Volunteer to be Uncomfortable
&lt;/h3&gt;

&lt;p&gt;The former CEO of IBM, Ginni Rometty, &lt;a href="https://mitsloan.mit.edu/ideas-made-to-matter/former-ibm-ceo-diversity-and-discomfort-good-ideas" rel="noopener noreferrer"&gt;once said&lt;/a&gt;...&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;One sign an idea is a good one is if it makes people a little bit uncomfortable. That’s because growth and comfort never coexist.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;In order to grow, you have to be willing to be uncomfortable.&lt;/p&gt;

&lt;p&gt;And this principle is true in almost all aspects of life and even more so when it comes to communicating. &lt;/p&gt;

&lt;p&gt;In order to really grow and build your communication skills as a developer or a software engineer, you need to put yourself in situations that challenge you and take you out of your comfort zone. &lt;/p&gt;

&lt;p&gt;Sometimes, it will work out that you will be given a task or assignment that will force you to use your communication skills in new and challenging ways. But, you should never wait for that opportunity to come to you. &lt;/p&gt;

&lt;p&gt;Instead, you should be seeking out opportunities of growth and putting yourself in situations that will &lt;strong&gt;force&lt;/strong&gt; you to grow. &lt;/p&gt;

&lt;p&gt;Is your manager looking for someone to volunteer to communicate some technical details to stakeholders? Volunteer to speak on behalf of the team.&lt;/p&gt;

&lt;p&gt;Is there a need, at the end of a Sprint, for a person to share a summary of work completed by the dev team to the greater team? Speak with your team lead and volunteer to give that summary.&lt;/p&gt;

&lt;p&gt;Are there seemingly no opportunities for communication roles on your team? Speak with your team lead or manager and ask if they can create those opportunities for you.&lt;/p&gt;

&lt;p&gt;Be active in seeking out opportunities to grow in your communication skills. &lt;/p&gt;

&lt;p&gt;Volunteer and take the chance to be uncomfortable and discover the growth that follows.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7hef8zcdxxww4149dj8x.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media2.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F7hef8zcdxxww4149dj8x.jpg" alt="Black and Gray Microphone" width="800" height="533"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  In Conclusion
&lt;/h2&gt;

&lt;p&gt;I feel I have been very blessed in my career and have been able to experience both substantial skill growth and positional growth. I would attribute that, not only to my technically proficiency, but also to my goal of focusing on communicating more effectively.&lt;/p&gt;

&lt;p&gt;And I can confidently say, that when competing for roles or opportunities, where I am equally qualified or even less qualified than my peers, that my ability to communicate has helped me to outpace the competition.&lt;/p&gt;

&lt;p&gt;If you are looking to advance your career, expand your influence within your company or community at large, or if you aim stand out amongst candidates all vying for the same open role at an organization, consider building your communication skills. &lt;/p&gt;

&lt;p&gt;I know without a shadow of a doubt, I owe much of my career success to the ability to not just “walk the walk” but  also “talk to talk”.&lt;/p&gt;

&lt;p&gt;All the best,&lt;/p&gt;

&lt;p&gt;Bradston Henry&lt;/p&gt;




&lt;p&gt;&lt;strong&gt;Do you have any other suggestions on how developers and engineers can grow their communication skills? If you do, please share them the comments below. I would love to hear them!&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Note:&lt;/em&gt; &lt;br&gt;
&lt;em&gt;I am very passionate about this topic and believe that for many software engineers, that this area of expertise that can be difficult to master. If you'd like me to expand on this topic and go into more depth into the specifics of how to grow proficiency in communication, please let me know. I'd love to continue diving into this topic if others would find value in it. Thanks!&lt;/em&gt;&lt;/p&gt;




&lt;p&gt;&lt;strong&gt;Photo Credits(Order of Appearance):&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Cover Photo by &lt;a href="https://www.pexels.com/photo/dead-end-road-sign-1469196/" rel="noopener noreferrer"&gt;Dustin Tray from Pexels&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Elementals: ©2023 Disney/Pixar. All Rights Reserved.&lt;/p&gt;

&lt;p&gt;Photo by &lt;a href="https://www.pexels.com/photo/man-wearing-black-and-white-stripe-shirt-looking-at-white-printer-papers-on-the-wall-212286/" rel="noopener noreferrer"&gt;Startup Stock Photos&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Photo by &lt;a href="https://www.pexels.com/photo/black-and-gray-microphone-164829/" rel="noopener noreferrer"&gt;Pixabay from Pexels&lt;/a&gt;&lt;/p&gt;




&lt;p&gt;Follow me on my Socials:&lt;br&gt;
&lt;a href="https://linktr.ee/bradstondev" rel="noopener noreferrer"&gt;https://linktr.ee/bradstondev&lt;/a&gt;&lt;/p&gt;

</description>
      <category>developer</category>
      <category>career</category>
      <category>careerdevelopment</category>
      <category>communication</category>
    </item>
    <item>
      <title>K8s QuickBites: Creating Secure TLS Certificates for Kubernetes Deployments</title>
      <dc:creator>Kaye Alvarado</dc:creator>
      <pubDate>Wed, 21 Aug 2024 12:50:47 +0000</pubDate>
      <link>https://dev.to/devsatasurion/k8-quickbites-creating-secure-tls-certificates-for-kubernetes-deployments-gfb</link>
      <guid>https://dev.to/devsatasurion/k8-quickbites-creating-secure-tls-certificates-for-kubernetes-deployments-gfb</guid>
      <description>&lt;p&gt;This is the first of a series of blogs about Kubernetes Fundamentals, providing a quick step-by-step guide for each management scenario that is relevant when maintaining K8s workloads.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ftl5jz6gzxkstmmmeow1x.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Ftl5jz6gzxkstmmmeow1x.png" alt="Image description" width="507" height="388"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;A Kubernetes application can be secured by adding a an SSL certificate to the deployment configuration. This quick bites shows how to manually do this.&lt;/p&gt;

&lt;h2&gt;
  
  
  Pre-requisites
&lt;/h2&gt;

&lt;p&gt;It is assumed that the reader has set up their &lt;em&gt;kube config file&lt;/em&gt; in addition to having the following tools available in their machine:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;openssl&lt;/li&gt;
&lt;li&gt;kubectl&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Let's dive in to the steps!&lt;/p&gt;

&lt;h2&gt;
  
  
  Creating the Private Key and Certificate Files
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;Create a &lt;em&gt;private key file&lt;/em&gt; using an encryption of your choice
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;openssl genrsa -aes256 -out privatekey.pem 4096 
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;Now, create a &lt;em&gt;certificate signing request (csr)&lt;/em&gt; from the key. A series of questions will come after this command prompting for details of the certificate such as country, state, city, domain name, etc.
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;openssl req -new -sha256 -key privatekey.pem -out certreq.csr
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;Then get a trusted certificate authority (CA) to sign your certificate. Optionally, you can also make the certificate self-signed.  Download the generated crt &lt;code&gt;tls.crt&lt;/code&gt; and key file. To get the unencrypted privatekey, decrypt it. You can use openssl to do this.
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;#for CA-signed
openssl rsa -in privatekey.pem -out tls.key
#for self-signed
$ openssl req -x509 -new -nodes -days 365 -key privatekey.pem -out tls.crt -subj "/CN=domain.com"
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;Rename the private key to &lt;code&gt;tis.key&lt;/code&gt;. By this time you would have the two files needed for the K8s deployment.
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;$ls tls*
tls.crt tls.key
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;Now, create the secret in the namespace that you need it for, replacing &lt;code&gt;secretname&lt;/code&gt; and &lt;code&gt;namespace&lt;/code&gt; with the proper values respectively
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;kubectl create secret tls &amp;lt;secretname&amp;gt; --cert=tls.crt --key=tls.key -n &amp;lt;namespace&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;A secret will be created in the namespace you specified. You can verify this with the commands below:
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;kubectl get secrets -n &amp;lt;namespace&amp;gt;
kubectl get secret &amp;lt;secretname&amp;gt; -n &amp;lt;namespace&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;The secret will have values for &lt;code&gt;tls.crt&lt;/code&gt; and &lt;code&gt;tls.key&lt;/code&gt;. You can decode this using base64 to view the value.
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;echo &amp;lt;tls.crt value&amp;gt;|base64 --decode
echo &amp;lt;tls.key value&amp;gt;|base64 --decode
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Adding the TLS secret to the Deployment&lt;br&gt;
—--&lt;br&gt;
The second part is how you will update the K8s deployment to include the certificate files and update the config to use this as the application’s certificate.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;First, get the deployment name that you need to edit. Then open the file for editing.
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;kubectl get deployments -n &amp;lt;namespace&amp;gt;
kubectl edit deployment &amp;lt;deployment_name&amp;gt; -n &amp;lt;namespace&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;In the volumes section, add an item for the secret
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;      volumes:
      - name: &amp;lt;secretname_used_for_deployment&amp;gt;
        secret:
          defaultMode: 420
          secretName: &amp;lt;secretname_in_secrets&amp;gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;In the volumeMounts section, add the mount path where the certs will be stored
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;        volumeMounts:
        - mountPath: /etc/ssl/certs
          name: &amp;lt;secretname_used_for_deployment&amp;gt;
          readOnly: true
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;ul&gt;
&lt;li&gt;Once done, you can quickly verify if the certificate is present in the path you provided.
&lt;/li&gt;
&lt;/ul&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;kubectl get pods -n &amp;lt;namespace&amp;gt;
kubectl exec -it &amp;lt;gateway_pod_name&amp;gt; -- ls /etc/ssl/certs
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Depending on the configuration of the deployment, you can point it to pick up the certificate from the path of the certificate and private key paths. Deployments may use different directories so just replace the &lt;code&gt;/etc/ssl/certs&lt;/code&gt; directory when applicable.&lt;/p&gt;

&lt;p&gt;...and that's it!&lt;/p&gt;




&lt;p&gt;Let me know if there are any quick bites requests you want me to publish next!&lt;/p&gt;

</description>
      <category>kubernetes</category>
      <category>secret</category>
      <category>yaml</category>
      <category>devops</category>
    </item>
    <item>
      <title>Taking Your Releases Into Overdrive with GitHub Actions</title>
      <dc:creator>Derek Berger</dc:creator>
      <pubDate>Wed, 14 Aug 2024 20:04:36 +0000</pubDate>
      <link>https://dev.to/devsatasurion/taking-your-releases-into-overdrive-with-github-actions-3edj</link>
      <guid>https://dev.to/devsatasurion/taking-your-releases-into-overdrive-with-github-actions-3edj</guid>
      <description>&lt;h2&gt;
  
  
  Introduction
&lt;/h2&gt;

&lt;p&gt;GitHub Actions’ seamless integration with version control simplifies creating and executing operations and infrastructure workflows. Two key features of Actions for building efficient workflows are:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;a href="https://docs.github.com/en/actions/creating-actions/creating-a-composite-action" rel="noopener noreferrer"&gt;Composite actions&lt;/a&gt;.  Composite actions let you create combinations of steps that you can reuse across different kinds of workflows.&lt;/li&gt;
&lt;li&gt;
&lt;a href="https://docs.github.com/en/actions/writing-workflows/choosing-what-your-workflow-does/defining-outputs-for-jobs" rel="noopener noreferrer"&gt;Job outputs&lt;/a&gt;.  Outputs make values derived from one job's steps available to downstream jobs' steps.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;In this article, I’ll share how Actions’ integration with version control, composite actions, and job outputs helped my team advance our use of Actions to automate production deployments.&lt;/p&gt;

&lt;h2&gt;
  
  
  Mostly manual automation
&lt;/h2&gt;

&lt;p&gt;The workflow that &lt;a href="https://dev.to/devsatasurion/optimizing-devops-automation-in-the-aws-cloud-with-github-actions-42o8"&gt;my team built for disaster recovery&lt;/a&gt; uses a composite action that cuts off DNS traffic to the impaired region. It lets us execute failover in just one step, and the same workflow can be used for any operation that requires rerouting production traffic for an extended time.  We just manually trigger it exactly the same way we would when failing over, specifying which DNS to change and which region to cut off.  &lt;/p&gt;

&lt;p&gt;While that can be helpful for major changes like infrastructure upgrades, major changes are not common.  More often we simply deploy application or configuration updates via pull requests, following &lt;a href="https://github.blog/enterprise-software/devops/applying-gitops-principles-to-your-operations" rel="noopener noreferrer"&gt;GitOps practices&lt;/a&gt;.  To keep our uptime as high as possible and avoid disrupting customers, we tried using the failover workflow to reroute DNS during these everyday changes.&lt;/p&gt;

&lt;p&gt;That at least rerouted traffic how we wanted, but it required multiple manual steps:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Trigger failover workflow to change DNS.&lt;/li&gt;
&lt;li&gt;Merge pull request to deploy application change.&lt;/li&gt;
&lt;li&gt;Verify pods roll out.&lt;/li&gt;
&lt;li&gt;Trigger failover workflow to restore DNS.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;Considering the workflow required thinking about which DNS needed to change, and manually selecting the right DNS and region options, the procedure took more like five steps. And despite automation for applying DNS changes and verifying pods, it became a drudgery to deploy anything.  &lt;/p&gt;

&lt;p&gt;Even worse, whenever we wanted to apply the change to multiple clusters, we’d have to repeat every step multiple times. &lt;/p&gt;

&lt;p&gt;This was counterproductive, inefficient, and discouraged us from deploying as frequently as we could have.&lt;/p&gt;

&lt;h2&gt;
  
  
  Eradicating the toil
&lt;/h2&gt;

&lt;p&gt;What we needed was a workflow to deploy everyday changes in one step, not &lt;em&gt;four or five&lt;/em&gt;, so we set out to build a new workflow that uses the same composite actions as the failover workflow, but makes better overall use of GitHub Actions' automation capabilities.&lt;/p&gt;

&lt;p&gt;First, since all production changes are deployed via pull request, instead of &lt;code&gt;workflow_dispatch&lt;/code&gt; we use &lt;a href="https://docs.github.com/en/actions/writing-workflows/choosing-when-your-workflow-runs/events-that-trigger-workflows#pull_request" rel="noopener noreferrer"&gt;pull request triggers&lt;/a&gt; based on branch, path, and event type.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight yaml"&gt;&lt;code&gt;&lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;Production deployment&lt;/span&gt;
&lt;span class="na"&gt;on&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
 &lt;span class="na"&gt;pull_request&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
   &lt;span class="na"&gt;branches&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
     &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="s"&gt;main&lt;/span&gt;
   &lt;span class="na"&gt;paths&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
     &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="s"&gt;path/to/region1/releases/namespace1/"&lt;/span&gt;
     &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="s"&gt;path/to/region1/releases/namespace2/"&lt;/span&gt;
     &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="s"&gt;path/to/region2/releases/namespace1/"&lt;/span&gt;
     &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="s2"&gt;"&lt;/span&gt;&lt;span class="s"&gt;path/to/region2/releases/namespace2/"&lt;/span&gt;
   &lt;span class="na"&gt;types&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
     &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="s"&gt;closed&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;We broke the new workflow down into 4 jobs, which correspond to the old manual steps.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Determine what changed.&lt;/li&gt;
&lt;li&gt;Make DNS change to stop traffic.&lt;/li&gt;
&lt;li&gt;Verify services’ pods roll out successfully&lt;/li&gt;
&lt;li&gt;Make DNS change to restore traffic.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;In the first job, we start by ensuring the workflow only proceeds upon &lt;em&gt;merged&lt;/em&gt; pull requests, and not just any pull request closed event, by adding this &lt;code&gt;if&lt;/code&gt; condition:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight yaml"&gt;&lt;code&gt;&lt;span class="na"&gt;job1&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
   &lt;span class="na"&gt;if&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;(github.event_name == 'pull_request') &amp;amp;&amp;amp; (github.event.pull_request.merged == &lt;/span&gt;&lt;span class="kc"&gt;true&lt;/span&gt;&lt;span class="s"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Unlike the failover workflow, the new workflow must automatically determine the right region and DNS to cut off. The &lt;a href="https://github.com/dorny/paths-filter" rel="noopener noreferrer"&gt;dorny paths-filter action&lt;/a&gt; was our help for this.&lt;/p&gt;

&lt;p&gt;We first use it to determine region based on change path:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight yaml"&gt;&lt;code&gt;     &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;Determine region&lt;/span&gt;
       &lt;span class="na"&gt;uses&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;actions/checkout@v4&lt;/span&gt;
     &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="na"&gt;uses&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;dorny/paths-filter@v3&lt;/span&gt;
       &lt;span class="na"&gt;id&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;region-filter&lt;/span&gt;
       &lt;span class="na"&gt;with&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
         &lt;span class="na"&gt;filters&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="pi"&gt;|&lt;/span&gt;
           &lt;span class="s"&gt;region-1: 'path/to/cluster/account/region1/**'&lt;/span&gt;
           &lt;span class="s"&gt;region-2: 'path/to/cluster/account/region2/**'&lt;/span&gt;

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Next, we have a filter for DNS, which is important to get right because the DNS we want to reroute will vary depending on which services change:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight yaml"&gt;&lt;code&gt;     &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;Determine DNS to change&lt;/span&gt;
       &lt;span class="na"&gt;uses&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;actions/checkout@v4&lt;/span&gt;
     &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="na"&gt;uses&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;dorny/paths-filter@v3&lt;/span&gt;
       &lt;span class="na"&gt;id&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;dns-filter&lt;/span&gt;
       &lt;span class="na"&gt;with&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
         &lt;span class="na"&gt;filters&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="pi"&gt;|&lt;/span&gt;
           &lt;span class="s"&gt;dns1: &lt;/span&gt;
             &lt;span class="s"&gt;- 'path/to/services/1'&lt;/span&gt;
             &lt;span class="s"&gt;- 'path/to/services/2'&lt;/span&gt;
           &lt;span class="s"&gt;dns2:&lt;/span&gt;
             &lt;span class="s"&gt;- 'path/to/services/3'&lt;/span&gt;
             &lt;span class="s"&gt;- 'path/to/services/4'&lt;/span&gt;
           &lt;span class="s"&gt;dns3:&lt;/span&gt;
             &lt;span class="s"&gt;- 'path/to/services/1'&lt;/span&gt;
             &lt;span class="s"&gt;- 'path/to/services/2'&lt;/span&gt;
           &lt;span class="s"&gt;dns4:&lt;/span&gt;
             &lt;span class="s"&gt;- 'path/to/services/1'&lt;/span&gt;
             &lt;span class="s"&gt;- 'path/to/services/2'&lt;/span&gt;
             &lt;span class="s"&gt;- 'path/to/services/5'&lt;/span&gt;
             &lt;span class="s"&gt;- 'path/to/services/6'&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The final filter determines which pods to validate, also based on which services have changed:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight yaml"&gt;&lt;code&gt;     &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;Determine services&lt;/span&gt;
       &lt;span class="na"&gt;uses&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;actions/checkout@v4&lt;/span&gt;
     &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="na"&gt;uses&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;dorny/paths-filter@v3&lt;/span&gt;
       &lt;span class="na"&gt;id&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;service-filter&lt;/span&gt;
       &lt;span class="na"&gt;with&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
         &lt;span class="na"&gt;filters&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="pi"&gt;|&lt;/span&gt;
           &lt;span class="s"&gt;service-1:&lt;/span&gt;
             &lt;span class="s"&gt;- path/to/services/1&lt;/span&gt;
           &lt;span class="s"&gt;service-2:&lt;/span&gt;
             &lt;span class="s"&gt;- path/to/services/2&lt;/span&gt;
           &lt;span class="s"&gt;service-3:&lt;/span&gt;
             &lt;span class="s"&gt;- path/to/services/3&lt;/span&gt;
           &lt;span class="s"&gt;service-4:&lt;/span&gt;
             &lt;span class="s"&gt;- path/to/services/4 &lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Finally, &lt;a href="https://docs.github.com/en/actions/writing-workflows/choosing-what-your-workflow-does/defining-outputs-for-jobs" rel="noopener noreferrer"&gt;job outputs&lt;/a&gt; are what makes all these filtered values available to downstream jobs.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight yaml"&gt;&lt;code&gt;   &lt;span class="na"&gt;outputs&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
     &lt;span class="na"&gt;dns&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;${{ steps.dns-filter.outputs.changes }}&lt;/span&gt;
     &lt;span class="na"&gt;services&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;${{ steps.service-filter.outputs.changes }}&lt;/span&gt;
     &lt;span class="na"&gt;region&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;${{ steps.region-filter.outputs.region-1 == 'true' &amp;amp;&amp;amp; 'region-1' || 'region-2' }}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The second job applies the DNS change, but includes a condition to only proceed if it finds values in the outputs for DNS and region.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight yaml"&gt;&lt;code&gt; &lt;span class="na"&gt;job2&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
   &lt;span class="na"&gt;needs&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="pi"&gt;[&lt;/span&gt; &lt;span class="nv"&gt;job1&lt;/span&gt; &lt;span class="pi"&gt;]&lt;/span&gt;
   &lt;span class="na"&gt;if&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;${{ needs.job1.outputs.dns != '[]' &amp;amp;&amp;amp; needs.job1.outputs.dns != '' &amp;amp;&amp;amp; needs.job1.outputs.region != '[]' &amp;amp;&amp;amp; needs.job1.outputs.region != '' }}&lt;/span&gt;
   &lt;span class="na"&gt;strategy&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
     &lt;span class="na"&gt;matrix&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
       &lt;span class="na"&gt;dns&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;${{ fromJSON(needs.job1.outputs.dns) }}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;It calls the same composite action as the failover procedure:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight yaml"&gt;&lt;code&gt;   &lt;span class="na"&gt;steps&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
     &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="na"&gt;uses&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;actions/checkout@v4&lt;/span&gt;
     &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;Stop traffic to ${{ needs.job1.outputs.region }} ${{ matrix.dns }}&lt;/span&gt;
       &lt;span class="na"&gt;uses&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s1"&gt;'&lt;/span&gt;&lt;span class="s"&gt;./.github/actions/dns-change'&lt;/span&gt;
       &lt;span class="na"&gt;with&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
         &lt;span class="na"&gt;dns&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;${{ matrix.dns }}&lt;/span&gt;
         &lt;span class="na"&gt;action&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;stop&lt;/span&gt;
         &lt;span class="na"&gt;region&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;${{ needs.job1.outputs.region }}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The third job verifies pods roll out, applying the values from the &lt;code&gt;services&lt;/code&gt; output to a matrix:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight yaml"&gt;&lt;code&gt;&lt;span class="na"&gt;job3&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
   &lt;span class="na"&gt;needs&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="pi"&gt;[&lt;/span&gt; &lt;span class="nv"&gt;job1&lt;/span&gt;&lt;span class="pi"&gt;,&lt;/span&gt; &lt;span class="nv"&gt;job2&lt;/span&gt; &lt;span class="pi"&gt;]&lt;/span&gt;
   &lt;span class="na"&gt;if&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;${{ needs.job1.outputs.services != '[]' &amp;amp;&amp;amp; needs.job1.outputs.services != '' }}&lt;/span&gt;
   &lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;Validate pods&lt;/span&gt;
   &lt;span class="na"&gt;strategy&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
     &lt;span class="na"&gt;matrix&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
       &lt;span class="na"&gt;service&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;${{ fromJSON(needs.job1.outputs.services) }}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;And calling the composite action to execute the pod validation steps:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight yaml"&gt;&lt;code&gt;&lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="na"&gt;uses&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;actions/checkout@v4&lt;/span&gt;
     &lt;span class="s"&gt;- name&lt;/span&gt;&lt;span class="err"&gt;:&lt;/span&gt; &lt;span class="s"&gt;validate deployments and pods&lt;/span&gt;
       &lt;span class="s"&gt;uses&lt;/span&gt;&lt;span class="err"&gt;:&lt;/span&gt; &lt;span class="s1"&gt;'&lt;/span&gt;&lt;span class="s"&gt;./.github/actions/pod-validation'&lt;/span&gt;
       &lt;span class="na"&gt;with&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
         &lt;span class="na"&gt;deployment&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;${{ matrix.service }}&lt;/span&gt;
         &lt;span class="na"&gt;cluster&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;${{ needs.job1.outputs.region == region-1' &amp;amp;&amp;amp; '1' || '2' }}&lt;/span&gt;

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;If every pod rolls out successfully, the workflow proceeds to restore the traffic cut off in job 2.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight yaml"&gt;&lt;code&gt; &lt;span class="na"&gt;job4&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
   &lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;Restore traffic to ${{ needs.determine-changes.outputs.region }} in ${{ matrix.dns }}&lt;/span&gt;
   &lt;span class="na"&gt;strategy&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
     &lt;span class="na"&gt;matrix&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
       &lt;span class="na"&gt;dns&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;${{ fromJSON(needs.job1.outputs.dns) }}&lt;/span&gt;
   &lt;span class="na"&gt;steps&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
     &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="na"&gt;uses&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;actions/checkout@v4&lt;/span&gt;
     &lt;span class="pi"&gt;-&lt;/span&gt; &lt;span class="na"&gt;name&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;Restore traffic to ${{ needs.job1.outputs.region }} ${{ matrix.dns }}&lt;/span&gt;
       &lt;span class="na"&gt;uses&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s1"&gt;'&lt;/span&gt;&lt;span class="s"&gt;./.github/actions/dns-change'&lt;/span&gt;
       &lt;span class="na"&gt;with&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt;
         &lt;span class="na"&gt;dns&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;${{ matrix.dns }}&lt;/span&gt;
         &lt;span class="na"&gt;action&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;start&lt;/span&gt;
         &lt;span class="na"&gt;region&lt;/span&gt;&lt;span class="pi"&gt;:&lt;/span&gt; &lt;span class="s"&gt;${{ needs.job1.outputs.region }}&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;If any step fails, the workflow fails and traffic remains routed away from the failed cluster while the team investigates.  If necessary, we can open a pull request to revert the change. Merging it will trigger the workflow again, effectively validating the rollback.&lt;/p&gt;

&lt;h2&gt;
  
  
  Success!
&lt;/h2&gt;

&lt;p&gt;By combining the composite actions we created for the failover workflow with path filters and job outputs into a new workflow, deployments now take one manual step: merging a pull request.&lt;/p&gt;

&lt;p&gt;The workflow takes over from there, automatically making the proper DNS changes, verifying impacted pods roll out, restoring DNS traffic, and notifying us of results.&lt;/p&gt;

&lt;p&gt;Unburdened by multiple manual steps, our team deployed 32 changes to production in the first month of using the workflow. In the previous month, we deployed 17 changes.  The results so far have been promising, and we'll continue looking for ways to make our release practices even better with Actions.&lt;/p&gt;

</description>
      <category>githubactions</category>
      <category>automation</category>
      <category>devops</category>
      <category>productivity</category>
    </item>
    <item>
      <title>What Idiot Wrote This Code? ...Oh It Was Me</title>
      <dc:creator>Alex Micksch</dc:creator>
      <pubDate>Fri, 09 Aug 2024 22:46:53 +0000</pubDate>
      <link>https://dev.to/devsatasurion/what-idiot-wrote-this-code-oh-it-was-me-46c9</link>
      <guid>https://dev.to/devsatasurion/what-idiot-wrote-this-code-oh-it-was-me-46c9</guid>
      <description>&lt;p&gt;Entering this world as a Level 1 engineer, I soon realized that my ambition was greater than my knowledge - a humbling part of my growth. The first big project I took on was creating a snapshot of our production database cluster for use in lower environments. This process involved creating a copy of the production cluster into a temp DB, anonymizing customer data, updating api keys and passwords, and then generating a snapshot that was ready to be used by developers and QA testers. At the time, it was a massive undertaking, and I was eager to prove myself. Now, looking back, I can see there were many things I could have done better with how much I've learned since then. Could I have anticipated these improvements ahead of time? In some cases, yes, though I lacked the skills to implement it. But in others, it was experience that guided my progress.&lt;/p&gt;

&lt;p&gt;The process I developed was functional, but fragile. Any small error would require manual intervention, which made the process less reliable. Still, it worked - albeit just barely. It was a delicate machine that could break down if someone so much as looked at it. During this period, our team began to focus heavily on a new project, and time/energy/motivation to return to this original project became scarce. Manual workarounds, while inefficient, were the most effective solution. But as the inefficiencies piled up, so did my mental list of tech debt. Finally, I reached a point where I had enough and decided to revisit my once biggest achievement turned my now biggest headache. I had a list of issues to work on:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;What to do with the temp DB's that were generated if the process failed overnight? At the time, I was just deleting them and restarting the process. But this was... not great.&lt;/li&gt;
&lt;li&gt;Next was the time it took to add the encryption key to the snapshot. Initially it took about 10 minutes, but over time, that ballooned to nearly 45 minutes. When I consulted AWS support, their suggestion was to "just increase the sleep." While this was a quick fix, it didn’t address the root of the problem.&lt;/li&gt;
&lt;li&gt;Sometimes the DB would reject the connection while it was running my laundry list of SQL queries. This would cause the job to return an error code and fail outright. Ugh.&lt;/li&gt;
&lt;li&gt;Most importantly, this job is shared between multiple applications. This was one of the main reasons why it was so fragile. Should I separate it out into a different job per application?&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;When I set out to revisit this project, I had an epiphany. It was like coming back to the video game you struggled with six months ago and beating it on the first try. Every day, you make small improvements that seem insignificant on a day-to-day basis, but over time they accumulate. When I started working on the project again I realized how much I had grown. Not just in my technical skills, but in my approach to problem-solving. Here's how I went about it:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;For the orphaned temp DB's: Reuse them! While I created some logic around the rest of the process to make it more resilient, if the job had failed and left around the temp DB's, just reuse them and start the job from the steps after they would get created. Hindsight is 20/20, etc, but I for whatever reason I couldn't see it my first time around.&lt;/li&gt;
&lt;li&gt;The encryption key time... Admittedly I still haven't found an answer for this. And AWS support was never able to provide me with a clear answer as to why this happened. In the end, I increased the sleep time to compensate for this mysterious time increase, but I pray in the future I will gain additional knowledge that will grant me an "aha!" moment if I come back around.&lt;/li&gt;
&lt;li&gt;I'm still unsure why the DB randomly rejects the SQL connection. But for now I've added a catch and retry. A good solution doesn't have to be complicated!&lt;/li&gt;
&lt;li&gt;After considering whether to split out the job for each application, I decided to stick to my guns and share the same job file between our three apps. I think splitting it up would be easier, but this gives me a self-enforced challenge to work into my development. And with my increased experience and skills, I was able to make it work.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Looking back, I can clearly see what my original implementation was lacking. But for a long time, other tasks and complacency with manual workarounds kept me from addressing them. Once I decided to revisit it, I was amazed at how quickly I was able to come up with solutions for my prior shortcomings. Just a few days of work and testing compared to the drawn-out struggle I had faced before. The experience was a powerful reminder of how much I had grown. Not just in my technical ability, but also in my confidence and approach to problem-solving. This project, which for a long time seemed so daunting, now serves as a marker of my progress.&lt;/p&gt;

&lt;p&gt;In conclusion, my encouragement to you dear reader, is to revisit that old project you know could be better. The one you worked on so long ago. You may not realize it now, but once you start looking at how you can improve it you'd be surprised at how far you've come! &lt;/p&gt;

</description>
    </item>
    <item>
      <title>Software Design Principles in Note-taking</title>
      <dc:creator>Mark Castillo</dc:creator>
      <pubDate>Fri, 09 Aug 2024 11:25:36 +0000</pubDate>
      <link>https://dev.to/devsatasurion/software-design-principles-in-note-taking-3p6h</link>
      <guid>https://dev.to/devsatasurion/software-design-principles-in-note-taking-3p6h</guid>
      <description>&lt;p&gt;Those of us who've been writing code for some time have likely applied these design principles in our work. These help our code become clear and readable - maintainable. It helps collaborators (and your future self) better understand your creation.&lt;/p&gt;

&lt;p&gt;I started to entertain strategies for note-taking when I realized that it was time to stop dumping all of my notes into Notepad and start compiling and organizing them into something that sentient beings could understand. However, those that I've read were mostly geared towards capturing ideas (for book writing, graduate studies, etc.)&lt;/p&gt;

&lt;p&gt;And so I thought, "I'm familiar with principles to write clean code... could I apply those to my notes, maybe?" I've found success in translating these into note-taking. As I share them with you, I hope you do too.&lt;/p&gt;




&lt;h2&gt;
  
  
  Single Responsibility Principle
&lt;/h2&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;em&gt;"A class, method, or function should only have one responsibility."&lt;/em&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;In line with it's traditional definition, each note or page should contain only one focal idea or purpose. The main goal: don't dump everything on a single document. Give each major component an island of their own.&lt;/p&gt;

&lt;p&gt;Using application support as an example - responsibilities include supporting weekly requirements and troubleshooting of reported issues. Respectively, I've organized my notes as such:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Deployment Steps&lt;/strong&gt; - a detailed, step-by-step guide on how to do the deployment. Screenshots and all.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Troubleshooting&lt;/strong&gt; - the first aid kit. A compilation of valid, known, and even weird issues encountered and how they were solved. This comes in handy especially when someone else performed the resolution.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Overview&lt;/strong&gt; - the page that ties them all together. Contains top-level information like the AWS account and region, access requirements, relevant URLs, plus it references the Deployment Steps and Troubleshooting pages.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Looks something like this:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fpe8h0r7re8y6hgjgobw6.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fpe8h0r7re8y6hgjgobw6.jpg" alt="SRP visual" width="671" height="210"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;You might think that having separate pages for each topic would be counterproductive in the long run, but it's actually the opposite. I know exactly where something is. No more guessing which piece contains what information. It also makes everything shareable and easier to build on to.&lt;/p&gt;




&lt;h2&gt;
  
  
  Open-Close Principle
&lt;/h2&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;em&gt;"Entities should be open to extension, but closed to modification."&lt;/em&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Chain your notes together, but don't weld them. Build them up as if you were making notes using pen and paper - give each idea or article, no matter how small, it's own space to grow. Then make use of links to connect the dots, like the choose-your-own-adventure books of old.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fszmbu5yj3aju6j6f077p.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fszmbu5yj3aju6j6f077p.jpg" alt="charlie conspiracy meme" width="425" height="319"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;It could look something like this - let's say you have an application issue that's been a pain point for quite some time. And so, you add it to your wish list of improvements. Fast forward in time, you're writing about what's shiny and new in the enhancement's you've made and the story behind it.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fyze37emtoax9ic5pwpez.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fyze37emtoax9ic5pwpez.jpg" alt="OCP visual" width="561" height="441"&gt;&lt;/a&gt;&lt;/p&gt;




&lt;h2&gt;
  
  
  Don't Repeat Yourself
&lt;/h2&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;em&gt;"Every piece of knowledge must have a single, unambiguous, authoritative representation within a system."&lt;/em&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Your mileage may vary on this one as it depends on your use case. But the idea is to link your notes whenever you can.&lt;/p&gt;

&lt;p&gt;One possible use of this could be: you encounter an issue or error that has the same nature as one that you've encountered and/or resolved before. When you get around to documenting, instead of writing everything down again from scratch, you could just make a reference to the existing document.&lt;/p&gt;




&lt;h2&gt;
  
  
  Bonus: Single Source of Truth
&lt;/h2&gt;

&lt;blockquote&gt;
&lt;p&gt;&lt;em&gt;"There should be one definitive data repository that all users and systems refer to."&lt;/em&gt;&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;This is more a personal preference of mine. Having a "master copy" of my notes in one place eliminates the mental load of having to keep track of what is where. Gone are the days of &lt;em&gt;Did I have that in Confluence? OneNote? Or was it in Slack Canvas?&lt;/em&gt; 😬&lt;/p&gt;

&lt;p&gt;I like to use Obsidian. All of the notes I keep and its revisions go through there first before being shared anywhere else. I find it convenient to have the updated copy within reach, as the ones in Confluence or even GitHub can fall behind when I jump from project to project.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fyacc4mkqovxwdpvfl7mh.jpg" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fyacc4mkqovxwdpvfl7mh.jpg" alt="SSoT stock image" width="800" height="278"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;But!&lt;/strong&gt; Having a single source of truth does not mean that you should limit yourself to a single tool. Go with whichever you fancy the most, but there's no one app to rule them all; use the right tool for the right job. I use a combination of Logseq and Obsidian as they both use markdown formatting - Obsidian excels in long-form notes whereas Logseq excels in short-form (bulleted, quick notes and to-do lists).&lt;/p&gt;




&lt;p&gt;Note-taking is not much different from any other skill we learn. And it's tools are the equivalent of an IDE. Pick the one that works with your style and you end up with a second brain that works for you.&lt;/p&gt;



&lt;h6&gt;
  
  
  &lt;em&gt;Related: &lt;a href="https://zettelkasten.de/introduction/" rel="noopener noreferrer"&gt;Zettelkasten Method&lt;/a&gt;&lt;/em&gt;
&lt;/h6&gt;

</description>
      <category>learning</category>
      <category>productivity</category>
    </item>
    <item>
      <title>Create your own Kubernetes "kind:"</title>
      <dc:creator>raymundmelvinchua-github</dc:creator>
      <pubDate>Thu, 08 Aug 2024 15:25:04 +0000</pubDate>
      <link>https://dev.to/devsatasurion/create-your-own-kubernetes-kind-1n9o</link>
      <guid>https://dev.to/devsatasurion/create-your-own-kubernetes-kind-1n9o</guid>
      <description>&lt;p&gt;Imagine each Kube object is a unique dinosaur specie and you're a novice Kube user/operator or a seasoned Kube application developer. &lt;/p&gt;

&lt;p&gt;The term "KIND" would have a double connotation:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;it could mean the your shortcut framework to create a Kube cluster inside Docker... or&lt;/li&gt;
&lt;li&gt;it may mean creating your own Kube YAML "KIND:" objective.&lt;/li&gt;
&lt;li&gt;it could mean a specific KIND of dinosaur.  Just joking.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;But you, as my reader here in Dev.to, will not be indulged by run-of-the-mill tips and tricks.  You want more action and value... you want something to showcase to your senior colleagues that Kubernetes can indeed be extended by writing your own Kube API objects.  &lt;/p&gt;

&lt;p&gt;So by choosing the second bullet above, all are possible by leveraging the Kubernetes API's CRD: "&lt;strong&gt;Custom Resource Definition&lt;/strong&gt;".  Let's discuss that second bullet above and create your own KIND of dinosaur... I mean Kube Object ! &lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F2jimfjicbol4014wbaea.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F2jimfjicbol4014wbaea.png" alt="Image description" width="214" height="215"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Use Case!  Create your new kind of dinosaur!
&lt;/h2&gt;

&lt;p&gt;To demonstrate the WHY and the HOW of CRD's, let us imagine these points in your Kube cluster:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;you need multiple ingressControllers to avoid single point of failures.&lt;/li&gt;
&lt;li&gt;you need unique ingressClasses that correspond to each ingressController mentioned above, to avoid traffic route mixing.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;For our solution, you want to use a CRD as a "&lt;em&gt;wrapper&lt;/em&gt;" of sorts, so you can "bootstrap" multiple Kube objects in one go, at the same time give the user some freedom to enforce UNIQUENESS by making some Kube metadata &lt;u&gt;configurable&lt;/u&gt;.&lt;/p&gt;

&lt;h3&gt;
  
  
  Diagram flow
&lt;/h3&gt;

&lt;p&gt;So here's the flow of how the CRD will work:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F9nw587815nvpwohur5ji.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F9nw587815nvpwohur5ji.png" alt="Image description" width="800" height="222"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Above image illustrates how a CRD would act as a bootstrap with configurable metadata.&lt;/p&gt;

&lt;h2&gt;
  
  
  To start off, imagine these steps:
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fvyf30jy4p1oghehhdiur.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fvyf30jy4p1oghehhdiur.gif" alt="Image description" width="800" height="600"&gt;&lt;/a&gt;&lt;/p&gt;




&lt;h4&gt;
  
  
  STEP 1
&lt;/h4&gt;




&lt;p&gt;Prepare your consolidated YAML file that contains all needed components for your &lt;strong&gt;ingress-controller&lt;/strong&gt; &amp;amp; &lt;strong&gt;ingressClass&lt;/strong&gt; pattern:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;apiVersion: v1
kind: Service
metadata:
  annotations:
    service.beta.kubernetes.io/aws-load-balancer-backend-protocol: tcp
    service.beta.kubernetes.io/aws-load-balancer-cross-zone-load-balancing-enabled: "true"
    service.beta.kubernetes.io/aws-load-balancer-type: nlb
    service.beta.kubernetes.io/aws-load-balancer-internal: "true"
  labels:
    app.kubernetes.io/component: controller
    app.kubernetes.io/instance: ingress-nginx
    app.kubernetes.io/name: primary-ingress-nginx
    app.kubernetes.io/part-of: ingress-nginx
    app.kubernetes.io/version: 1.1.3
  name: primary-ingress-nginx-controller
spec:
  externalTrafficPolicy: Local
  ports:
  - appProtocol: http
    name: http
    port: 80
    protocol: TCP
    targetPort: http
  - appProtocol: https
    name: https
    port: 443
    protocol: TCP
    targetPort: https
  selector:
    app.kubernetes.io/component: controller
    app.kubernetes.io/instance: ingress-nginx
    app.kubernetes.io/name: primary-ingress-nginx
  type: LoadBalancer
---
apiVersion: v1
kind: Service
metadata:
  labels:
    app.kubernetes.io/component: controller
    app.kubernetes.io/instance: ingress-nginx
    app.kubernetes.io/name: primary-ingress-nginx
    app.kubernetes.io/part-of: ingress-nginx
    app.kubernetes.io/version: 1.1.3
  name: primary-ingress-nginx-controller-admission
spec:
  ports:
  - appProtocol: https
    name: https-webhook
    port: 443
    targetPort: webhook
  selector:
    app.kubernetes.io/component: controller
    app.kubernetes.io/instance: ingress-nginx
    app.kubernetes.io/name: primary-ingress-nginx
  type: ClusterIP
---
apiVersion: apps/v1
kind: Deployment
metadata:
  labels:
    app.kubernetes.io/component: controller
    app.kubernetes.io/instance: ingress-nginx
    app.kubernetes.io/name: primary-ingress-nginx
    app.kubernetes.io/part-of: ingress-nginx
    app.kubernetes.io/version: 1.1.3
  name: primary-ingress-nginx-controller
spec:
  replicas: 2
  minReadySeconds: 0
  revisionHistoryLimit: 10
  selector:
    matchLabels:
      app.kubernetes.io/component: controller
      app.kubernetes.io/instance: ingress-nginx
      app.kubernetes.io/name: primary-ingress-nginx
  template:
    metadata:
      labels:
        app.kubernetes.io/component: controller
        app.kubernetes.io/instance: ingress-nginx
        app.kubernetes.io/name: primary-ingress-nginx
    spec:
      containers:
      - args:
        - /nginx-ingress-controller
        - --publish-service=kube-system/primary-ingress-nginx-controller
        - --election-id=ingress-controller-leader
        - --controller-class=k8s.io/ingress-nginx
        - --ingress-class=primary-ingress-nginx-class
        - --configmap=kube-system/primary-ingress-nginx-controller
        - --validating-webhook=:8443
        - --validating-webhook-certificate=/usr/local/certificates/cert
        - --validating-webhook-key=/usr/local/certificates/key
        env:
        - name: POD_NAME
          valueFrom:
            fieldRef:
              fieldPath: metadata.name
        - name: POD_NAMESPACE
          valueFrom:
            fieldRef:
              fieldPath: metadata.namespace
        - name: LD_PRELOAD
          value: /usr/local/lib/libmimalloc.so
        image: k8s.gcr.io/ingress-nginx/controller:v1.1.1
        imagePullPolicy: IfNotPresent
        lifecycle:
          preStop:
            exec:
              command:
              - /wait-shutdown
        livenessProbe:
          failureThreshold: 5
          httpGet:
            path: /healthz
            port: 10254
            scheme: HTTP
          initialDelaySeconds: 10
          periodSeconds: 10
          successThreshold: 1
          timeoutSeconds: 1
        name: controller
        ports:
        - containerPort: 80
          name: http
          protocol: TCP
        - containerPort: 443
          name: https
          protocol: TCP
        - containerPort: 8443
          name: webhook
          protocol: TCP
        readinessProbe:
          failureThreshold: 3
          httpGet:
            path: /healthz
            port: 10254
            scheme: HTTP
          initialDelaySeconds: 10
          periodSeconds: 10
          successThreshold: 1
          timeoutSeconds: 1
        resources:
          limits:
            memory: 1Gi
          requests:
            cpu: 100m
            memory: 90Mi
        securityContext:
          allowPrivilegeEscalation: true
          capabilities:
            add:
            - NET_BIND_SERVICE
            drop:
            - ALL
          runAsUser: 101
        volumeMounts:
        - mountPath: /usr/local/certificates/
          name: webhook-cert
          readOnly: true
      dnsPolicy: ClusterFirst
      nodeSelector:
        kubernetes.io/os: linux
      serviceAccountName: primary-ingress-nginx
      terminationGracePeriodSeconds: 300
      volumes:
      - name: webhook-cert
        secret:
          secretName: primary-ingress-nginx-admission
      affinity:
        nodeAffinity:
          requiredDuringSchedulingIgnoredDuringExecution:
            nodeSelectorTerms:
            - matchExpressions:
              - key: dedicated
                operator: In
                values:
                - essentials
      tolerations:
        - key: dedicated
          operator: Equal
          value: essentials
---
apiVersion: networking.k8s.io/v1
kind: IngressClass
metadata:
  labels:
    app.kubernetes.io/component: controller
    app.kubernetes.io/instance: ingress-nginx
    app.kubernetes.io/name: primary-ingress-nginx
    app.kubernetes.io/part-of: ingress-nginx
    app.kubernetes.io/version: 1.1.3
  name: primary-ingress-nginx-class
spec:
  controller: k8s.io/ingress-nginx
---
apiVersion: admissionregistration.k8s.io/v1
kind: ValidatingWebhookConfiguration
metadata:
  labels:
    app.kubernetes.io/component: admission-webhook
    app.kubernetes.io/instance: ingress-nginx
    app.kubernetes.io/name: primary-ingress-nginx
    app.kubernetes.io/part-of: ingress-nginx
    app.kubernetes.io/version: 1.1.3
  name: primary-ingress-nginx-admission
webhooks:
- admissionReviewVersions:
  - v1
  clientConfig:
    service:
      name: primary-ingress-nginx-controller-admission
      namespace: kube-system
      path: /networking/v1/ingresses
  failurePolicy: Fail
  matchPolicy: Equivalent
  name: validate.nginx.ingress.kubernetes.io
  rules:
  - apiGroups:
    - networking.k8s.io
    apiVersions:
    - v1
    operations:
    - CREATE
    - UPDATE
    resources:
    - ingresses
  sideEffects: None

&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  The value of using CRDs
&lt;/h3&gt;

&lt;p&gt;In above YAML example, we consolidated 2 Kube SVC objects, alongside a DEPLOYMENT object and an ingressClass object.&lt;/p&gt;

&lt;p&gt;But at his point you may be thinking?  I can simply &amp;amp; easily instantiate these  objects using above consolidated YAML.  So why need CRD?  &lt;/p&gt;

&lt;p&gt;That is a valid concern!  However, the value of CRD comes when you want to have metadata configurable prior to object instantiation.  &lt;/p&gt;

&lt;p&gt;Imagine the challenge of externalizing the metadata  "&lt;em&gt;&lt;strong&gt;ingress-nginx&lt;/strong&gt;&lt;/em&gt;"?  How would you make a single configurable item for this?  Does that mean you have to refactor your consolidated YAML each time you need to implement this pattern?  Kind of time-consuming and prone to human errors.&lt;/p&gt;

&lt;p&gt;For our use case, we want to externalize these three metadata, to make it user-defined:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;app.kubernetes.io/instance: ingress-nginx&lt;/li&gt;
&lt;li&gt;app.kubernetes.io/part-of: ingress-nginx&lt;/li&gt;
&lt;li&gt;name: primary-ingress-nginx-*&lt;/li&gt;
&lt;/ul&gt;




&lt;h4&gt;
  
  
  STEP 2
&lt;/h4&gt;

&lt;h2&gt;
  
  
  Define the Custom Resource Definition itself:
&lt;/h2&gt;



&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
  name: ingresscontrollerclass.example.com
spec:
  group: example.com
  versions:
    - name: v1
      served: true
      storage: true
      schema:
        openAPIV3Schema:
          type: object
          properties:
            spec:
              type: object
              properties:
                instanceName:
                  type: string
                partOf:
                  type: string
                name:
                  type: string
                replicas:
                  type: integer
                ingressClassName:
                  type: string
                serviceAnnotations:
                  type: object
  scope: Namespaced
  names:
    plural: ingresscontrollerclass
    singular: ingresscontrollerclass
    kind: IngressControllerClass
    shortNames:
      - icc
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;There are alot of conceptual attributes to introduce in above example, but I have faith in your capacity to associate new stuff with your stock knowledge.  Here, you are instantiating a widely accepted Kubernetes object of  "&lt;strong&gt;kind: CustomResourceDefinition&lt;/strong&gt;".&lt;/p&gt;

&lt;p&gt;But the more critical attributes we need to introduce here, the mechanism to externalize the needed metadata, defined here as object properties:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;     properties:
    instanceName:
      type: string
    partOf:
      type: string
    name:
      type: string
        ingressClassName:
          type: string

        # extra properties:
    replicas:
          type: integer
        serviceAnnotations:
          type: object
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;The crucial stuff to &lt;em&gt;externalize&lt;/em&gt; here are &lt;strong&gt;&lt;em&gt;instanceName, partOf, name and ingressClassName&lt;/em&gt;&lt;/strong&gt; because these properties enforce &lt;em&gt;uniqueness&lt;/em&gt; of ingress-controllers and their corresponding ingress classes.  The extra properties are nice to have but are still helpful.&lt;/p&gt;




&lt;h3&gt;
  
  
  Step 3: Create your very own Kube KIND (Custom Resource)!
&lt;/h3&gt;




&lt;p&gt;So here's the reason why you need a CRD, because you need a hard pattern so users can create a "Custom Resource".&lt;/p&gt;

&lt;p&gt;After instantiating your CRD, feel free to create your very own customized Kube Kind --&amp;gt; kind: IngressControllerClass&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;apiVersion: example.com/v1
kind: IngressControllerClass
metadata:
  name: my-nginx-ingress-setup
spec:
  instanceName: "melvin-nginx"
  partOf: "melvin-nginx"
  name: "melvin-ingress-nginx"
  replicas: 2
  ingressClassName: "melvin-ingress-nginx-class"
  serviceAnnotations:
    service.beta.kubernetes.io/aws-load-balancer-backend-protocol: tcp
    service.beta.kubernetes.io/aws-load-balancer-cross-zone-load-balancing-enabled: "true"
    service.beta.kubernetes.io/aws-load-balancer-type: nlb
    service.beta.kubernetes.io/aws-load-balancer-internal: "true"
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;^&lt;br&gt;
As you can see in the "spec" part of your new YAML KIND, the operator now has the freedom to define the name of the new ingress controller,  with corresponding ingress class name and associated metadata.&lt;/p&gt;

&lt;p&gt;That way, the CRD enforces tight coupling, thereby ensuring that the resulting ingress-controller and ingressClass will be tighty associated with each other and enforce uniqueness from other parallel implementations.&lt;/p&gt;

&lt;p&gt;A proper Kube coupling like the image below:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fik1uxtltxjuqdluv3i0m.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fik1uxtltxjuqdluv3i0m.png" alt="Image description" width="800" height="333"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;If you like this article, tell my boss to buy me a coffee! =)&lt;br&gt;
~&lt;/p&gt;

</description>
    </item>
    <item>
      <title>Cost Effective Way of Travelling in the “Cloud”- Quite Literally!!</title>
      <dc:creator>Saikrishna Annavajjula</dc:creator>
      <pubDate>Wed, 07 Aug 2024 19:21:16 +0000</pubDate>
      <link>https://dev.to/devsatasurion/cost-effective-way-of-travelling-in-the-cloud-quite-literally-4hb6</link>
      <guid>https://dev.to/devsatasurion/cost-effective-way-of-travelling-in-the-cloud-quite-literally-4hb6</guid>
      <description>&lt;p&gt;I came to realize recently that, similarities between cloud computer and award traveling is quite intriguing. As we delve into these realms, we'll uncover how meticulous planning and critical thinking can harness maximum benefits, be it through optimizing credit card points for travel enthusiasts or choosing the perfect AWS services for tech-savvy professionals. Join me as I draw insightful parallels between these seemingly disparate worlds. &lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fwdm3csf45pqp3q6sne41.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fwdm3csf45pqp3q6sne41.png" alt="Hold on.. lets go in to the details.." width="225" height="225"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;The Art of Point Transfers in Award Travel&lt;/strong&gt;&lt;br&gt;
In the realm of award travel, savvy individuals don't merely redeem credit card points for flights or hotel stays. Instead, they leverage the power of point transfers to enhance the value derived from each point spent. This often involves transferring points to airline loyalty programs or even to partner airlines, where the value per point can be significantly higher than redeeming points directly with the issuing airline.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Drawing Parallels in AWS&lt;/strong&gt;&lt;br&gt;
Similarly, in AWS, the journey towards cost optimization extends beyond a simple choice between EC2 instances and other services. Just as travelers explore various avenues to increase the value of their points, AWS users should consider a broader range of services and configurations to tailor their infrastructure to specific needs and budgets.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fom88bk2fyqcr2uk9xvne.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fom88bk2fyqcr2uk9xvne.png" alt="Let me breakdown a scenario" width="275" height="183"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  AWARD TRAVEL
&lt;/h2&gt;

&lt;p&gt;Lets assume you have a requirement to embark on a seamless journey from &lt;strong&gt;Washington DC to Alaska&lt;/strong&gt; with a &lt;strong&gt;direct flight&lt;/strong&gt;, departing from an airport of your choice on your chosen dates.&lt;/p&gt;

&lt;p&gt;Lets look in to our options.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Cash&lt;/strong&gt;
You can take an easy route by spending some $$$ book the most convenient flight..The simplest way to travel with least amount of effort.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fsnjx4xz7xb32leukhgsi.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fsnjx4xz7xb32leukhgsi.png" alt="Image description" width="358" height="344"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;CreditCard points&lt;/strong&gt;
Perhaps you're hesitant to spend actual money and would rather utilize credit card points instead. This way, you're not directly spending cash. It requires some effort in strategic planning and selecting a card that offers a superior sign-on bonus. Based on 1 cents per point valuation, you will need 43,000 points. &lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F0mypmroydre9mtcizacq.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F0mypmroydre9mtcizacq.png" alt="Image description" width="800" height="931"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Airline points&lt;/strong&gt;
May be you do a bit more discovery work and found out that you get even better value if you transfer to airlines which is your credit card’s preferred travel partner. We now need 15K points to travel. Now compare with above two options and this seems to be the cheapest option, yielding us 2.86 cents per chase point.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F19qanirwjalaa9vbd9gi.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F19qanirwjalaa9vbd9gi.png" alt="Image description" width="580" height="434"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;You are not done yet.... more research gives you even better value.&lt;/em&gt;&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Partner airline points&lt;/strong&gt;
By transferring the credit card points to a partner airline of united airline, you will travel in same united flight and an exact itinerary. But you only spend 10K points one way. Which yields you a whopping 4.3 Cents value per creditcard point spent. &lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fcnv87m6nvns6ekuird5o.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fcnv87m6nvns6ekuird5o.png" alt="Image description" width="800" height="364"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Conclusion:&lt;/strong&gt; By employing strategic thinking, you can optimize the value derived from your credit card points. Utilizing credit card points instead of cash may seem economical; however, maximizing their potential by transferring them to airlines or partner airlines could yield greater benefits.&lt;/p&gt;




&lt;p&gt;&lt;em&gt;Lets draw some parallels..&lt;/em&gt;&lt;/p&gt;




&lt;h2&gt;
  
  
  AWS SERVICES
&lt;/h2&gt;

&lt;p&gt;Lets assume you have a requirement of running a web application that processes user requests and performs lightweight data transformations. This application experiences variable traffic, peaking during business hours and dropping significantly overnight.&lt;/p&gt;

&lt;p&gt;Example Workload Specifications:&lt;br&gt;
CPU Usage: 1 vCPU&lt;br&gt;
Memory Usage: 2 GB RAM&lt;br&gt;
Traffic Pattern: Variable, with peaks during business hours&lt;br&gt;
Monthly Traffic Volume: Approximately 500,000 requests&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;strong&gt;EC2 INSTANCES&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;&lt;em&gt;On-Demand&lt;/em&gt;&lt;/strong&gt;&lt;br&gt;
Probably an easiest and least effort way to spin up and configure your application. Go to console launch and EC2 and configure your app...&lt;br&gt;
$0.092 per Hour for t3.medium instance = ~$66/month (assuming full month usage).&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;strong&gt;&lt;em&gt;Reserved&lt;/em&gt;&lt;/strong&gt;&lt;br&gt;
Perhaps you're hesitant about investing heavily and creating a single point of failure. In that case, consider applying some planning ahead to configure your application to operate on an reserved instance, allowing for not spending as much as on-demand.&lt;br&gt;
Using EC2 Reserved Instances (1-year term): Assume 40% savings over On-Demand = ~$39.6/month&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;CONTAINERIZE&lt;/strong&gt;
May be you do a bit more discovery work and found out that you can run the same workload in a container running on EKS or ECS and get high availability and scaling.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F1pfryxfwoe9m1ede9klm.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/cdn-cgi/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F1pfryxfwoe9m1ede9klm.png" alt="Image description" width="290" height="174"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Containerize your app and running on ECS/EKS Fargate: &lt;br&gt;
$0.04048 per vCPU-Hour + $0.004445 per GB-Hour = ~$58/month (estimation)&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;SERVERLESS&lt;/strong&gt;
May be you dont want to build a container or maintain an EC2 but you still want to run it as efficiently as it is but even cheaper. &lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Assume average execution time of 200ms per request at 128MB memory = $0.00001667 per GB-second + $0.20 per million requests = ~$12/month (estimation)&lt;/p&gt;

&lt;h2&gt;
  
  
  &lt;strong&gt;Analysis and Recommendations&lt;/strong&gt;
&lt;/h2&gt;

&lt;p&gt;&lt;strong&gt;Cost Efficiency:&lt;/strong&gt; For variable workloads with significant traffic fluctuations, Lambda offers the most cost-efficient option due to its pay-per-use model, charging only for actual execution time and memory used.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Predictable Workloads:&lt;/strong&gt; For applications with predictable, steady-state workloads, committing to EC2 Reserved Instances can offer substantial savings compared to On-Demand pricing.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Flexibility vs. Cost:&lt;/strong&gt; Spot Instances provide a balance between cost and flexibility, offering lower prices than On-Demand instances but with the risk of interruption.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Containerized Workloads:&lt;/strong&gt; For containerized applications, both ECS Fargate and EKS Fargate offer simplicity and cost predictability, charging based on actual resource consumption without the need to manage underlying servers.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Conclusion:&lt;/strong&gt;&lt;br&gt;
The choice of service depends on the workload characteristics and cost considerations for highly variable workloads or those that can benefit from serverless architecture, Lambda is often the most cost-effective.For steady-state applications where cost predictability is crucial, EC2 Reserved Instances offer significant savings.&lt;br&gt;
Spot Instances are suitable for fault-tolerant applications where cost savings outweigh potential interruptions.ECS/EKS Fargate provides a good balance for containerized applications, offering simplicity and scalability without managing server infrastructure.&lt;br&gt;
It's essential to monitor actual usage and costs closely, as AWS pricing models can vary based on region, instance types, and other factors. Additionally, consider using AWS Cost Explorer and Savings Plans for further optimization.&lt;/p&gt;

&lt;h2&gt;
  
  
  Empowering Decisions with AWS Cost Management Tools
&lt;/h2&gt;

&lt;p&gt;To navigate this complex landscape effectively, AWS provides a suite of cost management tools. These tools offer insights into spending patterns, enabling users to make informed decisions about service allocation and optimization strategies. Just as travelers rely on apps and websites to track rewards and find the best deals, AWS Cost Explorer and Budgets empower users to analyze their cloud spending and identify opportunities for improvement.&lt;/p&gt;

&lt;h2&gt;
  
  
  Embracing the Journey of Continuous Optimization
&lt;/h2&gt;

&lt;p&gt;The quest for cost optimization in both award travel and AWS is a journey of continuous learning and adaptation. Whether it's mastering the art of point transfers or navigating the intricacies of AWS pricing models, the key to success lies in staying informed, being adaptable, and making strategic choices that align with your goals.&lt;/p&gt;

&lt;p&gt;By applying the same level of critical thinking and strategic planning to AWS service selection as you do to award travel, you can unlock significant savings and ensure that every dollar spent—whether in points or cloud resources—delivers maximum value. Remember, the ultimate goal is not just to save money but to ensure that every investment supports your broader objectives and enhances your ability to innovate and grow.&lt;/p&gt;

&lt;p&gt;If you have made this far… Thank you for reading!! I would love to hear your feedback, thoughts and comments below..  &lt;/p&gt;

</description>
      <category>awardtravel</category>
      <category>aws</category>
      <category>points</category>
      <category>offers</category>
    </item>
    <item>
      <title>From Code to Game: My Unity Adventure</title>
      <dc:creator>Spencer Steed</dc:creator>
      <pubDate>Wed, 07 Aug 2024 16:09:30 +0000</pubDate>
      <link>https://dev.to/devsatasurion/from-code-to-game-my-unity-adventure-3i1f</link>
      <guid>https://dev.to/devsatasurion/from-code-to-game-my-unity-adventure-3i1f</guid>
      <description>&lt;p&gt;As a software engineer, I've always been fascinated by the intricate world of game development. Despite my experience in coding, stepping into this realm felt like opening a door to an entirely new universe. This blog aims to share my journey as a beginner in Unity game development, along with some initial tips and tricks I've picked up along the way.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Why would I make a video game when I can just play them?&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;I have been playing video games as long as I can remember. I have always used them as a release from stress and anxiety, but its also how I met some of my best friends. Countless nights of staying up late on a variety of games, weekends of competing in fps (first person shooter) tournaments, and even hosting LAN parties at my house.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fqbtn1u3bdor5kpttjs52.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fqbtn1u3bdor5kpttjs52.png" alt="LAN"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Often, I hoped for a way to combine some features from different games. I began to think, "What if I could merge these fun mechanics into a single game?" The idea grew even more exciting when I imagined my friends' voices as the characters' voice lines.&lt;br&gt;
 &lt;br&gt;
Then it dawned on me…..&lt;/p&gt;

&lt;p&gt;Why not create a game that combines the best elements of my favorite games, featuring the unique touch of my friends' voices? That's when this journey began.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Let's Start Simple.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Learning The Basics&lt;/strong&gt;: First thing I did was look up some tutorials for Unity on Youtube. I quickly found one called "The Unity Tutorial for Complete Beginners". This video helped me create a new project, understand the Unity ui, and create a simple flappy bird style game.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Starting Small&lt;/strong&gt;: I knew I was brand new to this and needed something that wouldn't require extensive knowledge of advanced features in Unity and something that would get my feet wet in game development. Therefore, I decided to start with a 2D Zombie Survival Game. This would also allow me to practice leveraging what I learned in the tutorial video and also add some custom flair to the project.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Leveraging Online Resources&lt;/strong&gt;: Now that I had my project idea and some new base principles to try out, I went back to Youtube to find some examples of similar style games to what I was looking to build. That's where I found "Make a 2D Top Down RPG in Unity". This video series is quite long (~100 videos), but I was able to jump around a bit and utilize some core teachings they offered.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Practice, Practice, Practice&lt;/strong&gt;: Watching someone else implement a new sprite with new animations and collision does not grant you the ability to do it yourself. It also won't help you retain that knowledge. Practice is key when implementing and improving anything in your game. This is something that I have carried over from being a software engineer for the past 10 years.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Join or Create a Community&lt;/strong&gt;: A community is crucial for feedback and improvements to your game. It also can provide the help you need for new ideas, bug fixes, and even with new assets to add to your game! I was fortunate enough to have a group of Discord friends that were willing to help with this. We opened a channel and ideas started flooding in. "What should the zombies look like?" or "What should the sniper class look like?" which was then followed by someone from the community adding some new sprites to use.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Setup The New Project&lt;/strong&gt;: Once I figured out I wanted to make a 2D Zombie Survival Game, I created the project in Unity with the prebuilt "2D" template and pushed the code to a new private Github repository. This allows you to add any contributors to the project later and also serves as a way to rollback if you make a mistake or change your mind on something (it will happen). Also PC issues happen, so never hurts to have a backup.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Lets get started on the game!&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Building this game in 2D largely determines how I will have to control the character. While I enjoy the classic full keyboard controls of games like Final Fantasy XI, most users prefer using the mouse to control the direction the character is facing. Additionally, using the mouse makes fighting hoards of zombies easier since they will be coming from every direction. Therefore, I decided to go with simple WASD movement, having abilities set to 1–2–3–4 , and mouse for camera directional controls.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fezpkjlaux6amgl4og1vw.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fezpkjlaux6amgl4og1vw.png" alt="Mouse and Keyboard"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;How does Unity handle player movement?&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Unity offers various methods for handling movement inputs, including Transform, Rigidbody, and CharacterController. For my project, I am utilizing Rigidbody. Below are some examples of Rigidbody methods essential for the PlayerMovement script:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Update()&lt;/strong&gt; Handles input for movement (WASD keys) and call the RotateTowardsMouse method to rotate the player towards the mouse position.&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;

void Update()
{
  movement.x = Input.GetAxis('Horizontal');
  movement.y = Input.GetAxis('Vertical');

  RotateTowardsMouse();
}


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;FixedUpdate()&lt;/strong&gt; Moves the player based on the movement vector and speed.&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;

void FixedUpdate()
{
  rb.MovePosition(rb.position + movement * moveSpeed * Time.fixedDeltaTime);
}


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;&lt;strong&gt;RotateCharacterTowardsMouse()&lt;/strong&gt; Calculates the angle between the player and the mouse position, then rotates the player to face the mouse.&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;

void RotateCharacterTowardsMouse()
{
    Vector3 mousePosition = Camera.main.ScreenToWorldPoint(Input.mousePosition);
    Vector2 direction = (Vector2)(mousePosition - transform.position);
    float angle = Mathf.Atan2(direction.y, direction.x) * Mathf.Rad2Deg;
    rb.rotation = angle;
}


&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;Most components created for the project will require scripts for customization. Note that Unity will automatically update the script as you make changes through the UI.&lt;/p&gt;

&lt;p&gt;Once you have created the PlayerMovement script, you can assign it to the player GameObject by dragging and dropping it from the Project window into the Inspector window. Alternatively, you can click the Add Component button in the Inspector window, search for PlayerMovement, and select it.&lt;/p&gt;

&lt;p&gt;After configuring the movement, you will be able to move an empty square model around.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Lets add some custom sprites!&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Setting up the player and zombie sprites is a fun process that I enjoyed. My friend Joey created the sprites and I was able to build all the surrounding pieces to make them work. I imported the custom sprites for player models, zombies, and scenery into their folder, plugged them in, and worked on setting up idle/running states.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F6fog077r3h6qyo6fh2g4.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F6fog077r3h6qyo6fh2g4.png" alt="Zombie"&gt;&lt;/a&gt;&lt;br&gt;
 &lt;br&gt;
&lt;em&gt;Wow,  I got stuck on a bush in the dark and couldn't get the zombie off me!&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Nothing is worse than getting stuck on an object and your character dying due to poor coding. This is something that I wanted to make sure I got right. I added a combination of Collider and RigidBody2D to set a collision perimeter for the player, the zombies, and all scenery that was added. Unity fortunately does a good job with the ability to duplicate the models and maintain their collision.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;How should the zombies behave?&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;For the Zombie AI I want them to behave similar to how they do in Project Zomboid. If you are detected in their sight or hearing range, they will immediately start trying to attack and chase you. The player should have a slight speed advantage over the zombies while sprinting. However, there should be a balance between choosing to outrun the zombie at the risk of depleting stamina or confronting the zombie and potentially attracting more due to the noise.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;What should we do next?&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Combat&lt;/strong&gt;: Animations and feedback will require a significant amount of time because each weapon type has unique requirements. Melee weapons need different rotations, ranged weapons need distinct animations, and any change to the weapon's size necessitates updates to the animations.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;UI&lt;/strong&gt;: Creating a clean UI is crucial for maintaining game fluidity and providing players with essential information about their health, stamina, and, if applicable, mana for magic mechanics. It's also important to have visibility into ability cooldowns and which weapon is currently equipped.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Advanced Animations&lt;/strong&gt;: Implementing features like player death, bullet animations, destructible objects, and blood can be challenging, but they significantly enhance the game's depth.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Add Multiplayer&lt;/strong&gt;: To add multiplayer, you will likely need to do some research on implementing Photon or mirror. These will give you the networking you need for adding other players to be controlled.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Don't forget to play your game!&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;After investing countless hours in building your game, I recommend taking some time to play it. Identify areas for improvement and jot them down. Many of the enhancements I worked on originated from bugs I discovered in existing features.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Thank you for reading!&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;As I conclude this talk about my Unity adventure, I reflect on the invaluable lessons learned along the way. It has been filled with challenges, creativity, and continuous learning.&lt;/p&gt;

&lt;p&gt;Each bug fixed and feature implemented brought new insights and a deeper understanding of game development. It is important to identify areas for improvement, and embrace every obstacle as a stepping stone to growth.&lt;/p&gt;

&lt;p&gt;Thank you for following along, and I hope my experiences inspire you to pursue your own adventures in the world of Unity and game development.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F9ax9k3k8w4fvax3p9tr6.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F9ax9k3k8w4fvax3p9tr6.png" alt="FinalSendoff"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;References&lt;/strong&gt;:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://medium.com/r/?url=https%3A%2F%2Fyoutu.be%2FXtQMytORBmM%3Fsi%3DR8jtTA4xMzsO2tgY" rel="noopener noreferrer"&gt;The Unity Tutorial for Complete Beginners&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://medium.com/r/?url=https%3A%2F%2Fyoutu.be%2F9zzUq6T-rtA%3Fsi%3DgILZ5HOJBJofZwjb" rel="noopener noreferrer"&gt;Make a 2D Top Down RPG in Unity&lt;/a&gt;&lt;/p&gt;

</description>
      <category>gamedev</category>
      <category>unity3d</category>
    </item>
    <item>
      <title>Why You Should Learn Kubernetes</title>
      <dc:creator>Vince Llauderes</dc:creator>
      <pubDate>Wed, 07 Aug 2024 12:39:46 +0000</pubDate>
      <link>https://dev.to/devsatasurion/why-you-should-learn-kubernetes-p8k</link>
      <guid>https://dev.to/devsatasurion/why-you-should-learn-kubernetes-p8k</guid>
      <description>&lt;h2&gt;
  
  
  Introduction
&lt;/h2&gt;

&lt;p&gt;Kubernetes is one of the fastest-growing open-source projects in the community since it was released by Google in 2014. &lt;strong&gt;&lt;em&gt;It became one of the de facto APIs for building and deploying cloud-native applications in the public cloud&lt;/em&gt;&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;As an increasing number of companies shift to cloud-native applications to modernize their systems into smaller, microservice-based components, they require a robust technology that can manage scalability, reliability, and automated deployment. This enables them to operate with greater agility as the demand for their application increases.&lt;/p&gt;

&lt;h2&gt;
  
  
  What is Kubernetes?
&lt;/h2&gt;

&lt;blockquote&gt;
&lt;p&gt;Kubernetes is a portable, extensible, open-source platform for managing containerized workloads and services, that facilitates both declarative configuration and automation. &lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;source from &lt;a href="https://kubernetes.io/docs/concepts/overview/" rel="noopener noreferrer"&gt;https://kubernetes.io/docs/concepts/overview/&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;/blockquote&gt;

&lt;h3&gt;
  
  
  Let’s take a look at why Kubernetes is so useful today
&lt;/h3&gt;

&lt;p&gt;In IT, there are three common ways to deploy our applications (to name a few before the advent of Function as a Service known as FaaS)&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fe2fg478yyx47y3lboez1.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fe2fg478yyx47y3lboez1.png" alt="traditional deployment"&gt;&lt;/a&gt;&lt;br&gt;Figure: 1.0 "Evolution of application deployment"
  &lt;/p&gt;

&lt;h3&gt;
  
  
  Traditional deployment
&lt;/h3&gt;

&lt;p&gt;In the early days of computing, organizations ran their applications on their physical servers (on-premise setup). By doing this, you cannot define resource boundaries between your application in a physical server, which might cause &lt;strong&gt;resource allocation issues&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;For example, suppose you have multiple applications running on the same physical server. In that case, there can be instances where one application would take up most of the resources and as a result, the other applications would underperform (see Figure: 1.1). A solution for this is to host your other applications on a different physical server. But the problem with this approach is that it might not scale, because you’ll end up buying more and more physical servers to accommodate the load when increases. When you allocate your application to different servers, it often results in underutilized resources on the physical server. This is where the virtualized deployment era comes in.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fjuvdq4cjcad8djw0uul1.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fjuvdq4cjcad8djw0uul1.png" alt="traditional deployment"&gt;&lt;/a&gt;&lt;br&gt;Figure: 1.1 "No resource boundaries between application"
  &lt;/p&gt;

&lt;h3&gt;
  
  
  Virtualized deployment
&lt;/h3&gt;

&lt;p&gt;As a solution to traditional deployment, Virtualized deployments were introduced. It allows us to isolate different applications to separate Virtual Machines (VMs). In such a way that other applications won’t take up more resources even if they're on a single server (see Figure: 1.2). Multiple Virtual Machines can run on a single physical server which reduces our hardware cost and allows us to maintain lesser physical servers compared to traditional deployment approach.&lt;/p&gt;

&lt;p&gt;But here’s the thing, by using Virtualized Deployment, there are still underutilized resources. Each VM has its own Operating System which can take up resources on the physical server. Would it be better if we remove the layer of the Operating System so that we could have more storage in the physical server to use? This is where the containerized deployment is introduced.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fnit6cov1uc9o93or0ucy.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fnit6cov1uc9o93or0ucy.png" alt="virtualized deployment"&gt;&lt;/a&gt;&lt;br&gt;Figure: 1.2 "Virtualized Deployment to define resource boundaries"
  &lt;/p&gt;

&lt;h3&gt;
  
  
  &lt;strong&gt;Container deployment&lt;/strong&gt;
&lt;/h3&gt;

&lt;p&gt;Container deployments are similar to Virtualized deployments they can isolate your applications from the rest of the applications in a &lt;strong&gt;“Container”&lt;/strong&gt; fashion. Containers are lightweight (see Figure: 1.3) compared to VMs because containers, don’t have the whole Operating System layer. Similar to VMs, containers have their own filesystem, memory, and CPU but container uses a generic Operating System called Kernel. This Kernel Operating System is typically Linux.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fp5xtpbowdr49zvdfmds6.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fp5xtpbowdr49zvdfmds6.png" alt="container deployment"&gt;&lt;/a&gt;&lt;br&gt;Figure: 1.3 "Container has its own filesystem"
  &lt;/p&gt;

&lt;p&gt;In order for us to run “Containers” we need to have a &lt;a href="https://www.wiz.io/academy/container-runtimes" rel="noopener noreferrer"&gt;Container Runtime&lt;/a&gt; on top of our physical server which is typically &lt;strong&gt;Docker&lt;/strong&gt;. (Docker is a container technology. There are lots of container technologies exist in the market and not only Docker see &lt;a href="https://www.solarwinds.com/resources/it-glossary/container" rel="noopener noreferrer"&gt;link&lt;/a&gt;)&lt;/p&gt;

&lt;p&gt;Since containers are lightweight, we can easily &lt;strong&gt;add&lt;/strong&gt; &amp;amp; &lt;strong&gt;remove&lt;/strong&gt; applications &lt;strong&gt;without the boot-up of the server&lt;/strong&gt;. &lt;/p&gt;

&lt;p&gt;This is where the Microservices pattern became popular. With Microservices (see Figure: 1.4), we can host each microservice to each individual container. We can have hundreds or even thousands of running containers on a single physical server. Just imagine that 🤯.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F6dc4wuipjtqnhl3o2rfd.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F6dc4wuipjtqnhl3o2rfd.png" alt="container deployment"&gt;&lt;/a&gt;&lt;br&gt;Figure: 1.4 "Applications are decomposed into smaller services or known as &lt;strong&gt;Microservices&lt;/strong&gt;"
  &lt;/p&gt;

&lt;p&gt;To name a few, containers have lots of benefits. With containers, we can be more agile, scale our application on demand, and achieve portability in our applications which we will not end up having dependency issues when deploying applications in production. Because the container is packaged to include all the application dependencies in order for it to run.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;But that great power comes with great responsibility 💪🏻&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;How do we manage our containers? I mentioned earlier that containers enable us to deploy hundreds or even thousands of containers on a physical server. How do we &lt;strong&gt;start&lt;/strong&gt;, and &lt;strong&gt;stop&lt;/strong&gt; each individual container? How do we ensure each individual container is &lt;strong&gt;healthy&lt;/strong&gt;? How do &lt;strong&gt;coordinate each individual container&lt;/strong&gt;?  How do you handle the scaling of containers, &lt;strong&gt;Deployment&lt;/strong&gt;, &lt;strong&gt;Load Balancing&lt;/strong&gt;, &lt;strong&gt;Service Discovery&lt;/strong&gt;, and even &lt;strong&gt;Rolling Updates&lt;/strong&gt;? These are things that you need to keep in mind in running containers in production.&lt;/p&gt;

&lt;p&gt;Of course, we can develop a script that can handle these tasks but that’s not ideal unless you want to invent a new technology. For some companies it’s not worth it for them to develop new technology, instead, they want a proven and working technology in the market that is capable of doing this instead of developing their own. This is where &lt;strong&gt;Container Orchestration&lt;/strong&gt; comes in.&lt;/p&gt;

&lt;h2&gt;
  
  
  What is Container Orchestration?
&lt;/h2&gt;

&lt;p&gt;Container Orchestration is a tool that &lt;strong&gt;orchestrates/manages&lt;/strong&gt; the containers. It helps us solve the problem that arises in managing containers. Container orchestration helps us manage each individual piece of a container such as &lt;strong&gt;scaling&lt;/strong&gt;, &lt;strong&gt;automated deployments&lt;/strong&gt;, and &lt;strong&gt;health checks&lt;/strong&gt;. It also ensures each container is alive even in uncertain circumstances.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“&lt;em&gt;Container orchestration is the same concept of an orchestra in music which manages each individual part of the instrument to perform great music (see Figure: 1.5)&lt;/em&gt;”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F1ckwqmpmr8pxzy8fit9b.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F1ckwqmpmr8pxzy8fit9b.png" alt="container orchestration"&gt;&lt;/a&gt;&lt;br&gt;Figure: 1.5 "Container Orchestration is like an Orchestra in Music"
  &lt;/p&gt;

&lt;p&gt;There are lots of tools that are available for choosing container orchestration, but &lt;strong&gt;Kubernetes&lt;/strong&gt; is one of the most popular.&lt;/p&gt;

&lt;p&gt;(Docker Swarm can manage containers but docker swarm doesn’t scale well and has limited features compared to Kubernetes. see link: &lt;a href="https://circleci.com/blog/docker-swarm-vs-kubernetes/" rel="noopener noreferrer"&gt;Docker Swarm vs. Kubernetes&lt;/a&gt;)&lt;/p&gt;

&lt;h2&gt;
  
  
  Benefits of Learning Kubernetes?
&lt;/h2&gt;

&lt;h3&gt;
  
  
  Industry demand
&lt;/h3&gt;

&lt;p&gt;Big tech companies like Google, Amazon &amp;amp; Microsoft are highly invested in this technology, which creates a huge job opportunity for engineers who will learn this.&lt;/p&gt;

&lt;p&gt;Also, with more and more companies embracing the Kubernetes model to deploy their cloud-native applications, it creates huge community support on the market and allows you to become more productive in using the technology.&lt;/p&gt;

&lt;p&gt;In a recent &lt;a href="https://survey.stackoverflow.co/2024/technology#most-popular-technologies-tools-tech-prof" rel="noopener noreferrer"&gt;2024 Stackoverflow Developer Survey&lt;/a&gt;, Kubernetes ranked among the top 5 most used tools by &lt;strong&gt;Professional Developers&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F4ss07qf10s6wg6r94n5m.png" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2F4ss07qf10s6wg6r94n5m.png" alt="StackOverflow survey"&gt;&lt;/a&gt;&lt;br&gt;Figure: 1.5 "Kubernetes became top 5 by most used by developers"
  &lt;/p&gt;

&lt;h3&gt;
  
  
  Portability
&lt;/h3&gt;

&lt;p&gt;One of the best selling points of Kubernetes is its use of containers to run applications (Thanks to containerization tools). Since containers are portable, you can run your applications in a wide variety of environments, along with their required dependencies. With this kind of approach, it is possible to reduce the number of issues shown in Production because of missing configuration.&lt;/p&gt;

&lt;p&gt;Gone are the days of saying...&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“Your application is running in DEV but not in PROD. That's because there’s is a different configuration in the environment.“&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h3&gt;
  
  
  Scalability &amp;amp; Flexibility
&lt;/h3&gt;

&lt;p&gt;One of the common issues that we face on On-Premise setups is how do we scale our applications like Horizontal scaling. Horizontal Scaling in an On-Premise setup is a nightmare for some because we typically buy a new physical server and set up the configuration required in order to spin up a new one. This kind of approach is not very productive and you’ll waste a lot of time.&lt;/p&gt;

&lt;p&gt;With Kubernetes, you can easily &lt;strong&gt;scale up&lt;/strong&gt; and &lt;strong&gt;scale down&lt;/strong&gt; your applications depending on the demand. Whether it is Horizontal or Vertical Scaling (see: &lt;a href="https://www.cloudzero.com/blog/horizontal-vs-vertical-scaling/#:~:text=While%20horizontal%20scaling%20refers%20to,%2C%20storage%2C%20or%20network%20speed" rel="noopener noreferrer"&gt;Horinzontal vs. Vertical Scaling&lt;/a&gt;).&lt;/p&gt;

&lt;p&gt;It is flexible because it can adapt to your needs in such a way that if the demand is low, it can scale down. But if the demand is high, it scales up your resources.&lt;/p&gt;

&lt;h3&gt;
  
  
  High Availability &amp;amp; Stability
&lt;/h3&gt;

&lt;p&gt;Kubernetes by nature is self-healing and monitors our applications whether it was healthy or not. If it’s not healthy, it replaces a new instance to become functional and healthy again (Figure: 1.0). With this kind of feature, we can rely on technology to ensure our application is reliable in uncertain circumstances.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fwelg3r9qe9gdrp6ihxok.gif" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Farticles%2Fwelg3r9qe9gdrp6ihxok.gif" alt="Self-healing"&gt;&lt;/a&gt;&lt;br&gt;Figure: 1.6 "If the Container isn't healthy, it replaces a new one to become healthy again"
  &lt;/p&gt;

&lt;p&gt;You can also perform rollbacks if your recent deployments didn’t work as expected and Kubernetes can seamlessly perform rollbacks.&lt;/p&gt;

&lt;h3&gt;
  
  
  Community &amp;amp; Support
&lt;/h3&gt;

&lt;p&gt;Cloud Providers such as &lt;strong&gt;AWS&lt;/strong&gt;, &lt;strong&gt;Azure&lt;/strong&gt;, &amp;amp; &lt;strong&gt;GCP&lt;/strong&gt; have created &lt;a href="https://www.akamai.com/glossary/what-is-managed-kubernetes" rel="noopener noreferrer"&gt;Managed Kubernetes Services&lt;/a&gt; that allow customers to use Kubernetes with ease without worrying too much about its underlying infrastructure. This is a huge advantage for the community who wants to use and try Kubernetes immediately 👏🏻. &lt;/p&gt;

&lt;p&gt;There are also lots of tools developed by the community that you can use in Kubernetes to make your setup more versatile like integrating it into CI/CD Pipeline or following the &lt;a href="https://codefresh.io/learn/gitops/#:~:text=GitOps%20is%20an%20operational%20framework,infrastructure%20and%20manages%20software%20deployment." rel="noopener noreferrer"&gt;GitOps&lt;/a&gt; approach. Tools like &lt;a href="https://argo-cd.readthedocs.io/en/stable/" rel="noopener noreferrer"&gt;ArgoCD&lt;/a&gt;, &lt;a href="https://kustomize.io/" rel="noopener noreferrer"&gt;Kustomize&lt;/a&gt;, and &lt;a href="https://helm.sh/" rel="noopener noreferrer"&gt;Helm&lt;/a&gt; can make you more productive by embracing the Kubernetes model in your deployment.&lt;/p&gt;

&lt;h2&gt;
  
  
  Where should you start?
&lt;/h2&gt;

&lt;p&gt;Start with the basics. I will share below the resources that helped me get started on my journey of learning Kubernetes.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;&lt;p&gt;First, start getting better and understanding how containers work. Start using a container technology like Docker and containerizing your application. &lt;br&gt;&lt;br&gt;Familiarize yourself with how to create &lt;code&gt;Dockerfile&lt;/code&gt; from scratch and learning the important &lt;code&gt;Dockerfile&lt;/code&gt; commands like &lt;code&gt;FROM&lt;/code&gt;, &lt;code&gt;COPY&lt;/code&gt;, &lt;code&gt;ENTRYPOINT&lt;/code&gt;, and &lt;code&gt;CMD&lt;/code&gt; might help. &lt;br&gt;&lt;br&gt;Get your hands dirty on how to use &lt;code&gt;docker cli&lt;/code&gt; commands. Commands like &lt;code&gt;docker build&lt;/code&gt;, &lt;code&gt;docker tag&lt;/code&gt;, and &lt;code&gt;docker push&lt;/code&gt;. &lt;br&gt;Be familiar with how to troubleshoot docker containers by using &lt;code&gt;docker logs&lt;/code&gt; and dig deeper with the container image like &lt;code&gt;docker exec&lt;/code&gt; to inspect the container filesystem.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Once you know containers, Learn how to work with YAML. You’ll get heavily reliant on YAML once you start working on Kubernetes. A basic understanding of how YAML files work is a huge advantage in learning Kubernetes.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Next, set up a local Kubernetes cluster on your local machine. The &lt;a href="https://docs.docker.com/desktop/kubernetes/" rel="noopener noreferrer"&gt;Docker desktop application&lt;/a&gt; can help you easily get started on this by enabling Kubernetes. &lt;br&gt;&lt;br&gt;Deploy lots of applications and get your hands dirty. Understanding &lt;br&gt;
Kubernetes objects like Pods, Deployments, and Services are a good start to get your applications up and running.&lt;br&gt;&lt;br&gt;You’ll heavily use the Kubernetes CLI commands like &lt;code&gt;kubectl -f &amp;lt;filename.yaml&amp;gt;&lt;/code&gt;, &lt;code&gt;kubectl get pods&lt;/code&gt;, &lt;code&gt;kubectl describe&lt;/code&gt;, &amp;amp; &lt;code&gt;kubectl exec&lt;/code&gt;. To interact with applications.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Apply what you learn out there. Maybe in your team or organization, introduce some container orchestration tools like Kubernetes if you haven’t used them yet. Or if you’re using it, collaborate with those people who heavily use Kubernetes on their day-to-day job and start volunteering to help them with that task.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;This is optional but, &lt;strong&gt;Get certified&lt;/strong&gt;! Having a certification in a particular technology can enhance professional credibility and recognition within the industry. It’s also a huge plus for those people who don’t have certification. This also serves as a personal accomplishment in your journey as a Software Engineer and can help you stay up to date with the latest trends in technology. &lt;br&gt;&lt;br&gt;Certifications like &lt;strong&gt;CKAD&lt;/strong&gt;, &lt;strong&gt;CKA&lt;/strong&gt;, and &lt;strong&gt;CKS&lt;/strong&gt; might be great option to validate and show your credibility and competitiveness in the Kubernetes field.&lt;br&gt;&lt;br&gt;This certification was released by the &lt;a href="https://www.cncf.io/training/certification/" rel="noopener noreferrer"&gt;Cloud Native Computing Foundation&lt;/a&gt;. This Certification has a cost and you will need to review and practice a lot to pass it.&lt;br&gt;&lt;br&gt;I just got my certification in &lt;strong&gt;CKAD&lt;/strong&gt; last year and it was one of the best decisions that I have made.&lt;br&gt;&lt;br&gt;Having a certification is a win-win scenario for Software Engineers!&lt;/p&gt;&lt;/li&gt;
&lt;/ol&gt;

&lt;h2&gt;
  
  
  Call to Action
&lt;/h2&gt;

&lt;p&gt;Ready to dive into the Kubernetes world? Start your learning journey today with these beginner-friendly resources and courses.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;A miniseries created by Google Cloud Tech on How to run containers on Kubernetes — &lt;a href="https://www.youtube.com/watch?v=_2fiMli8p3E" rel="noopener noreferrer"&gt;https://www.youtube.com/watch?v=_2fiMli8p3E&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;This YouTube Tutorial Kubernetes series by &lt;strong&gt;TechWorld with Nana&lt;/strong&gt; —&lt;a href="https://www.youtube.com/watch?v=X48VuDVv0d" rel="noopener noreferrer"&gt;https://www.youtube.com/watch?v=X48VuDVv0d&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;I’m a huge fan of reading an E-book if I want to learn a particular technology that’s new to me I want to dig deeper. Having an Ebook which greatly helps me understand better the bigger picture of Kubernetes

&lt;ul&gt;
&lt;li&gt;Kubernetes In Action by Marko Luksa - &lt;a href="https://www.manning.com/books/kubernetes-in-action" rel="noopener noreferrer"&gt;https://www.manning.com/books/kubernetes-in-action&lt;/a&gt;
&lt;/li&gt;
&lt;li&gt;Kubernetes Up &amp;amp; Running 2nd Edition By Brendan Burns, Joe Beda, Kelsey Hightower - &lt;a href="https://www.oreilly.com/library/view/kubernetes-up-and/9781492046523/" rel="noopener noreferrer"&gt;https://www.oreilly.com/library/view/kubernetes-up-and/9781492046523/&lt;/a&gt;
&lt;/li&gt;
&lt;/ul&gt;


&lt;/li&gt;

&lt;li&gt;There's also an Udemy course that I recommend. I bought this because It allows you to prepare for the CKAD certification exam experience with actual exam scenarios and try challenges which helps me get better at debugging and allows you to get your hands dirty with the technology. &lt;a href="https://www.udemy.com/course/certified-kubernetes-application-developer/?couponCode=ACCAGE0923" rel="noopener noreferrer"&gt;&lt;/a&gt;&lt;a href="https://www.udemy.com/course/certified-kubernetes-application-developer/?couponCode=ACCAGE0923" rel="noopener noreferrer"&gt;https://www.udemy.com/course/certified-kubernetes-application-developer/?couponCode=ACCAGE0923&lt;/a&gt; by &lt;a href="https://www.udemy.com/user/mumshad-mannambeth/" rel="noopener noreferrer"&gt;Mumshad Mannambeth&lt;/a&gt;
&lt;/li&gt;

&lt;/ul&gt;

&lt;p&gt;Let me end this blog post with a quote from one of the famous Kubernetes Advocate.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“Kubernetes has become the &lt;strong&gt;de facto&lt;/strong&gt; standard for container orchestration. Its ability to abstract the underlying infrastructure &lt;strong&gt;makes it easier for developers to focus on writing code rather than managing infrastructure&lt;/strong&gt;”&lt;/p&gt;

&lt;p&gt;— Brendan Burns, Co-Founder of Kubernetes and Distinguished Engineer at Microsoft.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;If you enjoy this blog, please give me a heart reaction ♥️. Comment below for some additional tips as well 😊&lt;/p&gt;

&lt;h2&gt;
  
  
  “Don’t be a mediocre Software Engineer”
&lt;/h2&gt;

&lt;p&gt;Follow me on twitter &lt;a href="https://twitter.com/llaudevc/" rel="noopener noreferrer"&gt;&lt;em&gt;https://twitter.com/llaudevc/&lt;/em&gt;&lt;/a&gt;&lt;/p&gt;

</description>
      <category>kubernetes</category>
      <category>devops</category>
      <category>webdev</category>
      <category>programming</category>
    </item>
  </channel>
</rss>
