<?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: Victoria Nadasdi</title>
    <description>The latest articles on DEV Community by Victoria Nadasdi (@efertone).</description>
    <link>https://dev.to/efertone</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%2Fuser%2Fprofile_image%2F283966%2F305d9026-1dbe-46b5-91ba-c6ba9ca63700.jpg</url>
      <title>DEV Community: Victoria Nadasdi</title>
      <link>https://dev.to/efertone</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/efertone"/>
    <language>en</language>
    <item>
      <title>Drone on Kubernetes with Gitea, something went wrong</title>
      <dc:creator>Victoria Nadasdi</dc:creator>
      <pubDate>Thu, 09 Jan 2020 13:12:53 +0000</pubDate>
      <link>https://dev.to/efertone/drone-on-kubernetes-with-gitea-2gho</link>
      <guid>https://dev.to/efertone/drone-on-kubernetes-with-gitea-2gho</guid>
      <description>&lt;p&gt;For a while I have my own Kubernetes stack on &lt;a href="https://m.do.co/c/b40a659c34a7" rel="noopener noreferrer"&gt;DigitalOcean&lt;/a&gt; where I can do some science and host what I want or what others ask me like blogs, landing pages, cron-jobs and of course a &lt;a href="https://gitea.io/en-us/" rel="noopener noreferrer"&gt;Gitea&lt;/a&gt; instance. One day I decided to fire up a &lt;a href="https://drone.io/" rel="noopener noreferrer"&gt;Drone.io&lt;/a&gt; instance so I can automate the boring tasks with it. It was like Drone 1.0 or something. Everything worked as I expected and I was happy. One day I updated Gitea and suddenly Drone stopped working. No problem, updated Drone too and that's where all the fun part started.&lt;/p&gt;

&lt;p&gt;I always got an error message:&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;&lt;code&gt;invalid character '&amp;lt;' looking for beginning of value&lt;/code&gt;&lt;br&gt;
&lt;/p&gt;

&lt;p&gt;I tried to find a reasonable answer, but found nothing. I knew from that error message it's definitely coming from a JSON parser that received HTML instead. I met this error message a lot of times before, but I did not know why it happens. Drone-&amp;gt;Gitea connection should be fine because the OAuth login works and the Webhook calls back to Drone when push happened.&lt;/p&gt;

&lt;p&gt;I decided to sit back and who cares, those jobs are running like monthly once and there is already a &lt;code&gt;Makefile&lt;/code&gt; in there that does the same. So for like 3-4 months I built/published them manually. Not a bit deal, like extra 5-10 minutes, but still... It's not working and it's poking brain hard, WHY? But I had no time for that. Deeply, I had a light hope it's not something I fix but they have to fix it. &lt;/p&gt;

&lt;p&gt;But now, I had time for that. Updated Gitea and Drone. Kick off a build... It's still the same error. And that was the point where I said "No I can't get away with this, I will find and fix it" and I did ;)&lt;/p&gt;

&lt;p&gt;That's the reason why I write this, maybe someone else has the same problem and has no idea why it does not work. After I decided to recreate the whole Drone stack based on the documentation... it has the same error again. I went to sleep. A woke up from a serious nightmare where a whale with a tattoo tried to catch me. The tattoo was (obviously, thanks brain) "invalid character '&amp;lt;' looking for beginning of value". And I was not able to sleep back.&lt;/p&gt;

&lt;p&gt;Solution? Is there a solution? Or is it an infinite pain I have to live with? Yes, there is a solution. I don't really know how I ended up changing the value for &lt;code&gt;DRONE_GITEA_SERVER&lt;/code&gt; but I did. And suddenly everything worked. Here is a diff that made me crazy:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight diff"&gt;&lt;code&gt;&lt;span class="gd"&gt;- DRONE_GITEA_SERVER=https://gitea.domain.com/
&lt;/span&gt;&lt;span class="gi"&gt;+ DRONE_GITEA_SERVER=https://gitea.domain.com
&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Yes, I just removed (to be more precise, I missed it during the copy-paste) and that's it. That was the solution. With the trailing slash was fine for the OAuth redirect, but for git clone it was an error.&lt;/p&gt;

&lt;p&gt;If you came here because you have the same problem. I hope it helps you and you don't have to wake up because a giant whale chases you.&lt;/p&gt;

</description>
      <category>gitea</category>
      <category>droneio</category>
      <category>kubernetes</category>
      <category>troubleshooting</category>
    </item>
  </channel>
</rss>
