<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>SRE on Eri Bastos</title>
    <link>https://ebastos.dev/categories/sre/</link>
    <description>Recent content in SRE on Eri Bastos</description>
    <generator>Hugo</generator>
    <language>en-us</language>
    <lastBuildDate>Sun, 09 Aug 2026 00:00:00 +0000</lastBuildDate>
    <atom:link href="https://ebastos.dev/categories/sre/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>Optimize for Happiness</title>
      <link>https://ebastos.dev/2026/08/optimize-for-happiness/</link>
      <pubDate>Sun, 09 Aug 2026 00:00:00 +0000</pubDate>
      <guid>https://ebastos.dev/2026/08/optimize-for-happiness/</guid>
      <description>&lt;div class=&#34;audio-player&#34;&gt;&#xA;  &lt;div class=&#34;audio-player-header&#34;&gt;&#xA;    &lt;svg class=&#34;audio-player-icon&#34; viewBox=&#34;0 0 24 24&#34; fill=&#34;none&#34; stroke=&#34;currentColor&#34; stroke-width=&#34;2&#34; stroke-linecap=&#34;round&#34; stroke-linejoin=&#34;round&#34;&gt;&#xA;      &lt;path d=&#34;M3 18v-6a9 9 0 0 1 18 0v6&#34;/&gt;&#xA;      &lt;path d=&#34;M21 19a2 2 0 0 1-2 2h-1a2 2 0 0 1-2-2v-3a2 2 0 0 1 2-2h3zM3 19a2 2 0 0 0 2 2h1a2 2 0 0 0 2-2v-3a2 2 0 0 0-2-2H3z&#34;/&gt;&#xA;    &lt;/svg&gt;&#xA;    &lt;span class=&#34;audio-player-label&#34;&gt;Listen to this post&lt;/span&gt;&#xA;  &lt;/div&gt;&#xA;  &lt;div class=&#34;audio-player-controls&#34;&gt;&#xA;    &lt;button class=&#34;audio-play-btn&#34; aria-label=&#34;Play audio&#34;&gt;&#xA;      &lt;svg class=&#34;audio-icon-play&#34; viewBox=&#34;0 0 24 24&#34; fill=&#34;currentColor&#34;&gt;&lt;polygon points=&#34;5,3 19,12 5,21&#34;/&gt;&lt;/svg&gt;&#xA;      &lt;svg class=&#34;audio-icon-pause&#34; viewBox=&#34;0 0 24 24&#34; fill=&#34;currentColor&#34;&gt;&lt;rect x=&#34;6&#34; y=&#34;4&#34; width=&#34;4&#34; height=&#34;16&#34;/&gt;&lt;rect x=&#34;14&#34; y=&#34;4&#34; width=&#34;4&#34; height=&#34;16&#34;/&gt;&lt;/svg&gt;&#xA;    &lt;/button&gt;&#xA;    &lt;span class=&#34;audio-time audio-time-current&#34;&gt;0:00&lt;/span&gt;&#xA;    &lt;div class=&#34;audio-progress-wrap&#34;&gt;&#xA;      &lt;div class=&#34;audio-progress-bar&#34;&gt;&#xA;        &lt;div class=&#34;audio-progress-fill&#34;&gt;&lt;/div&gt;&#xA;      &lt;/div&gt;&#xA;      &lt;input type=&#34;range&#34; class=&#34;audio-progress-input&#34; min=&#34;0&#34; max=&#34;100&#34; value=&#34;0&#34; step=&#34;0.1&#34; aria-label=&#34;Seek audio&#34;&gt;&#xA;    &lt;/div&gt;&#xA;    &lt;span class=&#34;audio-time audio-time-duration&#34;&gt;0:00&lt;/span&gt;&#xA;    &lt;div class=&#34;audio-volume-wrap&#34;&gt;&#xA;      &lt;button class=&#34;audio-volume-btn&#34; aria-label=&#34;Toggle mute&#34;&gt;&#xA;        &lt;svg class=&#34;audio-icon-volume&#34; viewBox=&#34;0 0 24 24&#34; fill=&#34;none&#34; stroke=&#34;currentColor&#34; stroke-width=&#34;2&#34; stroke-linecap=&#34;round&#34; stroke-linejoin=&#34;round&#34;&gt;&#xA;          &lt;polygon points=&#34;11,5 6,9 2,9 2,15 6,15 11,19&#34; fill=&#34;currentColor&#34;/&gt;&#xA;          &lt;path d=&#34;M15.54 8.46a5 5 0 0 1 0 7.07&#34;/&gt;&#xA;          &lt;path d=&#34;M19.07 4.93a10 10 0 0 1 0 14.14&#34;/&gt;&#xA;        &lt;/svg&gt;&#xA;        &lt;svg class=&#34;audio-icon-muted&#34; viewBox=&#34;0 0 24 24&#34; fill=&#34;none&#34; stroke=&#34;currentColor&#34; stroke-width=&#34;2&#34; stroke-linecap=&#34;round&#34; stroke-linejoin=&#34;round&#34;&gt;&#xA;          &lt;polygon points=&#34;11,5 6,9 2,9 2,15 6,15 11,19&#34; fill=&#34;currentColor&#34;/&gt;&#xA;          &lt;line x1=&#34;23&#34; y1=&#34;9&#34; x2=&#34;17&#34; y2=&#34;15&#34;/&gt;&#xA;          &lt;line x1=&#34;17&#34; y1=&#34;9&#34; x2=&#34;23&#34; y2=&#34;15&#34;/&gt;&#xA;        &lt;/svg&gt;&#xA;      &lt;/button&gt;&#xA;    &lt;/div&gt;&#xA;  &lt;/div&gt;&#xA;  &lt;audio class=&#34;audio-element&#34; preload=&#34;metadata&#34; src=&#34;https://ebastos.dev/uploads/audio/optimize_for_happiness.mp3&#34;&gt;&lt;/audio&gt;&#xA;&lt;/div&gt;&#xA;&lt;script&gt;&#xA;(function(){&#xA;  var player = document.currentScript.previousElementSibling;&#xA;  var audio = player.querySelector(&#39;.audio-element&#39;);&#xA;  var playBtn = player.querySelector(&#39;.audio-play-btn&#39;);&#xA;  var iconPlay = player.querySelector(&#39;.audio-icon-play&#39;);&#xA;  var iconPause = player.querySelector(&#39;.audio-icon-pause&#39;);&#xA;  var timeCurrent = player.querySelector(&#39;.audio-time-current&#39;);&#xA;  var timeDuration = player.querySelector(&#39;.audio-time-duration&#39;);&#xA;  var progressFill = player.querySelector(&#39;.audio-progress-fill&#39;);&#xA;  var progressInput = player.querySelector(&#39;.audio-progress-input&#39;);&#xA;  var volumeBtn = player.querySelector(&#39;.audio-volume-btn&#39;);&#xA;  var iconVolume = player.querySelector(&#39;.audio-icon-volume&#39;);&#xA;  var iconMuted = player.querySelector(&#39;.audio-icon-muted&#39;);&#xA;&#xA;  function formatTime(s){&#xA;    if(!s || isNaN(s)) return &#39;0:00&#39;;&#xA;    var m = Math.floor(s/60);&#xA;    var sec = Math.floor(s%60);&#xA;    return m+&#39;:&#39;+(sec&lt;10?&#39;0&#39;:&#39;&#39;)+sec;&#xA;  }&#xA;&#xA;  playBtn.addEventListener(&#39;click&#39;, function(){&#xA;    if(audio.paused){&#xA;      audio.play();&#xA;    } else {&#xA;      audio.pause();&#xA;    }&#xA;  });&#xA;&#xA;  audio.addEventListener(&#39;play&#39;, function(){&#xA;    iconPlay.style.display=&#39;none&#39;;&#xA;    iconPause.style.display=&#39;block&#39;;&#xA;  });&#xA;  audio.addEventListener(&#39;pause&#39;, function(){&#xA;    iconPlay.style.display=&#39;block&#39;;&#xA;    iconPause.style.display=&#39;none&#39;;&#xA;  });&#xA;&#xA;  audio.addEventListener(&#39;loadedmetadata&#39;, function(){&#xA;    timeDuration.textContent = formatTime(audio.duration);&#xA;    progressInput.max = audio.duration || 100;&#xA;  });&#xA;&#xA;  audio.addEventListener(&#39;timeupdate&#39;, function(){&#xA;    if(!audio.duration) return;&#xA;    timeCurrent.textContent = formatTime(audio.currentTime);&#xA;    var pct = (audio.currentTime / audio.duration)*100;&#xA;    progressFill.style.width = pct+&#39;%&#39;;&#xA;    progressInput.value = audio.currentTime;&#xA;  });&#xA;&#xA;  progressInput.addEventListener(&#39;input&#39;, function(){&#xA;    audio.currentTime = parseFloat(this.value);&#xA;  });&#xA;&#xA;  var lastVolume = 1;&#xA;  volumeBtn.addEventListener(&#39;click&#39;, function(){&#xA;    if(audio.muted || audio.volume === 0){&#xA;      audio.muted = false;&#xA;      audio.volume = lastVolume || 1;&#xA;    } else {&#xA;      lastVolume = audio.volume;&#xA;      audio.muted = true;&#xA;    }&#xA;    updateVolumeIcon();&#xA;  });&#xA;&#xA;  function updateVolumeIcon(){&#xA;    var muted = audio.muted || audio.volume === 0;&#xA;    iconVolume.style.display = muted ? &#39;none&#39; : &#39;block&#39;;&#xA;    iconMuted.style.display = muted ? &#39;block&#39; : &#39;none&#39;;&#xA;  }&#xA;&#xA;  audio.addEventListener(&#39;ended&#39;, function(){&#xA;    iconPlay.style.display=&#39;block&#39;;&#xA;    iconPause.style.display=&#39;none&#39;;&#xA;    progressFill.style.width = &#39;0%&#39;;&#xA;    progressInput.value = 0;&#xA;    timeCurrent.textContent = &#39;0:00&#39;;&#xA;  });&#xA;})();&#xA;&lt;/script&gt;&#xA;&#xA;&lt;p&gt;The other day I was talking backups with a client. They had a solid custom script that compressed customer data into one large file and pushed it to object storage. One big compressed object is usually much faster to upload than thousands of small ones, so the backup finished sooner. That felt like a win.&lt;/p&gt;</description>
    </item>
  </channel>
</rss>
