<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Rugamba Odilo on Medium]]></title>
        <description><![CDATA[Stories by Rugamba Odilo on Medium]]></description>
        <link>https://medium.com/@rugambaodilo?source=rss-48fcaacad0a7------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*XAli2zCRipzFobJ0R_xScw.jpeg</url>
            <title>Stories by Rugamba Odilo on Medium</title>
            <link>https://medium.com/@rugambaodilo?source=rss-48fcaacad0a7------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Thu, 19 Nov 2026 01:10:31 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@rugambaodilo/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[As promised, Checklist — Rwanda’s Personal Data Protection and Privacy Law]]></title>
            <link>https://medium.com/@rugambaodilo/as-promised-checklist-rwandas-personal-data-protection-and-privacy-law-4e5045eba747?source=rss-48fcaacad0a7------2</link>
            <guid isPermaLink="false">https://medium.com/p/4e5045eba747</guid>
            <dc:creator><![CDATA[Rugamba Odilo]]></dc:creator>
            <pubDate>Sun, 26 Mar 2023 19:13:52 GMT</pubDate>
            <atom:updated>2023-03-26T19:13:52.406Z</atom:updated>
            <content:encoded><![CDATA[<h3>As promised, Checklist — Rwanda’s Personal Data Protection and Privacy Law</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*mYkUTThvHvqKMGuFORy4mw.png" /><figcaption>The checklist</figcaption></figure><p>As previously mentioned, I’ve created a helpful <a href="https://docs.google.com/document/d/1YAxsE1OM9ULe7bNbOPgNH7_hTDwCdd_aZ0P1ZEBRqKQ/edit?usp=sharing">checklist</a> to ensure that your business is in compliance with Rwanda’s Personal Data Protection and Privacy Law, which will be implemented this October. I’ve made it very user-friendly, and you can find it on a Google Doc via the link provided below. Feel free to utilize it as is or add to it as necessary.</p><p>I’m also looking for input from others to help grow and improve the checklist’s coverage, so please don’t hesitate to chime in with your own suggestions. And if you encounter any difficulties, I’m more than happy to lend a hand in any way possible.</p><p>For more information, check out the <a href="https://www.minict.gov.rw/fileadmin/user_upload/minict_user_upload/Documents/Press_Release/211021_PRESS_RELEASE_Rwanda_s_New_Data_Protection_Law_ENGLISH.pdf">press release </a>from the Ministry of ICT, which I’ve included here as a point of reference.</p><p>Checklist: <a href="https://docs.google.com/document/d/1YAxsE1OM9ULe7bNbOPgNH7_hTDwCdd_aZ0P1ZEBRqKQ/edit?usp=sharing"><em>https://docs.google.com/document/d/1YAxsE1OM9ULe7bNbOPgNH7_hTDwCdd_aZ0P1ZEBRqKQ/edit?usp=sharing</em></a></p><p>Press release: <a href="https://www.minict.gov.rw/fileadmin/user_upload/minict_user_upload/Documents/Press_Release/211021_PRESS_RELEASE_Rwanda_s_New_Data_Protection_Law_ENGLISH.pdf"><em>https://www.minict.gov.rw/fileadmin/user_upload/minict_user_upload/Documents/Press_Release/211021_PRESS_RELEASE_Rwanda_s_New_Data_Protection_Law_ENGLISH.pdf</em></a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4e5045eba747" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Decoding Rwanda’s Data Privacy Regulations: My Thoughts]]></title>
            <link>https://medium.com/@rugambaodilo/decoding-rwandas-data-privacy-regulations-my-thoughts-a9dc182db0ce?source=rss-48fcaacad0a7------2</link>
            <guid isPermaLink="false">https://medium.com/p/a9dc182db0ce</guid>
            <dc:creator><![CDATA[Rugamba Odilo]]></dc:creator>
            <pubDate>Sun, 12 Feb 2023 16:04:06 GMT</pubDate>
            <atom:updated>2023-02-12T16:20:44.584Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*3jtKmLSloudsaNVdnbKHcA.png" /></figure><p>Having worked with dozens of companies in Rwanda and other countries on software and data engineering projects I have always found data privacy laws interesting( To put it in non-eng. terms: challenging!!!). I have always wanted to write about Rwanda personal data protection and privacy law since it was introduced in 2019 but could never seem to get around to it. on the other hand, I believe that Being able to understand and implement this law is crucial for any company or organization that deals with personal data in Rwanda. So, let me share with you my key takeaways from this law, in a language that’s easy to understand.</p><ul><li><strong>It’s all about the rights of individuals:</strong> The Rwanda data privacy law puts a lot of emphasis on the rights of individuals, who are referred to as “data subjects.” These rights include the right to access their personal data, the right to rectify it (correct it if it’s incorrect), and the right to object to the processing of their data for certain purposes, such as direct marketing. This is great news for individuals, as it gives them more control over their personal information. However, it might not be so good news for organizations, since offering these options would require some extra work.</li><li><strong>Data controllers must be transparent and accountable:</strong> Data controllers, which are entities that are responsible for collecting, processing, and storing personal data, must be transparent about how they collect, store, and use personal data. They must also be accountable, meaning they must be able to demonstrate that they have taken steps to comply with the law. This is important because it helps ensure that personal data is being handled in a responsible and secure manner. Oooh yeah, you are legally required to have someone in your organization in charge of it.</li><li><strong>Data security is a big deal:</strong> The Rwanda data privacy law requires that data controllers take appropriate measures to protect personal data from unauthorized access, loss, or damage. This includes measures such as encryption, firewalls, and regular backups. As a data engineer, I know how important data security is and it’s great to see that this law recognizes this too.</li><li><strong>Data residency is important:</strong> According to the Rwanda data privacy law, personal data collected or processed in Rwanda must be stored in the country, unless specific exceptions apply. This is known as data residency and it’s important because it helps ensure that personal data is subject to the jurisdiction of Rwanda’s courts and supervisory authorities.</li><li><strong>Transfers to other countries must be done carefully:</strong> The law also regulates the transfer of personal data to other countries, and personal data may only be transferred to countries that provide an adequate level of protection. This is to make sure that personal data isn’t transferred to countries where it may be at risk of unauthorized access, loss, or damage.</li><li><strong>Sanctions and penalties for non-compliance:</strong> Finally, the Rwanda data privacy law provides for effective sanctions and penalties for non-compliance and grants supervisory authorities with sufficient powers to enforce the law and protect the rights of data subjects. This includes the power to impose fines and to order the rectification or deletion of personal data that has been processed in violation of the law.</li></ul><p>In conclusion, the Rwanda Personal Data Protection and Privacy Law has important implications for companies and organizations handling personal data in the country. With the transition period ending on <a href="https://www.minict.gov.rw/news-detail/rwanda-passes-new-law-protecting-personal-data">October 15, 2023,</a> it is important that you start taking steps to ensure that you are in compliance with the law. In future, I will delve further into this topic, including providing a helpful compliance checklist and more. ONE STEP AT A TIME, MATE!</p><p>DISCLAIMER: Not a Lawyer</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a9dc182db0ce" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Monitor NodeJS application with Newrelic]]></title>
            <link>https://medium.com/@rugambaodilo/monitor-nodejs-application-with-newrelic-de3f6afb5174?source=rss-48fcaacad0a7------2</link>
            <guid isPermaLink="false">https://medium.com/p/de3f6afb5174</guid>
            <dc:creator><![CDATA[Rugamba Odilo]]></dc:creator>
            <pubDate>Tue, 27 Sep 2022 19:07:59 GMT</pubDate>
            <atom:updated>2022-09-27T19:09:21.207Z</atom:updated>
            <content:encoded><![CDATA[<p>All BS. aside Newrelic is a great tool when it comes to monitoring application performance, It zooms in and show you details you can’t even start to imagine that your small application even can have.</p><p>And that is the end of me trying to be writer. Let me just take my notes.</p><h3>Requirements</h3><ul><li>Account with <a href="http://newrelic.com/">newrelic.com</a></li><li>NodeJS project</li></ul><h3>Set up</h3><ul><li>navigate to <a href="http://newrelic.com/">newrelic.com</a> and login</li><li>Click on Add Data</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*QGEjX10wGiEERfCNvP6knw.png" /></figure><ul><li>Choose Nodejs</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*PGEKt25wF_BVnTFi5QZmLg.png" /></figure><ul><li>Then choose Begin installation &gt; Then choose package manager</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*7nmvofdVKV-elVqa_I1riQ.png" /></figure><ul><li>Now simply read and follow instructions on the page and you will be fine</li></ul><p>From There you should be able to monitor your application hustle free</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=de3f6afb5174" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Deploying Nodejs With PM2]]></title>
            <link>https://medium.com/@rugambaodilo/deploying-nodejs-with-pm2-5bd7b8332f7e?source=rss-48fcaacad0a7------2</link>
            <guid isPermaLink="false">https://medium.com/p/5bd7b8332f7e</guid>
            <dc:creator><![CDATA[Rugamba Odilo]]></dc:creator>
            <pubDate>Tue, 27 Sep 2022 15:14:24 GMT</pubDate>
            <atom:updated>2022-09-27T15:14:24.977Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*Nq8z6RJyynDVGxlN" /></figure><p>I have been working with Node for a few years now, I started with some simple tests application that never seen a light of day and went on to work on some big applications, hell, I even attempted to crazy apps when I was bored.</p><p>Lately I have switched to devOps and I am going to note down some tasks that I have performed either on/with Nodejs, Starting with basic deployment with PM2</p><p><strong>Assumptions:</strong></p><ul><li>Fresh new VM</li><li>Connected to the internet</li><li>Ubuntu 20.04</li><li>You have root access</li></ul><p>First install nodejs on the server, For me I like To create a folder called sandbox and save everything that I use for set up.</p><pre>curl -sL https:</pre><pre>Install Nodejs</pre><pre>sudo bash nodesource_setup.sh</pre><pre>sudo apt install nodejs</pre><pre>sudo apt install build-essential</pre><p>Now you have your node, these 2 commands should work</p><p>Now add your application source code to the server, I prefer cloning from github.</p><pre>mkdir apps cd apps git clone https: cd &lt;app-name&gt;</pre><p>Now we install PM2</p><pre>sudo npm install pm2@latest -g</pre><p>Run the app with pm2</p><pre>pm2 start npm --name &quot;APP-NAME&quot; -- start</pre><p>This should work for application that normally work with <em>npm start</em></p><p>Voila! Now you have your app running.</p><blockquote><em>Note: Please use this documentation for test deployment or demo. In real production this needs some extra work.</em></blockquote><p><em>Originally published at </em><a href="https://odilo.hashnode.dev/deploying-nodejs-with-pm2"><em>https://odilo.hashnode.dev</em></a><em>.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=5bd7b8332f7e" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Backup and restoration with velero]]></title>
            <link>https://medium.com/@rugambaodilo/backup-and-restoration-with-velero-b4da43c2a70?source=rss-48fcaacad0a7------2</link>
            <guid isPermaLink="false">https://medium.com/p/b4da43c2a70</guid>
            <dc:creator><![CDATA[Rugamba Odilo]]></dc:creator>
            <pubDate>Mon, 26 Sep 2022 16:15:12 GMT</pubDate>
            <atom:updated>2022-09-26T16:15:12.560Z</atom:updated>
            <content:encoded><![CDATA[<h3>Summary</h3><p>According to the official website Velero is a tool that helps you back up and restore your Kubernetes cluster resources and persistent volumes.</p><p>You can use Velero in multiple backup related scenarios:</p><ul><li>Take backups of your cluster and restore in case of loss.</li><li>Migrate cluster resources to other clusters.</li><li>Replicate your production cluster to development and testing clusters.</li></ul><h3>Architecture</h3><p>Velero has two components</p><ul><li>A server-API that runs all velero activities (backup and restoration) which resides on your clusters</li><li>CLi that runs on your local machine to help you give commands to velero server</li></ul><h3>Prerequisites</h3><ul><li>You have at-least 2 clusters</li><li>One for deployment</li><li>One backup dedicated cluster that runs MinIO and reachable from the Deployment cluster</li><li>Using mac as your local machine</li><li>Helm installed</li><li>Homebrew installed</li></ul><p>In this installl we use velero helm chart provided by vmware-tanzu?</p><h3>Why vmware-tanzu?</h3><ul><li>It exposes a lot of settings that you can set to suit your needs</li><li>It is Owned by VMware itself(Velero Author)</li><li>Recommended by Velero official website</li></ul><p>Using the provided helm chat, we can install it now</p><h3>Set up Velero</h3><h3>Local Machine set up [Mac OS]</h3><p>Install Velero CLI</p><pre>brew install velero</pre><h3>Installation on ubuntu</h3><pre>wget https://github.com/vmware-tanzu/velero/releases/download/v1.2.0/velero-v1.2.0-linux-amd64.tar.gz<br>tar -zxvf velero-v1.2.0-linux-amd64.tar.gz<br>sudo mv velero-v1.2.0-linux-amd64/velero /usr/local/bin/</pre><h3>Backup Cluster</h3><p>Make sure that MinIO is accessible from the outside</p><h3>Set up on deployment Cluster</h3><p>Next we need to install Velero server on both of our clusters. There is basically multiple ways we can achieve this but we are going to use helm chart provided by vmware-tanzu.</p><p><strong><em>1st</em> Option [tested]</strong></p><p>using yaml file</p><pre>helm install velero vmware-tanzu/velero --namespace velero -f values.yaml</pre><p>NB: This values.yaml file is attached below with values already set [with a daily backup] or you can download it from <a href="https://github.com/vmware-tanzu/helm-charts/tree/main/charts/velero">github</a> and adjust it to suit your needs</p><p><strong><em>2nd</em> Option [yet to be tested]</strong></p><p>Install it with key value pair / you should note that these are the same values set in the values.yaml described above</p><ul><li>Without values</li></ul><pre>helm install velero vmware-tanzu/velero \\<br>--namespace &lt;YOUR NAMESPACE&gt; \\<br>--create-namespace \\<br>--set-file credentials.secretContents.cloud=&lt;FULL PATH TO FILE&gt; \\<br>--set configuration.provider=&lt;PROVIDER NAME&gt; \\<br>--set configuration.backupStorageLocation.name=&lt;BACKUP STORAGE LOCATION NAME&gt; \\<br>--set configuration.backupStorageLocation.bucket=&lt;BUCKET NAME&gt; \\<br>--set configuration.backupStorageLocation.config.region=&lt;REGION&gt; \\<br>--set configuration.volumeSnapshotLocation.name=&lt;VOLUME SNAPSHOT LOCATION NAME&gt; \\<br>--set configuration.volumeSnapshotLocation.config.region=&lt;REGION&gt; \\<br>--set initContainers[0].name=velero-plugin-for-&lt;PROVIDER NAME&gt; \\<br>--set initContainers[0].image=velero/velero-plugin-for-&lt;PROVIDER NAME&gt;:&lt;PROVIDER PLUGIN TAG&gt; \\<br>--set initContainers[0].volumeMounts[0].mountPath=/target \\<br>--set initContainers[0].volumeMounts[0].name=plugins</pre><ul><li>With values</li></ul><pre>helm install velero vmware-tanzu/velero \\<br>--namespace velero \\<br>--create-namespace \\<br>--set-file credentials.secretContents.cloud=credentials-velero \\<br>--set configuration.provider=aws \\<br>--set configuration.backupStorageLocation.name=minio-bucket \\<br>--set configuration.backupStorageLocation.bucket=velero \\<br>--set configuration.backupStorageLocation.config.region=minio \\<br>--set configuration.volumeSnapshotLocation.name=minio-volume-bucket \\<br>--set configuration.volumeSnapshotLocation.config.region=minio \\<br>--set initContainers[0].image=velero/velero-plugin-for-aws:v1.2.1 \\<br>--set initContainers[0].volumeMounts[0].mountPath=/target \\<br>--set initContainers[0].volumeMounts[0].name=plugins</pre><p>NB: credentials-velero is file which contains the following content and should be in the location from where you are running this command</p><pre>[default]<br>aws_access_key_id = [minio access key]<br>aws_secret_access_key = [minio secret key]</pre><p><strong>NB:</strong> in case of migration or disaster recovery, you need to setup velero on the second server that you want restore your back up on</p><h3>Backup</h3><h3>Perform a backup</h3><p>(This is Done one the deployment cluster that you want to backup )</p><p>Create a backup all objects</p><pre>velero backup create backup-1</pre><p>Create a backup for any object that matches the backup=tier-1 label selector:</p><pre>velero backup create backup-2 --selector backup=tier-1</pre><p>Create regularly scheduled backups based on a cron expression</p><pre>velero schedule create backup-daily --schedule=&quot;0 1 * * *&quot;</pre><p>Alternatively, you can use some non-standard shorthand cron expressions:</p><pre>velero schedule create backup-daily --schedule=&quot;@daily&quot;</pre><h3>Types of backups</h3><h3>On-demand backups</h3><p>The <strong>backup</strong> operation:</p><ol><li>Uploads a tarball of copied Kubernetes objects into cloud object storage.</li><li>Calls the cloud provider API to make disk snapshots of persistent volumes, if specified.</li></ol><p>You can optionally specify backup hooks to be executed during the backup. For example, you might need to tell a database to flush its in-memory buffers to disk before taking a snapshot. <a href="https://velero.io/docs/v1.8/backup-hooks/">More about backup hooks</a>.</p><p>Note that cluster backups are not strictly atomic. If Kubernetes objects are being created or edited at the time of backup, they might not be included in the backup. The odds of capturing inconsistent information are low, but it is possible.</p><p>&lt;aside&gt; 💡 When making changes on a cluster, there is always a possibility that something might go wrong. which is why on-demand backup will help you to restore to the previous version If all goes to hell</p><p>&lt;/aside&gt;</p><h3>Scheduled backups</h3><p>The <strong>schedule</strong> operation allows you to back up your data at recurring intervals. You can create a scheduled backup at any time, and the first backup is then performed at the schedule’s specified interval. These intervals are specified by a Cron expression.</p><p>Velero saves backups created from a schedule with the name &lt;SCHEDULE NAME&gt;-&lt;TIMESTAMP&gt;, where &lt;TIMESTAMP&gt; is formatted as <em>YYYYMMDDhhmmss</em>. For more information see the <a href="https://velero.io/docs/v1.8/backup-reference/">Backup Reference documentation</a>.</p><p>&lt;aside&gt; 💡 Since we can backup on namesapace basis or label selector, we can backup deferent resources based on how critical they as well as how often they are updated. This type is perfect for that use</p><p>&lt;/aside&gt;</p><h3>Restoration</h3><p>(This can be done on the deployment cluster itself or to a fresh new cluster, in that case make sure that Velero server is also installed and both BackupStorageLocations and VolumeSnapshotLocations objects which can be done by basically installing velero on this cluster the same way you did on the original cluster)</p><p>On the cluster where you want to restore your data</p><p><strong>Restoration procedure</strong></p><p>Update your backup storage location to read-only mode (this prevents backup objects from being created or deleted in the backup storage location during the restore process):</p><pre>kubectl patch backupstoragelocation &lt;STORAGE LOCATION NAME&gt; \\<br>	--namespace velero \\<br>	--type merge \\<br>	--patch &#39;{&quot;spec&quot;:{&quot;accessMode&quot;:&quot;ReadOnly&quot;}}&#39;</pre><h3>Restoration</h3><p>List all available backups</p><pre>veleri get backups</pre><p>Restore back to one backup</p><p><strong>Note</strong> that if a resource already exists, it will not be overwritten, instead you will get an error that tells you that it already exists</p><pre>velero restore create --from-backup backup-1</pre><p>When ready, revert your backup storage location to read-write mode:</p><pre>kubectl patch backupstoragelocation &lt;STORAGE LOCATION NAME&gt; \\<br>   --namespace velero \\<br>   --type merge \\<br>   --patch &#39;{&quot;spec&quot;:{&quot;accessMode&quot;:&quot;ReadWrite&quot;}}&#39;</pre><p>Now the cluster should be the same as the original cluster the time you did the backup backup-1</p><h3>Set a backup to expire</h3><p>When you create a backup, you can specify a TTL (time to live) by adding the flag --ttl &lt;DURATION&gt;. If Velero sees that an existing backup resource is expired, it removes:</p><ul><li>The backup resource</li><li>The backup file from cloud object storage</li><li>All PersistentVolume snapshots</li><li>All associated Restores</li></ul><p>The TTL flag allows the user to specify the backup retention period with the value specified in hours, minutes and seconds in the form --ttl 24h0m0s. If not specified, a default TTL value of 30 days will be applied.</p><h3>Backup workflow</h3><p>When you run velero backup create test-backup:</p><ol><li>The Velero client makes a call to the Kubernetes API server to create a Backup object.</li><li>The BackupController notices the new Backup object and performs validation.</li><li>The BackupController begins the backup process. It collects the data to back up by querying the API server for resources.</li><li>The BackupController makes a call to the object storage service – for example, AWS S3 – to upload the backup file.</li></ol><p>By default, velero backup create makes disk snapshots of any persistent volumes. You can adjust the snapshots by specifying additional flags. Run velero backup create --help to see available flags. Snapshots can be disabled with the option --snapshot-volumes=false.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/771/1*7_CFuEW9QyV_jGiI0LGScw.png" /><figcaption><em>Source: Velero official website</em></figcaption></figure><h4>Restic</h4><p>Restic does a file system level backup which can be stored on any kind of provider with easy</p><h3>Metrics</h3><p>By default metrics are exposed for prometheus pull, [Tests are yet to be done]</p><h3>Security</h3><p>Even though Velero itself does not encrypt backups it can be addressed in two ways.</p><ul><li>If we use restic, we do a filesystem level backup which mitigates issue of data accessed on transit</li><li>Since it is going to be done over a private network, we have a guarantee that it will not not be intercepted on transit or on the cluster where the backups reside</li></ul><h3>Disclaimer</h3><p>&lt;aside&gt; 💡 Velero’s AWS Object Store plugin uses <a href="https://github.com/aws/aws-sdk-go/aws">Amazon’s Go SDK</a> to connect to the AWS S3 API. Some third-party storage providers also support the S3 API, and MinIO is one of them and has been reported by other people to work. however it is not officially supported by Velero team.</p><p>&lt;/aside&gt;</p><p>&lt;aside&gt; 💡 <em>Note that MinIO is not regularly tested by the Velero team.</em></p><p>&lt;/aside&gt;</p><h3>Limitations</h3><ul><li>Each Velero backup has one BackupStorageLocation, and one VolumeSnapshotLocation per volume provider. It is not possible (yet) to send a single Velero backup to multiple backup storage locations simultaneously, or a single volume snapshot to multiple locations simultaneously. However, you can always set up multiple scheduled backups that differ only in the storage locations used if redundancy of backups across locations is important.</li></ul><h3>Work in Progress</h3><ul><li>Prometheus tests</li></ul><p>Resources</p><ol><li>Official website: <a href="https://velero.io/">https://velero.io/</a></li><li>VMware-tanzu github repo <a href="https://github.com/vmware-tanzu/helm-charts.git">https://github.com/vmware-tanzu/helm-charts.git</a></li><li>How restic works with velero <a href="https://github.com/vmware-tanzu/velero/blob/main/site/content/docs/main/restic.md">https://github.com/vmware-tanzu/velero/blob/main/site/content/docs/main/restic.md</a></li></ol><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b4da43c2a70" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Backup and restoration (Kasten/k10 vs velero)]]></title>
            <link>https://medium.com/@rugambaodilo/backup-and-restoration-kasten-k10-vs-velero-edb55c506c82?source=rss-48fcaacad0a7------2</link>
            <guid isPermaLink="false">https://medium.com/p/edb55c506c82</guid>
            <dc:creator><![CDATA[Rugamba Odilo]]></dc:creator>
            <pubDate>Mon, 26 Sep 2022 15:41:48 GMT</pubDate>
            <atom:updated>2022-09-26T15:41:48.210Z</atom:updated>
            <content:encoded><![CDATA[<p>This document makes a comparison between Velero and Kasten for kubernetes backups</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/7135ef020f74f108f140675895e57d84/href">https://medium.com/media/7135ef020f74f108f140675895e57d84/href</a></iframe><h3>Resources</h3><p>Velero: <a href="https://velero.io/docs/v1.8/">https://velero.io/docs/v1.8/</a></p><p>Kasten: <a href="https://docs.kasten.io/latest/">https://docs.kasten.io/latest/</a></p><p><a href="https://www.baculasystems.com/blog/kubernetes-backup/">https://www.baculasystems.com/blog/kubernetes-backup/</a></p><p><a href="https://containerjournal.com/editorial-calendar/best-of-2021/disaster-recovery-for-kubernetes/">https://containerjournal.com/editorial-calendar/best-of-2021/disaster-recovery-for-kubernetes/</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=edb55c506c82" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Linkerd, A service mesh giving Istio a run for its money]]></title>
            <link>https://medium.com/@rugambaodilo/linkerd-a-service-mesh-giving-istio-a-run-for-its-money-2fea6368e25d?source=rss-48fcaacad0a7------2</link>
            <guid isPermaLink="false">https://medium.com/p/2fea6368e25d</guid>
            <dc:creator><![CDATA[Rugamba Odilo]]></dc:creator>
            <pubDate>Mon, 26 Sep 2022 15:16:33 GMT</pubDate>
            <atom:updated>2022-09-26T15:16:33.509Z</atom:updated>
            <content:encoded><![CDATA[<h3>Summary</h3><p>According to the official website Linkerd is a *service mesh* for Kubernetes. It makes running services easier and safer by giving you runtime debugging, observability, reliability, and security—all without requiring any changes to your code.</p><h3>Architecture</h3><p>Linkerd has three basic components: a UI, a <em>data plane</em>, and a <em>control plane</em>. You run Linkerd by:</p><ol><li>Installing the CLI on your local system;</li><li>Installing the control plane into your cluster;</li><li>Adding your services to Linkerd’s data plane.</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*YpHqZQ0I4xwcRVEf4bxXZw.png" /></figure><h3>Setup</h3><p>Linkerd can be deployed on an existing cluster with services already running and add services(mesh) to Linkerd data plane or on fresh new cluster and add each service as they come.</p><h3>Prerequisite</h3><p>For the purpose of this setup we assume the following:</p><ol><li>Homebrew installed</li><li>Kubectl</li></ol><h3>Install Linkerd CLI</h3><pre>brew install linkerd</pre><p><strong>Check if installed correctly</strong></p><pre>linkerd version</pre><h3>Install the control plane onto your cluster</h3><h3>Validate your Kubernetes cluster</h3><p>Kubernetes clusters can be configured in many different ways. Before we can install the Linkerd control plane, we need to check and validate that everything is configured correctly. To check that your cluster is ready to install Linkerd, run:</p><pre>linkerd check --pre</pre><p>If there are any checks that do not pass, make sure to follow the provided links and fix those issues before proceeding.</p><h3>Install control plane</h3><pre>linkerd install | kubectl apply -f -</pre><p>wait for a few minutes to check if it is fully installed</p><pre>linkerd check</pre><p>And Voila! Linkerd in setup for us to use. However, it is not doing anything yet, we have to activate linkerd on services (mesh them) for it to work with them.</p><h3>Mesh services</h3><p>If you have a service deployed on your cluster, we’re ready to <em>mesh</em> it — that is, to add Linkerd’s data plane proxies to it. We can do this on a live application without downtime, thanks to Kubernetes’s rolling deploys. Mesh your app by running</p><pre>kubectl get -n &lt;NAMESPACE&gt; deploy -o yaml \\<br>  | linkerd inject - \\<br>  | kubectl apply -f -</pre><p>This command retrieves all of the deployments running in the your namespace, runs their manifests through linkerd inject, and then reapplies it to the cluster. (The linkerd inject command simply adds annotations to the pod spec that instruct Linkerd to inject the proxy into the pods when they are created.)</p><p>As with install, inject is a pure text operation, meaning that you can inspect the input and output before you use it. Once piped into kubectl apply, Kubernetes will execute a rolling deploy and update each pod with the data plane’s proxies.</p><p>You can mesh just one deployment at a time as well</p><pre>cat deployment.yml | linkerd inject - | kubectl apply -f -</pre><p>This is enough for services that use HTTP connection, for non-HTTP we need more configuration**[To Be Worked On]**.</p><p>Even though linkerd is installed, our services are meshed, and working now we need to visualize it in action. we can use an extension called viz, which will install an on-cluster metric stack and dashboard.</p><p>To install the viz extension, run:</p><pre>linkerd viz install | kubectl apply -f - # install the on-cluster metrics stack</pre><p>Once you’ve installed the extension, let’s validate everything one last time:</p><pre>linkerd check</pre><p>With the control plane and extensions installed and running, we’re now ready to explore Linkerd! Access the dashboard with:</p><pre>linkerd viz dashboard &amp;</pre><h3>Monitoring</h3><p>By design, Linkerd only keeps metrics data for a short, fixed window of time (currently, 6 hours). This means that if Linkerd’s metrics data is valuable to you, you will probably want to export it into a full-fledged metrics store.</p><ul><li><a href="https://linkerd.io/2.11/tasks/exporting-metrics/">https://linkerd.io/2.11/tasks/exporting-metrics/</a></li><li><a href="https://linkerd.io/2.11/tasks/grafana/#hook-grafana-with-linkerd-viz-dashboard">https://linkerd.io/2.11/tasks/grafana/#hook-grafana-with-linkerd-viz-dashboard</a></li></ul><h3>High availability</h3><p>For production workloads, Linkerd’s control plane can run in high availability (HA) mode. This mode:</p><ul><li>Runs three replicas of critical control plane components.</li><li>Sets production-ready CPU and memory resource requests on control plane components.</li><li>Sets production-ready CPU and memory resource requests on data plane proxies</li><li><em>Requires</em> that the <a href="https://linkerd.io/2.11/features/proxy-injection/">proxy auto-injector</a> be functional for any pods to be scheduled.</li><li>Sets <a href="https://kubernetes.io/docs/concepts/configuration/assign-pod-node/#affinity-and-anti-affinity">anti-affinity policies</a> on critical control plane components to ensure, if possible, that they are scheduled on separate nodes and in separate zones by default.</li><li><a href="https://linkerd.io/2.11/features/ha/">https://linkerd.io/2.11/features/ha/</a></li></ul><h3>Security</h3><p><strong>Automatic mTLS</strong></p><p>By default, Linkerd automatically enables mutually-authenticated Transport Layer Security (mTLS) for all TCP traffic between meshed pods. This means that Linkerd adds authenticated, encrypted communication to your application with no extra work on your part. (And because the Linkerd control plane also runs on the data plane, this means that communication between Linkerd’s control plane components are also automatically secured via mTLS</p><p>Secure non-TCP traffic. <a href="https://linkerd.io/2.11/features/automatic-mtls/">https://linkerd.io/2.11/features/automatic-mtls/</a></p><h3>Business Model</h3><p>Linkerd project is open source, and it leaves of donations of its community (to be verified)</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2fea6368e25d" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Kubernetes testing environment]]></title>
            <link>https://medium.com/@rugambaodilo/kubernetes-testing-environment-88b9c689ad79?source=rss-48fcaacad0a7------2</link>
            <guid isPermaLink="false">https://medium.com/p/88b9c689ad79</guid>
            <dc:creator><![CDATA[Rugamba Odilo]]></dc:creator>
            <pubDate>Mon, 26 Sep 2022 15:10:29 GMT</pubDate>
            <atom:updated>2022-09-26T15:53:11.669Z</atom:updated>
            <content:encoded><![CDATA[<h3>First install kubectl</h3><p>for MacOS (using Homebrew cask)</p><pre>brew install kubectl</pre><p>For Linux</p><pre>curl -LO &quot;https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt&gt;)/bin/linux/amd64/kubectl&quot;<br>sudo install -o root -g root -m 0755 kubectl /usr/local/bin/kubectl</pre><h3>1. Docker Desktop</h3><p>Install docker desktop</p><p>MacOS</p><pre>brew cask install docker</pre><p>Linux</p><pre># download<br>curl https://desktop.docker.com/linux/main/amd64/docker-desktop-4.8.1-amd64.deb --output docker-desktop.deb</pre><pre># install<br>sudo apt install ./docker-desktop.deb</pre><pre>systemctl --user start docker-desktop<br>systemctl --user enable docker-desktop</pre><pre># review logs<br>journalctl --user --unit=docker-desktop</pre><p>Navigate to settings &gt; kubernets and check Enable kubernets the click on Apply &amp; Restart</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*0PU9CcVncXcINhxK" /></figure><h3>Business Model</h3><p>It was developed by docker, they do not charge for it but this keep people in the eco-system</p><h3>2. Minikube</h3><p>official website</p><p><a href="https://minikube.sigs.k8s.io/docs/start/">https://minikube.sigs.k8s.io/docs/start/</a></p><p>MacOS</p><pre>curl -LO https://storage.googleapis.com/minikube/releases/latest/minikube-darwin-amd64<br>sudo install minikube-darwin-amd64 /usr/local/bin/minikube</pre><p>Linux</p><pre>curl -LO https://storage.googleapis.com/minikube/releases/latest/minikube_latest_amd64.deb<br>sudo dpkg -i minikube_latest_amd64.deb</pre><p>Create a cluster with 2 nodes</p><pre>minikube start --nodes 2 -p multinode-demo</pre><h3>Manage your cluster</h3><p>Pause Kubernetes without impacting deployed applications:</p><pre>minikube pause</pre><p>Unpause a paused instance:</p><pre>minikube unpause</pre><p>Halt the cluster:</p><pre>minikube stop</pre><p>Increase the default memory limit (requires a restart):</p><pre>minikube config set memory 16384</pre><p>Browse the catalog of easily installed Kubernetes services:</p><pre>minikube addons list</pre><p>Create a second cluster running an older Kubernetes release:</p><pre>minikube start -p aged --kubernetes-version=v1.16.1</pre><p>Delete all of the minikube clusters:</p><pre>minikube delete --all</pre><h3>3. KinD</h3><p>install kind</p><p>MacOS</p><pre>brew install kind</pre><p>Linux</p><pre>curl -Lo ./kind https://kind.sigs.k8s.io/dl/v0.13.0/kind-linux-amd64<br>chmod +x ./kind<br>mv ./kind /some-dir-in-your-PATH/kind</pre><p>config file</p><pre>cat &lt;&lt;EOF | sudo tee kind-cluster-config.yaml<br># a cluster with 1 control-plane nodes and 3 workers<br># this config file contains all config fields with comments<br>kind: Cluster<br>apiVersion: kind.x-k8s.io/v1alpha4<br># 1 control plane node and 3 workers<br>nodes:<br>  # the control plane node config<br>  - role: control-plane<br>    kubeadmConfigPatches:<br>    - |<br>      kind: InitConfiguration<br>      nodeRegistration:<br>        kubeletExtraArgs:<br>          node-labels: &quot;ingress-ready=true&quot;<br>          authorization-mode: &quot;AlwaysAllow&quot;<br>    extraPortMappings:<br>    - containerPort: 80<br>      hostPort: 80<br>      protocol: TCP<br>      listenAddress: &quot;0.0.0.0&quot;<br>    - containerPort: 443<br>      hostPort: 443<br>      protocol: TCP<br>      listenAddress: &quot;0.0.0.0&quot;<br>  # number of workers<br>  - role: worker<br>  - role: worker<br>  - role: worker<br>EOF</pre><p>Create a cluster</p><pre>kind create cluster --image=kindest/node:v1.21.2 --config kind-cluster-config.yaml --name=solr-cluster-1</pre><p>Official website</p><p><a href="https://kind.sigs.k8s.io/">https://kind.sigs.k8s.io/</a></p><p>ssh into one of the nodes</p><p>First get the NAME</p><pre>kubectl get nodes</pre><p>Now ssh in the node using one of the names</p><pre>docker exec -it &lt;NAME&gt; sh<br># docker exec -it kind-control-plane sh</pre><h3>Business Model</h3><p>It is free, it was made and supported by Kubernetes project itself</p><h3>4. Kubespray with vagrant on Virtual machines</h3><p>(Working on the documentation of this one, I find it so interesting since It allows you to replicate your production environment to almost any specification you can think of)</p><h3>Business model</h3><p>It is free, well, I packaged it myself using open source projects and I am not charging you for it, but if you want support I would charge you.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=88b9c689ad79" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Kubernetes ingress controller, Logging the Client real IP address.]]></title>
            <link>https://medium.com/@rugambaodilo/kubernetes-ingress-controller-logging-the-client-real-ip-address-6e51f64d39a3?source=rss-48fcaacad0a7------2</link>
            <guid isPermaLink="false">https://medium.com/p/6e51f64d39a3</guid>
            <dc:creator><![CDATA[Rugamba Odilo]]></dc:creator>
            <pubDate>Mon, 26 Sep 2022 14:56:32 GMT</pubDate>
            <atom:updated>2022-09-26T14:56:32.614Z</atom:updated>
            <content:encoded><![CDATA[<p>A couple days ago I was tasked to get the real client IP on logs, and unsurprisingly this proved to be challenge.</p><p><strong>Background: </strong>For security and other data analytics purposes we wanted to get the real client IP in logs instead of some SNATed IP that we were getting by default from <strong>Kubernetes</strong> ingress controller logs</p><p>After Some settings recommended by the ingress controller, Kubernetes and stack-overflow(Duh!), I narrowed it down to externalTrafficPolicy which could be set to either <strong>Local</strong> or <strong>Cluster</strong>.</p><p>Unfortunately, when I set it to cluster we could not get the real IP and when I set it to Local our reverse proxy was not working anymore. This has also been dug <a href="https://groups.google.com/g/kubernetes-users/c/HOaGQD4J8j0">deeper into by these thread</a></p><p>Then the day of presenting my work came, I struggled to explain why this was the case. So here are my notes for the second attempt at explaining it to the team.</p><h3>Routing</h3><p><strong>Cluster: </strong>The service load balances any request to the whole cluster.</p><p><strong>Local: </strong>The service only loads balances locally to the node that received the request and when there is no pod to handle the traffic the request gets dropped.</p><p><strong>Question?:</strong> But why does it work only for the traffic coming from outside? That is because they go through kube-proxy which knows which nodes have the pods/backend but when the traffic is coming from one of the cluster’s nodes it does not go through kube-proxy. instead it is handled locally, hence can’t find the pod and gets dropped</p><h3>Logged-IP</h3><p><strong>Cluster:</strong> To achieve this, the request gets SNATed and load balanced to another pod and/or another node. Hence, on logs you see the IP of the node that re-routed the request(or rather the network address of that node) instead of the client IP.</p><p><strong>Local: </strong>Since the node that received the request is the one that responds, there is no need for SNATing. Hence, you get the real client IP.</p><h3>Pros &amp; Cons of Cluster</h3><p><strong>Pros: </strong>Our traffic gets balanced equally between pods.</p><p><strong>Cons: </strong>We are not able to see where the traffic is coming from.</p><h3>Pros &amp; Cons of Local</h3><p><strong>Pros: </strong>We are able to see where the traffic is coming from.</p><p><strong>Cons: </strong>Our traffic is only load balanced between nodes not pods which means that if we have 3 pods on node A and 1 pod on node B, 50% of the traffic will go node A and 50% to node B even if node A has 3 pods and node B has only 1.</p><p>I would appreciate anyone to challenge my understanding of this. Plz Plz!</p><p>Wish me luck.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=6e51f64d39a3" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>