<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title>Posts on audijo.de</title>
		<link>https://audijo.de/posts/</link>
		<description>Recent content in Posts on audijo.de</description>
		<generator>Hugo -- gohugo.io</generator>
		<language>en-gb</language>
		<copyright>This work is licensed under a Creative Commons Attribution-NonCommercial 4.0 International License.</copyright>
		<lastBuildDate>Sat, 27 Feb 2021 12:51:08 +0100</lastBuildDate>
		<atom:link href="https://audijo.de/posts/index.xml" rel="self" type="application/rss+xml" />
		
		<item>
			<title>Deploy Hugo site with Gitlab-CI using SFTP</title>
			<link>https://audijo.de/posts/deploy-hugo-with-gitlab-ci/</link>
			<pubDate>Sat, 27 Feb 2021 12:51:08 +0100</pubDate>
			
			<guid>https://audijo.de/posts/deploy-hugo-with-gitlab-ci/</guid>
			<description>My web server is only accepting connections via SFTP for file transfer. This rendered many of the already described ways of continuous integration and deployment useless for me. With wahooga&amp;rsquo;s much appreciated post on how to build and deploy a Hugo website using SCP I had a great place to start.
In order to automatically build and deploy your website created with Hugo add the .gitlab-ci.yml of my site to your sites main source directory.</description>
			<content type="html"><![CDATA[<p>My web server is only accepting connections via SFTP for file transfer. This
rendered many of the already described ways of continuous integration and
deployment useless for me. With wahooga&rsquo;s much appreciated <a href="https://www.wahooga.com/hugo-gitlab">post</a>
on how to build and deploy a Hugo website using SCP I had a great place to start.</p>
<p>In order to automatically build and deploy your website created with
<a href="https://gohugo.io/">Hugo</a> add the <a href="https://gitlab.com/Audijo/audijo.de/-/blob/master/.gitlab-ci.yml"><code>.gitlab-ci.yml</code></a>
of my site to your sites main source directory. This will enable Gitlab CI for
your website. Additionally you need to set four variables in the Gitlab CI/CD
settings.</p>
<ul>
<li><code>SSH_HOST</code>: The host name or IP of your server.</li>
<li><code>SSH_HOST_KEY</code>: The hosts key like it is entered in your <code>known_hosts</code> file,
once you have connected to your server.</li>
<li><code>SSH_PRIVATE_KEY</code>: The private key you use to connect to the server. The
corresponding public key must be added to the servers authorized keys. With
<a href="https://www.ssh.com/ssh/openssh/">OpenSSH</a>, a key pair can be created using
the <a href="https://www.ssh.com/ssh/keygen/"><code>ssh-keygen</code></a> tool. The public key can
then be copied to a server using the
<a href="https://www.ssh.com/ssh/copy-id"><code>ssh-copy-id</code></a> tool.</li>
<li><code>SSH_USER</code>: The user name you use to connect to your web server.</li>
</ul>
<p><img src="/img/deploy-hugo-with-gitlab-ci_1.png" alt="Gitlab CI variables"></p>
<p>With the configuration and the variables in place, a commit pushed to the master
branch of your project triggers a build and an deploy of your website
automatically.</p>
]]></content>
		</item>
		
		<item>
			<title>Screen Sharing in Sway</title>
			<link>https://audijo.de/posts/screen-sharing-in-sway/</link>
			<pubDate>Thu, 25 Feb 2021 20:47:23 +0100</pubDate>
			
			<guid>https://audijo.de/posts/screen-sharing-in-sway/</guid>
			<description>Screen sharing is done with xdg-desktop-portal-wlr on Wayland.
