<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Devops on Jose Castrillo</title>
    <link>https://jose.castrillo.eu/categories/devops/</link>
    <description>Recent content in Devops on Jose Castrillo</description>
    <generator>Hugo -- gohugo.io</generator>
    <language>en</language>
    <lastBuildDate>Sun, 04 Feb 2024 00:00:00 +0000</lastBuildDate>
    <atom:link href="https://jose.castrillo.eu/categories/devops/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>Faster and simple maintenance page</title>
      <link>https://jose.castrillo.eu/post/maintenance-page/</link>
      <pubDate>Sun, 04 Feb 2024 00:00:00 +0000</pubDate>
      <guid>https://jose.castrillo.eu/post/maintenance-page/</guid>
      <description>&lt;p&gt;Working on different platform either to update, patch, etc need to be notificate for those people that consume that services, it shouldn&amp;rsquo;t change if that service it&amp;rsquo;s internal, you must notificate your teams about it.&lt;/p&gt;
&lt;p&gt;When you&amp;rsquo;re into your maintenance window you can use a faster way to broadcast everyone you&amp;rsquo;re working on it; I use this simple solution when I was working into a Jenkins migration, hence I stop the jenkins service and instead of 500 html error I developed a simple html text exposing it by a nginx container by the root path.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Trigger pipelines by using the API</title>
      <link>https://jose.castrillo.eu/post/pipeline-part1/</link>
      <pubDate>Sat, 15 Jul 2023 00:00:00 +0000</pubDate>
      <guid>https://jose.castrillo.eu/post/pipeline-part1/</guid>
      <description>&lt;p&gt;When you join a new project, company, customer, etc. (you&amp;rsquo;re still in the onboarding phase 😅), meanwhile you may find that you need to make a few changes to get your team&amp;rsquo;s production pipelines up and running. In this case, you can call an API trigger from one project to another (this is just a example).&lt;/p&gt;
&lt;p&gt;I&amp;rsquo;ve been in the situation described above before, and it was how I discovered this amazing feature in GitLab.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Mastering GitLab CI/CD, Unleashing the Power of Pipelines</title>
      <link>https://jose.castrillo.eu/post/pipeline-gitlab-guide/</link>
      <pubDate>Fri, 16 Jun 2023 00:00:00 +0000</pubDate>
      <guid>https://jose.castrillo.eu/post/pipeline-gitlab-guide/</guid>
      <description>&lt;p&gt;Hey everyone! 👋 I hope you&amp;rsquo;re all having a fantastic summer time! 🌞&lt;/p&gt;
&lt;p&gt;I wanted to drop a quick note to let you know that I&amp;rsquo;m currently working on something special for all my fellow developers/operations and GitLab enthusiasts out there. 🤓✨&lt;/p&gt;
&lt;p&gt;In the upcoming posts, I&amp;rsquo;ll be sharing a treasure trove of valuable tips and tricks related to GitLab pipelines! based in my experiences 🏗️ Whether you&amp;rsquo;re a seasoned pro or just getting started with GitLab CI/CD, there&amp;rsquo;s bound to be something for everyone.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Cloining a repo and setting up as artifact</title>
      <link>https://jose.castrillo.eu/post/clone-pipeline-gitlab/</link>
      <pubDate>Tue, 20 Dec 2022 00:00:00 +0000</pubDate>
      <guid>https://jose.castrillo.eu/post/clone-pipeline-gitlab/</guid>
      <description>&lt;p&gt;On this post I will give you an example of how to clone a repo into your pipeline and use it for other jobs.&lt;/p&gt;
