<?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 Mattia Iaria on Medium]]></title>
        <description><![CDATA[Stories by Mattia Iaria on Medium]]></description>
        <link>https://medium.com/@mattia.iaria30?source=rss-69c0c4d6ace------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*koXcKlWFdImohPglOnQnSQ@2x.jpeg</url>
            <title>Stories by Mattia Iaria on Medium</title>
            <link>https://medium.com/@mattia.iaria30?source=rss-69c0c4d6ace------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sun, 06 Dec 2026 03:30:19 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@mattia.iaria30/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[Gitea: The Ultimate GitHub Alternative for Your Home Lab?]]></title>
            <link>https://medium.com/@mattia.iaria30/gitea-the-ultimate-github-alternative-for-your-home-lab-63bd1ebe3c80?source=rss-69c0c4d6ace------2</link>
            <guid isPermaLink="false">https://medium.com/p/63bd1ebe3c80</guid>
            <category><![CDATA[gitea]]></category>
            <category><![CDATA[ci-cd-pipeline]]></category>
            <category><![CDATA[devops]]></category>
            <dc:creator><![CDATA[Mattia Iaria]]></dc:creator>
            <pubDate>Mon, 18 May 2026 23:40:06 GMT</pubDate>
            <atom:updated>2026-05-18T23:40:06.678Z</atom:updated>
            <content:encoded><![CDATA[<blockquote>A lightweight, lightning-fast alternative to GitLab for Kubernetes home labs using Gitea Actions.</blockquote><p>I’ve recently discovered <strong>Gitea</strong>, a self-hosted Git service that is fully compatible with all Git features.</p><p>Written in Go, it is incredibly fast and lightweight. With a binary size of only ~100MB, it is the best choice if you have a home lab and don’t want to deal with the high RAM consumption and complex configuration of GitLab. <em>(Don’t get me wrong, GitLab is great for enterprises, but it can be overkill for smaller setups).</em></p><p>In addition to being lightweight, Gitea includes a built-in, highly practical <strong>Package Registry</strong> that allows you to host Docker images, npm packages, Maven artifacts, and more, right out of the box without needing an external registry.</p><p>Gitea is also very straightforward to configure. So today, we’re going to install it, host it in a <strong>k3s</strong> cluster, and run a complete CI/CD pipeline using its registry.</p><p>Another standout feature is that <strong>Gitea Actions</strong> is fully compatible with GitHub Actions, making the migration process incredibly smooth.</p><blockquote><em>🌐 For more details, you can check out the </em><a href="https://gitea.io/"><em>Gitea Official Website</em></a><em>.</em></blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*plrXyiVyTK4rP-Safq3E8w.png" /></figure><h3>Prerequirements</h3><ul><li><a href="https://www.docker.com/"><strong>docker</strong></a></li><li><a href="https://k3d.io/stable/#releases"><strong>k3d</strong></a></li><li><a href="https://helm.sh/it/"><strong>helm</strong></a></li></ul><p>You can download and review all the files and configuration in this <a href="https://github.com/mattia33011/gitea-k3d-demo">repository</a>.</p><blockquote>⚠️ <strong>N.B.</strong> Most of the commands listed in this guide will work <strong>only and exclusively</strong> if executed from the root folder of the repository. Make sure to clone the repo and navigate into it before starting!</blockquote><h4>Step 1: Setup a Local Cluster with k3d</h4><p>First, let’s spin up a local Kubernetes cluster simulating 3 nodes (1 server and 2 workers):</p><pre>k3d cluster create $CLUSTER \<br>  --servers 1 --agents 2 \<br>  --api-port 6550 \<br>  -p &#39;8080:80@loadbalancer&#39; \<br>  --volume /var/run/docker.sock:/var/run/docker.sock \<br>  --registry-use k3d-gitea-registry:5001</pre><p>Next, run the following command to add a specific label to one of the worker nodes. We will need this later for our runner deployment:</p><pre>kubectl label nodes k3d-gitea-cluster-agent-0 kind=gitea-runners</pre><h4>Step 2: Deploy Gitea using Helm</h4><p>Before installing Gitea, we need to create a Kubernetes secret to store our admin credentials securely:</p><pre>kubectl create secret generic gitea-admin-secret \<br>  --from-literal=username=&quot;gitea_admin&quot; \<br>  --from-literal=password=&quot;SecurePassword&quot; \<br>  --from-literal=email=&quot;admin@gitea.local&quot; \<br>  -n gitea</pre><p>Now, let’s add the official Gitea Helm repository:</p><pre># add helm repo<br>helm repo add gitea-charts https://dl.gitea.com/charts/</pre><p>To complete the deployment, I recommend using the customized <strong>gitea-helm-values.yaml</strong> provided in my <a href="https://github.com/mattia33011/gitea-k3d-demo">repository</a> for deployment:</p><pre># Install the chart<br> helm install gitea gitea-charts/gitea -n gitea -f gitea-helm-values.yaml --create-namespace</pre><blockquote>For this demo we are using 127.0.0.1.nip.io:8080 ingress, but you can use your host in production.</blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*sAkiW_WWr5j9SABE9I3D5A.png" /><figcaption>Gitea Home page</figcaption></figure><h4>Step 3: Configure <a href="https://docs.gitea.com/runner/0.2.11/">Gitea Runners</a></h4><p>Now that Gitea is up and running, let’s build, push, and deploy an application using a Gitea Action to see how easy it is to maintain!</p><ol><li>Log in to Gitea with your admin credentials by visiting <a href="http://127.0.0.1.nip.io:8080/">http://127.0.0.1.nip.io:8080/.</a></li><li>Go to the <strong>Admin Panel</strong>.</li><li>Click on the <strong>Actions</strong> tab.</li><li>Click on <strong>“Create new runner”</strong>.</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*7lsM2oMDBz79jXvN0OXM_g.png" /></figure><p>5. Copy the generated <strong>Gitea runner token</strong>.</p><p>6. Open your local runner.yaml file and paste the token into the designated field.</p><p>7. Apply the deployment manifest to your cluster.</p><p>8. Enjoy your new runner!</p><h4>Step 4: Create the runner service account</h4><p>To allow our runner to deploy applications to the cluster, we need to set up the correct permissions. You must apply the deployer-rbac.yaml manifest to create the necessary <strong>Role</strong>, <strong>RoleBinding</strong>, <strong>Secret</strong>, and <strong>Service Account</strong>.</p><p>Run the following command to apply the <strong>RBAC</strong> configurations:</p><pre>kubectl apply -f deployer-rbac.yaml</pre><p>After creating the service account, you need to generate a secure configuration file for it. Use the provided bash script generate_kubeconfig.sh to generate a base64-encoded kubeconfig string.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*9UAjjyYuzeFZZ599gHNMvQ.png" /></figure><p>Once generated, add this string to your Gitea repository secrets under the name <strong>KUBE_CONFIG</strong>:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*rvFoMNTV9SPXaLwqWAzdCw.png" /></figure><h3>Designing the CI/CD Workflow</h3><p>What workflow are we going to use? Here are the automated steps:</p><ol><li><strong>Download</strong> the base image with docker and kubectl.</li><li><strong>Checkout</strong> the repository.</li><li><strong>Build</strong> the Docker image.</li><li><strong>Push</strong> to the built-in Gitea registry.</li><li><strong>Deploy</strong> to K8s.</li></ol><p>First, create a new repository in your Gitea instance and push your first commit.</p><p>To get this workflow running, you need to add your Gitea package registry credentials to the repository secrets (in this case, we will use the admin credentials).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*hwDZNqsJrTOHlj1S-i_jrQ.png" /></figure><p>After saving the secrets, you can push your completely GitHub-compatible workflow! You can check the /repository folder in my GitHub repository to see a full example.</p><blockquote>⚠️ <strong>N.B.</strong> Now we are not using the Gitea package registry to keep simple the demo, we will use <a href="http://ttl.sh/">ttl.sh</a> a free registry with no authentication and self-destruction</blockquote><h3>Workflow Example in Action</h3><p>If you are using my workflow, you will see a pipeline split into 2 stages: <strong>Build and deploy</strong>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Bk2FWFWvwZk3Q4hYFAtfSw.png" /></figure><p>The <strong>build</strong> steps include:</p><ul><li>Setting up the job</li><li>Installing bash</li><li>Checking out the code</li><li>Logging into the Gitea Registry</li><li>Setting up Docker Buildx</li><li>Building and pushing the Docker Image</li></ul><figure><img alt="The steps are the following:" src="https://cdn-images-1.medium.com/max/309/1*lWQI3W_hHViV_on8E5OAaA.png" /></figure><p>Once the build and push steps complete successfully, they will automatically trigger the <strong>deploy</strong> stage.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*KAhYAY7XAFyQamslpHcCOg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*FwuDT-xFwWGxgP6wvf8qqg.png" /></figure><p>As you can see all the steps are checked, now it is deployed our application:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/618/1*nM5RP_Tf7XpqWnmK_4GKbg.png" /></figure><p>With a simple port-forward we can visit our brand-new application !</p><pre>kk port-forward svc/demo-app-svc 3000:80</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/801/1*OL_2jiX2UIasLyEi0irvHA.png" /><figcaption>Our awesome web site !</figcaption></figure><h3>Conclusion: Why Gitea Wins for Home Labs and Small Teams</h3><p>Let’s look back at what we’ve achieved today. In just a few steps, we have:</p><ol><li>Spun up a multi-node Kubernetes cluster locally using <strong>k3d</strong>.</li><li>Deployed <strong>Gitea</strong> using Helm charts with a minimal hardware footprint.</li><li>Connected a native <strong>Gitea Actions</strong> runner using safe Kubernetes RBAC permissions.</li><li>Orchestrated a full 2-stage <strong>CI/CD pipeline</strong> capable of building, pushing, and deploying a containerized application automatically.</li></ol><p>The beauty of this whole setup lies in its sheer efficiency. If we had tried to replicate this exact workflow using GitLab inside a modest home lab or a tiny corporate environment, our cluster nodes would likely be crying for more RAM right now.</p><p>Instead, Gitea gives you the best of both worlds:</p><ul><li><strong>Unmatched Lightweight Performance:</strong> With its tiny Go-based engine, it runs smoothly on almost any hardware without draining your resources.</li><li><strong>Dead-Simple Configuration:</strong> No complex architecture, no enterprise bloat — just a clean, straightforward UI and intuitive workflows.</li><li><strong>GitHub-Compatible Actions:</strong> You don’t need to learn a new pipeline syntax. If you know GitHub Actions, you already know Gitea Actions.</li></ul><p>Whether you are an engineer wanting to build a robust, low-maintenance staging environment in your <strong>home lab</strong>, or a <strong>small company</strong> looking for a cost-effective, self-hosted Git platform that doesn’t require an entire IT department to maintain, Gitea is an absolute game-changer.</p><p>It proves that you don’t need massive enterprise tools to get professional-grade DevOps automation.</p><h3>Special thanks</h3><p>I want to thank <strong>MorroLinux</strong>, an Italian tech influencer, for introducing me to this amazing tool.<br>This is his video: <a href="https://www.youtube.com/watch?v=qnrjoAlaVtA">https://www.youtube.com/watch?v=qnrjoAlaVtA</a></p><p><em>If you found this guide helpful, feel free to clap 👏 and follow for more DevOps and home lab content!</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=63bd1ebe3c80" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Build AI Agent Teams for Free using ADK and OpenRouter]]></title>
            <link>https://medium.com/@mattia.iaria30/build-ai-agent-teams-for-free-using-adk-and-openrouter-dca386b4db50?source=rss-69c0c4d6ace------2</link>
            <guid isPermaLink="false">https://medium.com/p/dca386b4db50</guid>
            <category><![CDATA[ai]]></category>
            <category><![CDATA[open-router]]></category>
            <category><![CDATA[ai-agent]]></category>
            <category><![CDATA[google-adk]]></category>
            <category><![CDATA[litellm]]></category>
            <dc:creator><![CDATA[Mattia Iaria]]></dc:creator>
            <pubDate>Tue, 13 Jan 2026 20:45:56 GMT</pubDate>
            <atom:updated>2026-01-13T20:45:56.140Z</atom:updated>
            <content:encoded><![CDATA[<p>Nowadays, AI agents are gaining significant traction globally, yet coordinating multiple agents to handle complex tasks has always been tricky.<br>Today, we’ll aim to solve this by using <strong>ADK</strong> to set up our own team of AI agents, combined with <strong>OpenRouter</strong> as an API gateway. This will allow us to access practically any model — even free ones.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*KqRh9KQ7xsmzGfvlRlStIA.png" /></figure><h3>OpenRouter and ADK</h3><h4>OpenRouter</h4><p>OpenRouter is a unified platform that allows you to use many different AI models through a single API. On the website, you can view all available models (including free ones) and use them with a single API key provided by OpenRouter. A key feature is that the OpenRouter API is fully compatible with the OpenAI API.</p><p>Be careful, though: choosing a model shouldn’t depend solely on token cost; you must also consider the <strong>data policy</strong>.</p><p>The data policies for models on OpenRouter allow you to verify how the provider handles and stores your prompts, tokens, and source code. To check a policy, simply go to your chosen model, select the <strong>‘Providers’</strong> tab, and expand the menu for the specific company providing the model.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*k3lABP2dD1huvCFKSXX8gg.png" /></figure><p><strong>source</strong>: <a href="https://openrouter.ai/">https://openrouter.ai/</a></p><h4>ADK (Agent Developer Kit)</h4><p>Google has released the ADK, a development kit designed to help developers build AI agents using the new A2A (Agent2Agent) protocol. It makes it easy to build a team of AI agents that can solve complex tasks by splitting the work among specific agents.</p><p><strong>source</strong>: <a href="https://google.github.io/adk-docs/a2a/">https://google.github.io/adk-docs/a2a/</a></p><h3>Setup</h3><h4>Model</h4><p>In this guide i will use <a href="https://openrouter.ai/xiaomi/mimo-v2-flash:free/api">MiMo-V2-Flash</a> the brand new Xiaomi’s LLM. It is free, open source and very strong.<br>Remember to sign up and log in so you can generate the API Key needed to call the OpenRouter gateway.</p><p>In your profile, find the <strong>‘Keys’</strong> tab, click the <strong>‘Create Key’</strong> button in the top right corner, and configure it to your liking. Finally, make sure to copy and save the key somewhere safe, as it will not be visible again once you close the window.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*QruNaP9Z0wRUm9IqjVNjWQ.png" /></figure><p>Once that’s done, you’re practically all set. To test the model, you can use a simple cURL command or any HTTP client you prefer, in any programming language.<br>In this article, I will be using <strong>Python</strong> with the <strong>ADK</strong>.</p><p>This is a quick example of request in python:</p><pre>import requests<br>import json<br><br>response = requests.post(<br>  url=&quot;https://openrouter.ai/api/v1/chat/completions&quot;,<br>  headers={<br>    &quot;Authorization&quot;: f&quot;Bearer {openrouter_apikey}&quot;, # Make sure to put yours<br>    &quot;Content-Type&quot;: &quot;application/json&quot;,<br>  },<br>  data=json.dumps({<br>    &quot;model&quot;: &quot;xiaomi/mimo-v2-flash:free&quot;,<br>    &quot;messages&quot;: [<br>        {<br>          &quot;role&quot;: &quot;user&quot;,<br>          &quot;content&quot;: &quot;make a diet schedule for a male teenager: 16 Years Old - 1.80m of height and 70kg of weight - his goal is to become stronger and healthy&quot;<br>        }<br>      ],<br>    &quot;reasoning&quot;: {&quot;enabled&quot;: True}<br>  })<br>)<br><br># Extract the assistant message with reasoning_details<br>response = response.json()<br><br>response_message = response[&#39;choices&#39;][0][&#39;message&#39;]<br><br># Printing the content generated by the model<br>print(response_message[&#39;content&#39;])</pre><h4>Project Bootstrap</h4><blockquote>install all the dependencies in a virtual environment using conda or venv</blockquote><p>The dependencies we need are <strong>ADK </strong>and<strong> LiteLLM</strong> (which we will discuss later).</p><pre>!pip install adk<br>!pip install litellm</pre><p>After the installation you can now run adk create agentto create your first Agent:</p><pre>$ adk create agent<br>Choose a model for the root agent:<br>1. gemini-2.5-flash<br>2. Other models (fill later)<br>Choose model (1, 2): 2 # For now we are choosing the option &quot;Other models&quot;</pre><p><strong>Congratulations!</strong> You’ve just created your first agent with <strong>ADK</strong>.<br><strong>ADK</strong> has generated a folder named agent containing these files:</p><ul><li>.venv</li><li>agent.py</li><li>__init__.py</li></ul><p>Now, our focus is on the agent.py file, which should look like this:</p><pre>from google.adk.agents.llm_agent import Agent<br><br>root_agent = Agent(<br>    model=&#39;&lt;FILL_IN_MODEL&gt;&#39;,<br>    name=&#39;root_agent&#39;,<br>    description=&#39;A helpful assistant for user questions.&#39;,<br>    instruction=&#39;Answer user questions to the best of your knowledge&#39;,<br>)</pre><p>As you can see, there is a variable called root_agent. This will serve as our entry point when we define sub-agents later.</p><p>Let’s break down the parameters of the Agent class constructor:</p><ul><li><strong>model:</strong> The specific model identifier to be used.</li><li><strong>name:</strong> The name of the agent.</li><li><strong>description:</strong> A brief description of what this agent can do.</li><li><strong>instruction:</strong> The instruction prompt; this is the core prompt used by the model to determine its behavior.</li></ul><p>Now you can run your agent with this command:</p><pre>$ adk run agent</pre><p>Or you can run the web UI with this other command:</p><pre>$ adk web</pre><p>For now it won’t work becouse we haven’t configured the model yet.</p><h4>LiteLLM</h4><p>Natively, <strong>ADK</strong> only supports Gemini. However, as mentioned earlier, we will use <strong>OpenRouter</strong> as our API gateway. To achieve this, we need to use <strong>LiteLLM</strong>, a library capable of integrating all kinds of external models with ADK.</p><p>I will create a utility function to manage our models. We’ll place this in a new file located in the project root, named shared.py.</p><pre>from google.adk.models.lite_llm import LiteLlm<br>import os<br>from dotenv import load_dotenv<br><br>def createLLM():<br>    load_dotenv()<br><br>    _apikey = os.getenv(&quot;APIKEY&quot;)<br>    _baseurl = os.getenv(&quot;BASEURL&quot;)<br><br>    if _apikey is None or _baseurl is None:<br>        raise EnvironmentError(&quot;APIKEY and BASEURL environments not provided&quot;)<br><br>    return LiteLlm(<br>                model=&quot;openrouter/xiaomi/mimo-v2-flash:free&quot;,<br>                api_key=_apikey,<br>                api_base=_baseurl<br>            )</pre><p>The class LiteLlm has 3 important parameters:</p><ul><li>model: the name of the model</li><li>api_key: your OpenRouter API key</li><li>api_base: The OpenRouter BaseURL</li></ul><p>I’ve already added my API key and the base url in the .env file.</p><pre>APIKEY=YOUR-API-KEY<br>BASEURL=https://openrouter.ai/api/v1</pre><p><strong>Important:</strong><br>To use an OpenRouter model with LiteLLM we have to add the prefix openrouter/… in front of the model name.</p><p><strong>For example:</strong><br>The model xiaomi/mimo-v2-flash:free will become openrouter/xiaomi/mimo-v2-flash:free</p><p>LiteLLM repository: <a href="https://github.com/BerriAI/litellm">https://github.com/BerriAI/litellm</a></p><h4>First complete Agent</h4><pre>from google.adk.agents.llm_agent import Agent<br>from shared import createLLM<br><br>root_agent = Agent(<br>    model=createLLM(),<br>    name=&#39;root_agent&#39;,<br>    description=&#39;A helpful assistant for user questions.&#39;,<br>    instruction=&#39;Answer user questions to the best of your knowledge&#39;,<br>)</pre><p>Now if we run the web UI, ADK will host on the port :8000 the chat UI of our agents</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*rEQ06wFJt2uEOwxJH7LfNg.png" /></figure><p>Here, you can chat with your agents by selecting the one you want to use from the <strong>dropdown menu</strong> in the top-left corner.</p><h4>Add a sub agent</h4><p>A Sub Agent is a specialized agent that the root_agent uses to answer user questions. For example, try creating a new agent named &#39;agent_1&#39; and add it to the root_agent.sub_agents list:</p><pre># agent_1/agent.py<br> from google.adk.agents.llm_agent import Agent<br>from shared import createLLM<br><br>agent1 = Agent(<br>    model=createLLM(),<br>    name=&#39;agent1&#39;,<br>    description=&#39;A helpful assistant for user questions.&#39;,<br>    instruction=&#39;Answer user questions to the best of your knowledge&#39;,<br>)<br><br># agent/agent.py<br>from google.adk.agents.llm_agent import Agent<br>from shared import createLLM<br>from agent_1.agent import agent1 # Importing the agent_1<br><br>root_agent = Agent(<br>    model=createLLM(),<br>    name=&#39;root_agent&#39;,<br>    sub_agents=[agent1], # Put agent1 here !<br>    description=&#39;A helpful assistant for user questions.&#39;,<br>    instruction=&#39;Answer user questions to the best of your knowledge&#39;,<br>)</pre><p>Ok now you have a very simple agent team.</p><h3>Real Example</h3><p>To demonstrate the full potential of this setup, I have created a <strong>GitHub repository</strong> showcasing a real-world scenario: a team of AI Agents that assists the user with personalized workouts and nutrition plans.</p><p>You can find the full source code here:<br><a href="https://github.com/mattia33011/MuscleAI">https://github.com/mattia33011/MuscleAI</a></p><p>To get started, simply clone the repo, read the README.md file, and follow the setup instructions.</p><h3>Conclusion</h3><p>Building agents with ADK and OpenRouter opens up a world of possibilities. I encourage you to check out the repository, try running the agent team yourself, and let me know what you think.</p><p>If you found this article or the code helpful, feel free to leave a star on GitHub or share your feedback in the comments below!</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=dca386b4db50" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>