<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title>elixir on Roger&#39;s Blog</title>
		<link>https://blog.differentpla.net/tags/elixir/</link>
		<description>Recent content in elixir on Roger&#39;s Blog</description>
		<generator>Hugo</generator>
		<language>en</language>
		
		
		
		
			<lastBuildDate>Mon, 20 Mar 2023 13:15:00 +0000</lastBuildDate>
		
			<atom:link href="https://blog.differentpla.net/tags/elixir/feed.xml" rel="self" type="application/rss+xml" />
			<item>
				<title>Cert-Manager Audit</title>
				<link>https://blog.differentpla.net/blog/2023/03/20/k8s-cert-manager-audit/</link>
				<pubDate>Mon, 20 Mar 2023 13:15:00 +0000</pubDate>
				<guid>https://blog.differentpla.net/blog/2023/03/20/k8s-cert-manager-audit/</guid>
				<description>&lt;p&gt;In &lt;a href=&#34;https://blog.differentpla.net/blog/2023/03/19/expired-certificates-incident-review/&#34;&gt;Expired Certificates: Incident Review&lt;/a&gt;, I&#xA;listed a future action: &lt;em&gt;&amp;ldquo;Audit the cluster to see if there are any other TLS secrets that aren&amp;rsquo;t using cert-manager.&amp;rdquo;&lt;/em&gt;&#xA;Here&amp;rsquo;s how I did it using Elixir Livebook.&lt;/p&gt;</description>
			</item>
			<item>
				<title>Unit testing in Elixir Livebook</title>
				<link>https://blog.differentpla.net/blog/2023/01/25/livebook-unit-testing/</link>
				<pubDate>Wed, 25 Jan 2023 11:19:00 +0000</pubDate>
				<guid>https://blog.differentpla.net/blog/2023/01/25/livebook-unit-testing/</guid>
				<description>&lt;p&gt;I&amp;rsquo;ve written some code in Elixir Livebook, and I&amp;rsquo;d like to write some unit tests for it. Here&amp;rsquo;s how I did it.&lt;/p&gt;</description>
			</item>
			<item>
				<title>Elixir Livebook on k3s</title>
				<link>https://blog.differentpla.net/blog/2022/02/23/livebook-k3s/</link>
				<pubDate>Wed, 23 Feb 2022 20:42:00 +0000</pubDate>
				<guid>https://blog.differentpla.net/blog/2022/02/23/livebook-k3s/</guid>
				<description>&lt;p&gt;I&amp;rsquo;d like to run Livebook on my cluster. Here&amp;rsquo;s how I went about doing that.&lt;/p&gt;</description>
			</item>
			<item>
				<title>Accessing the Kubernetes API from an Elixir container</title>
				<link>https://blog.differentpla.net/blog/2022/01/16/k8s-api-elixir-container/</link>
				<pubDate>Sun, 16 Jan 2022 13:04:00 +0000</pubDate>
				<guid>https://blog.differentpla.net/blog/2022/01/16/k8s-api-elixir-container/</guid>
				<description>&lt;p&gt;If you want to access the Kubernetes API from Elixir, you should probably just use the&#xA;&lt;a href=&#34;https://hex.pm/packages/k8s&#34;&gt;k8s package&lt;/a&gt;, but here&amp;rsquo;s how to do it without taking that dependency.&lt;/p&gt;</description>
			</item>
			<item>
				<title>Colouring the &#39;iex&#39; prompt</title>
				<link>https://blog.differentpla.net/blog/2022/01/09/iex-prompt-colours/</link>
				<pubDate>Sun, 09 Jan 2022 12:17:00 +0000</pubDate>
				<guid>https://blog.differentpla.net/blog/2022/01/09/iex-prompt-colours/</guid>
				<description>&lt;p&gt;If you&amp;rsquo;ve got separate dev, test and prod environments, it can help to use colour to tell you which one you&amp;rsquo;re logged&#xA;into. Here&amp;rsquo;s how to colour the &lt;code&gt;iex&lt;/code&gt; prompt appropriately.&lt;/p&gt;</description>
			</item>
			<item>
				<title>Erlang/Elixir Cookies and Kubernetes</title>
				<link>https://blog.differentpla.net/blog/2022/01/09/erlang-cookies-and-kubernetes/</link>
				<pubDate>Sun, 09 Jan 2022 10:27:00 +0000</pubDate>
				<guid>https://blog.differentpla.net/blog/2022/01/09/erlang-cookies-and-kubernetes/</guid>
				<description>&lt;p&gt;Distributed Erlang and Elixir applications use a shared secret called a &amp;ldquo;cookie&amp;rdquo;.  It&amp;rsquo;s just a string of alphanumeric&#xA;characters. All nodes in the cluster must use the same cookie. Let&amp;rsquo;s take a look at what that means in a Kubernetes&#xA;context.&lt;/p&gt;</description>
			</item>
			<item>
				<title>CoreDNS: endpoint_pod_names</title>
				<link>https://blog.differentpla.net/blog/2022/01/08/coredns-endpoint-pod-names/</link>
				<pubDate>Sat, 08 Jan 2022 19:34:00 +0000</pubDate>
				<guid>https://blog.differentpla.net/blog/2022/01/08/coredns-endpoint-pod-names/</guid>
				<description>&lt;p&gt;I&amp;rsquo;m still on the hunt for a way to connect Erlang nodes in a Kubernetes cluster by using pod names.&lt;/p&gt;</description>
			</item>
			<item>
				<title>libcluster and Kubernetes</title>
				<link>https://blog.differentpla.net/blog/2022/01/08/libcluster-kubernetes/</link>
				<pubDate>Sat, 08 Jan 2022 14:07:00 +0000</pubDate>
				<guid>https://blog.differentpla.net/blog/2022/01/08/libcluster-kubernetes/</guid>
				<description>&lt;p&gt;I&amp;rsquo;m looking at setting up an Erlang/Elixir cluster in my Kubernetes cluster, using&#xA;&lt;a href=&#34;https://github.com/bitwalker/libcluster&#34;&gt;libcluster&lt;/a&gt;, and I&amp;rsquo;m trying to get my head around some of the implied&#xA;constraints.&lt;/p&gt;</description>
			</item>
			<item>
				<title>elixir-certs</title>
				<link>https://blog.differentpla.net/blog/2021/12/21/elixir-certs/</link>
				<pubDate>Tue, 21 Dec 2021 11:50:00 +0000</pubDate>
				<guid>https://blog.differentpla.net/blog/2021/12/21/elixir-certs/</guid>
				<description>&lt;p&gt;I need to secure my Docker registry. Because OpenSSL sucks, I&amp;rsquo;m using&#xA;&lt;a href=&#34;https://github.com/rlipscombe/elixir-certs&#34;&gt;an Elixir script&lt;/a&gt; that uses the &amp;lsquo;x509&amp;rsquo; library.&lt;/p&gt;</description>
			</item>
			<item>
				<title>failed to start child: :ranch_server_proxy</title>
				<link>https://blog.differentpla.net/blog/2021/06/08/ranch-server-proxy-error/</link>
				<pubDate>Tue, 08 Jun 2021 14:02:00 +0000</pubDate>
				<guid>https://blog.differentpla.net/blog/2021/06/08/ranch-server-proxy-error/</guid>
				<description>&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;** (Mix) Could not start application example_server: ExampleServer.Application.start(:normal, []) returned an error: shutdown: failed to start child: {:ranch_embedded_sup, :example_server}&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;    ** (EXIT) shutdown: failed to start child: :ranch_server_proxy&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;        ** (EXIT) no process: the process is not alive or there&amp;#39;s no process currently associated with the given name, possibly because its application isn&amp;#39;t started&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&#xA;&lt;p&gt;Did you start the &lt;code&gt;ranch&lt;/code&gt; application? If you&amp;rsquo;re using &lt;code&gt;rebar3&lt;/code&gt; (Erlang) or &lt;code&gt;mix&lt;/code&gt; (Elixir), it ought to start automatically as part of your application.&lt;/p&gt;</description>
			</item>
			<item>
				<title>k3s on Raspberry Pi: Phoenix Server</title>
				<link>https://blog.differentpla.net/blog/2020/02/07/k3s-raspi-phoenix-server/</link>
				<pubDate>Fri, 07 Feb 2020 11:17:00 +0000</pubDate>
				<guid>https://blog.differentpla.net/blog/2020/02/07/k3s-raspi-phoenix-server/</guid>
				<description>&lt;p&gt;Note: This is basically the same as &lt;a href=&#34;https://blog.differentpla.net/blog/2020/02/06/k3s-raspi-node-server/&#34;&gt;the node.js server&lt;/a&gt;.&lt;/p&gt;&#xA;&lt;h2 id=&#34;creating-the-phoenix-app&#34;&gt;Creating the Phoenix app&lt;a href=&#34;#creating-the-phoenix-app&#34;&gt;&lt;span class=&#34;icon icon-link&#34;&gt;&lt;/span&gt;&lt;/a&gt;&#xA;&lt;/h2&gt;&#xA;&lt;p&gt;It&amp;rsquo;s entirely possible to create the app inside the docker container, or on a completely different machine, but I&amp;rsquo;m going to do it locally, which means &lt;a href=&#34;https://blog.differentpla.net/blog/2020/02/07/rpi-elixir/&#34;&gt;installing Erlang, Elixir and Phoenix first&lt;/a&gt;.&lt;/p&gt;</description>
			</item>
			<item>
				<title>Installing Erlang and Elixir on Raspberry Pi</title>
				<link>https://blog.differentpla.net/blog/2020/02/07/rpi-elixir/</link>
				<pubDate>Fri, 07 Feb 2020 10:49:06 +0000</pubDate>
				<guid>https://blog.differentpla.net/blog/2020/02/07/rpi-elixir/</guid>
				<description>&lt;p&gt;Quick reference for installing Erlang and Elixir on a Raspberry Pi, using the Erlang Solutions packages.&lt;/p&gt;</description>
			</item>
			<item>
				<title>Elixir&#39;s use functionality</title>
				<link>https://blog.differentpla.net/blog/2020/01/02/elixir-use/</link>
				<pubDate>Thu, 02 Jan 2020 15:54:00 +0000</pubDate>
				<guid>https://blog.differentpla.net/blog/2020/01/02/elixir-use/</guid>
				<description>&lt;p&gt;&lt;code&gt;use&lt;/code&gt; is a way that you can inject code into your module. Elixir uses this for boilerplate in &lt;code&gt;GenServer&lt;/code&gt;, and Phoenix uses it for metaprogramming.&lt;/p&gt;</description>
			</item>
			<item>
				<title>Installing Elixir with kiex</title>
				<link>https://blog.differentpla.net/blog/2019/01/30/installing-elixir-with-kiex/</link>
				<pubDate>Wed, 30 Jan 2019 17:12:00 +0000</pubDate>
				<guid>https://blog.differentpla.net/blog/2019/01/30/installing-elixir-with-kiex/</guid>
				<description>&lt;p&gt;At Electric Imp, we manage our Elixir versions with kiex.&lt;/p&gt;</description>
			</item>
			<item>
				<title>Installing kiex</title>
				<link>https://blog.differentpla.net/blog/2019/01/30/installing-kiex/</link>
				<pubDate>Wed, 30 Jan 2019 17:10:00 +0000</pubDate>
				<guid>https://blog.differentpla.net/blog/2019/01/30/installing-kiex/</guid>
				<description>&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; class=&#34;chroma&#34;&gt;&lt;code class=&#34;language-text&#34; data-lang=&#34;text&#34;&gt;&lt;span class=&#34;line&#34;&gt;&lt;span class=&#34;cl&#34;&gt;\curl -sSL https://raw.githubusercontent.com/taylor/kiex/master/install | bash -s&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&#xA;&lt;p&gt;Then ensure it&amp;rsquo;s in your path. I copied it to &lt;code&gt;/usr/local/bin&lt;/code&gt;:&lt;/p&gt;</description>
			</item>
			<item>
				<title>Integrating direnv with kiex</title>
				<link>https://blog.differentpla.net/blog/2019/01/30/integrating-kiex-direnv/</link>
				<pubDate>Wed, 30 Jan 2019 17:07:00 +0000</pubDate>
				<guid>https://blog.differentpla.net/blog/2019/01/30/integrating-kiex-direnv/</guid>
				<description>&lt;p&gt;To integrate &lt;code&gt;direnv&lt;/code&gt; with &lt;code&gt;kiex&lt;/code&gt;, add the following to &lt;code&gt;~/.direnvrc&lt;/code&gt;:&lt;/p&gt;</description>
			</item>
	</channel>
</rss>