&lt;p&gt;As you can read from Gitlab official &lt;a href=&#34;https://docs.gitlab.com/ee/ci/pipelines/job_artifacts.html&#34;&gt;documentation&lt;/a&gt; artifact can output an archive of files/directories. I set the following example:&lt;/p&gt;
&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-shell&#34; data-lang=&#34;shell&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;  artifacts:
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    paths:
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;      - &amp;lt;project_name&amp;gt;
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    exclude:
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;      - &amp;lt;project_name&amp;gt;/.git/**/*
&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    expire_in: &lt;span class=&#34;m&#34;&gt;60&lt;/span&gt; seconds
&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;p&gt;We need to call the &lt;em&gt;artifacts&lt;/em&gt; by using &amp;ldquo;artifacts&amp;rdquo; keyboard in the pipeline, in this example &lt;em&gt;paths&lt;/em&gt; keyboard which files/directories add into artifacts.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Trigger pipelines in Gitlab</title>
      <link>https://jose.castrillo.eu/post/trigger-pipeline-gitlab/</link>
      <pubDate>Thu, 10 Nov 2022 00:00:00 +0000</pubDate>
      <guid>https://jose.castrillo.eu/post/trigger-pipeline-gitlab/</guid>
      <description>&lt;p&gt;The following post is example of how to activate and use Trigger pipeline by API the official documentation over &lt;a href=&#34;https://docs.gitlab.com/ee/ci/triggers/&#34;&gt;here&lt;/a&gt; as it mentioned is can be use &lt;em&gt;&amp;ldquo;to trigger a pipeline for a specific branch or tag&amp;rdquo;&lt;/em&gt;; for our example I use it to activate a pipeline into specific branch.&lt;/p&gt;