It is available in the AUR https://archlinux.org/packages/community/x86_64/xdg-desktop-portal-wlr/.
The projects source can be found here https://github.com/emersion/xdg-desktop-portal-wlr.
Make sure XDG_CURRENT_DESKTOP=sway is set.
When correctly installed, xdg-desktop-portal should automatically invoke xdg-desktop-portal-wlr when needed.
This is not the case however if you use multiple outputs (screens). You need to pass the -output=&amp;lt;name&amp;gt; option to xdg-desktop-portal-wlr. The following script hands over the currently focused output. This output is the available as the only sharing option in applications like Microsoft Teams, Zoom and alike.</description>
			<content type="html"><![CDATA[<p>Screen sharing is done with <code>xdg-desktop-portal-wlr</code> on Wayland.</p>
<p>It is available in the AUR <a href="https://archlinux.org/packages/community/x86_64/xdg-desktop-portal-wlr/">https://archlinux.org/packages/community/x86_64/xdg-desktop-portal-wlr/</a>.</p>
<p>The projects source can be found here <a href="https://github.com/emersion/xdg-desktop-portal-wlr">https://github.com/emersion/xdg-desktop-portal-wlr</a>.</p>
<p>Make sure <code>XDG_CURRENT_DESKTOP=sway</code> is set.</p>
<p>When correctly installed, <code>xdg-desktop-portal</code> should automatically invoke <code>xdg-desktop-portal-wlr</code> when needed.</p>
<p>This is not the case however if you use multiple outputs (screens). You need to pass the <code>-output=&lt;name&gt;</code> option to <code>xdg-desktop-portal-wlr</code>. The following script hands over the currently focused output. This output is the available as the only sharing option in applications like Microsoft Teams, Zoom and alike. The dialogues of some browsers look like there is nothing to share. If you click somewhere in the dialogue the screen to share will appear.</p>
<div class="highlight"><pre class="chroma"><code class="language-bash" data-lang="bash"><span class="cp">#! /usr/bin/env bash
</span><span class="cp"></span>
<span class="c1"># share-screen</span>
<span class="c1"># This script starts or restarts `xdg-desktop-portal` and</span>
<span class="c1"># `xdg-desktop-portal-wlr`. While doing so the currently focused output (read</span>
<span class="c1"># screen) is passed to `xdg-desktop-portal-wlr`. This makes the respective</span>
<span class="c1"># screen available for sharing in apps and websites that can do so.</span>

<span class="nb">export</span> <span class="nv">XDG_CURRENT_DESKTOP</span><span class="o">=</span>sway

<span class="nv">output</span><span class="o">=</span><span class="k">$(</span>swaymsg -pt get_outputs <span class="p">|</span> grep focused <span class="p">|</span> awk <span class="s1">&#39;{print $2}&#39;</span><span class="k">)</span>
/usr/lib/xdg-desktop-portal -r <span class="p">&amp;</span> /usr/lib/xdg-desktop-portal-wlr -r -o <span class="nv">$output</span> <span class="p">&amp;</span>
</code></pre></div><p>It is currently not possible to share individual windows since there is no way to determine window borders in a not <code>sway</code> specific manner in Wayland. See <a href="https://github.com/emersion/xdg-desktop-portal-wlr/issues/12">https://github.com/emersion/xdg-desktop-portal-wlr/issues/12</a></p>
<p>The browser might be configured or built properly for sharing to work properly. See <a href="https://github.com/emersion/xdg-desktop-portal-wlr/wiki/Screencast-Compatibility">https://github.com/emersion/xdg-desktop-portal-wlr/wiki/Screencast-Compatibility</a></p>
<p>Resources:</p>
<p>Screen capture test page: <a href="https://mozilla.github.io/webrtc-landing/gum_test.html">https://mozilla.github.io/webrtc-landing/gum_test.html</a></p>
<p>Good guide also for browser configuration: <a href="https://bool3max.github.io/posts/sway_screenshare_guide/">https://bool3max.github.io/posts/sway_screenshare_guide/</a></p>
<p>Early guide, the stuff now works without the <code>-git</code> packages <a href="https://soyuka.me/make-screen-sharing-wayland-sway-work/">https://soyuka.me/make-screen-sharing-wayland-sway-work/</a></p>
]]></content>
		</item>
		
	</channel>
</rss>