&lt;p&gt;Steps:&lt;/p&gt;
&lt;p&gt;&lt;em&gt;repoA will be the main one where the pipeline trigger it will be activate&lt;/em&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;From &lt;strong&gt;repoA&lt;/strong&gt; go to Settings-CI/CD-Pipeline triggers&lt;/li&gt;
&lt;li&gt;Click on &lt;em&gt;&amp;ldquo;add trigger&amp;rdquo;&lt;/em&gt; copy your token&lt;/li&gt;
&lt;li&gt;From &lt;strong&gt;repoB&lt;/strong&gt; that will be our caller of the &lt;strong&gt;repoA&lt;/strong&gt; pipeline create a variable where you can paste the token.&lt;/li&gt;
&lt;li&gt;Finally into your pipeline on &lt;strong&gt;repoB&lt;/strong&gt; you can add something like below:&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The best part is that you can reference to specific branch &lt;strong&gt;ref=&amp;quot;&amp;lt;branch_name&amp;gt;&amp;quot;&lt;/strong&gt;.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Ansible missing sudo</title>
      <link>https://jose.castrillo.eu/post/ansible-missing-sudo/</link>
      <pubDate>Sun, 03 Apr 2022 00:00:00 +0000</pubDate>
      <guid>https://jose.castrillo.eu/post/ansible-missing-sudo/</guid>
      <description>&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;Ansible FAILED! =&amp;gt; {&amp;#34;msg&amp;#34;: &amp;#34;Missing sudo password&amp;#34;}
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;I have a couple of ansible-playbook, from one of my endpoint device started to prompt &lt;em&gt;missing sudo password&lt;/em&gt; due there is needed a sudoers access, thus this is one of the solutions.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;login by ssh to the device, where ansible can&amp;rsquo;t login.&lt;/li&gt;
&lt;li&gt;go to /etc/sudoers.d/&lt;/li&gt;
&lt;li&gt;create a new entry eg: &amp;ldquo;023_user-nopass&amp;rdquo;&lt;/li&gt;
&lt;li&gt;add the following line &amp;ldquo;user ALL=(ALL) NOPASSWD: ALL&amp;rdquo; into the file &amp;ldquo;023_user-nopass&amp;rdquo;&lt;/li&gt;
&lt;li&gt;change the permission by using:&lt;/li&gt;
&lt;/ul&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;sudo chmod 440 023_user-nopass
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;NOTE: please change &lt;user&gt; value for your normal user access -not the root one-&lt;/p&gt;</description>
    </item>
    <item>
      <title>How setup a Gitlab Runner (CI)</title>
      <link>https://jose.castrillo.eu/post/gitlab-runner1/</link>
      <pubDate>Wed, 08 Dec 2021 00:00:00 +0000</pubDate>
      <guid>https://jose.castrillo.eu/post/gitlab-runner1/</guid>
      <description>&lt;p&gt;&lt;img loading=&#34;lazy&#34; src=&#34;https://castrillo.gitlab.io/figaro/runner_logo.png&#34; alt=&#34;&#34;  /&gt;
&lt;/p&gt;
&lt;h2 id=&#34;part-i--&#34;&gt;Part I -&lt;/h2&gt;
&lt;p&gt;I&amp;rsquo;m learning Gitlab Runner and how them works on CI implementation.&lt;/p&gt;
&lt;p&gt;GitLab Runner is an application that works with GitLab CI to run jobs in a pipeline, they are written in &lt;a href=&#34;https://golang.org/&#34;&gt;GO&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Summary the task I will do:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Install Gitlab-runner as container(podman).&lt;/li&gt;
&lt;li&gt;Runner registration.
&lt;ul&gt;
&lt;li&gt;Enter the GitLab instance URL&lt;/li&gt;
&lt;li&gt;registration token.&lt;/li&gt;
&lt;li&gt;runner description.&lt;/li&gt;
&lt;li&gt;tags.&lt;/li&gt;
&lt;li&gt;Select an &lt;a href=&#34;https://docs.gitlab.com/runner/executors/&#34;&gt;executor&lt;/a&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;/li&gt;
&lt;li&gt;Create a gitlab-ci.yml&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;Install runner:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Create the Volume:&lt;/li&gt;
&lt;/ol&gt;
&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;podman volume create gitlab-runner-config
&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;Pull and start the container by &lt;strong&gt;register&lt;/strong&gt; command, then we will prompt the data need for register the runner into the project.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Repo-list</title>
      <link>https://jose.castrillo.eu/post/repo-list/</link>
      <pubDate>Sun, 08 Mar 2020 00:00:00 +0000</pubDate>
      <guid>https://jose.castrillo.eu/post/repo-list/</guid>
      <description>&lt;p&gt;This is a documentation I&amp;rsquo;ve made time ago searching some open source tools and platforms(&amp;amp; freeware), I hope It can be useful to you:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Ticketing&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;&lt;a href=&#34;https://www.graylog.org/&#34;&gt;https://www.graylog.org/&lt;/a&gt;    Monitoring / Open source&lt;/p&gt;
&lt;p&gt;Discover and resolve issues faster. Keep end users happy with less downtime and better performance by proactively monitoring key indicators and exceptions across the entire stack.&lt;/p&gt;
&lt;p&gt;&lt;a href=&#34;https://www.happyfox.com/&#34;&gt;https://www.happyfox.com/&lt;/a&gt;   Ticketing / private&lt;/p&gt;
&lt;p&gt;Meet HappyFox, a practical help desk and customer support software solution. Reduce chaos and bring order to your support process with a robust support ticket system, self-service knowledge base and community forums.&lt;/p&gt;</description>
    </item>
    <item>
      <title>How to set you SSH key into Gitlab</title>
      <link>https://jose.castrillo.eu/post/ssh-gitlab-git/</link>
      <pubDate>Thu, 26 Dec 2019 00:00:00 +0000</pubDate>
      <guid>https://jose.castrillo.eu/post/ssh-gitlab-git/</guid>
      <description>&lt;p&gt;How to set you SSH key into Gitlab [&lt;em&gt;First you need to had installed Git onto your distro&lt;/em&gt;]&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;
&lt;p&gt;Go to your terminal and issue the follow command to generate your key: &lt;code&gt;$ssh-keygen&lt;/code&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Copy your public key from the route: &lt;strong&gt;/home/user/.ssh/id_rsa.pub&lt;/strong&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;Then go at your gitlab profile &lt;a href=&#34;https://gitlab.com/profile/keys/&#34;&gt;https://gitlab.com/profile/keys/&lt;/a&gt; a paste and save.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
&lt;p&gt;From the terminal test the conection by typing: &lt;code&gt;$ssh -T git@gitlab.com&lt;/code&gt; and if everything was fine it has to promt &amp;ndash;&amp;gt; Welcome to GitLab, @user_account!&lt;/p&gt;</description>
    </item>
  </channel>
</rss>
