sawv.org on Gemini

created May 14, 2020

Related Gemini post from yesterday:

https://sawv.org/2020/05/13/today-i-learned-about-project-gemini.html


I host multiple websites on a Digital Ocean Droplet. Today, I updated the Let's Encrypt TLS certificate to include sawv.org.

A few years ago, I installed a Gopher server.

I don't actively maintain content at my Gopher site. I copied over some plain text versions of my content stored at sawv.org. I setup up more for testing, but maybe I should cross-post all or some of my https://sawv.org content to gopher://sawv.org and now to my Gemini site.

Today, I managed to get a Gemini server running.

At the moment, however, I only have test content, hosted at my Gemini site.

After the TLS cert was updated to include sawv.org, I upgraded Golang.

I deleted the old version of Golang.

At the Golang downloads page:

https://golang.org/dl

I downloaded go1.14.2.linux-386.tar.gz and I followed the install instructions.

https://golang.org/doc/install

I had planned to install a Gemini server, written in Lua, but the setup seemed a bit daunting. That's why I chose the Golang version found here:

https://tildegit.org/solderpunk/molly-brown

I followed the download, install, and setup procedures, mentioned on that Molly Brown page.

I copied the executable from ~/go/bin/molly-brown to /usr/sbin.

I found the example.conf file, stored under the temp ~/go directory tree where Molly Brown was downloaded.

I copied that example.conf file to /etc/molly.conf. I modified the settings, listed in the file.

Then I typed molly at the command prompt, which started the server in my terminal session, not in the background. I used the Castor Gopher/Gemini/Finger client app to access gemini://sawv.org and it worked, which surprised me. I assumed that I would need to fiddle with the setup some more.

home page for my gemini site

my hello world type page at my gemini site

My /etc/molly.conf settings, although HomeDocBase is set to another user. Maybe I don't understand what HomeDocBase is yet.

Port = 1965
Hostname = "sawv.org"
CertPath = "/etc/letsencrypt/archive/soupmode.com-0001/cert8.pem"
KeyPath = "/etc/letsencrypt/archive/soupmode.com-0001/privkey8.pem"
DocBase = "/home/gemini/docs/"
HomeDocBase = "users"
LogPath = "/var/log/molly.log"
CGIPath = "^/var/gemini/cgi-bin/"

At the moment, I may need to update CertPath and KeyPath each time that I renew the Let's Encrypt certificate.

More to learn. I need to get the Molly Brown executable setup as a daemon.

I don't understand the CGI aspects of Gemini. That could be interesting or a problem.

I created an index.gmi file in document root, and it works like an index.html file on the web.


I'm using the GUI-based Gemini client called Castor.

https://sr.ht/~julienxx/Castor/

It permits a few custom typographical settings.

Within my home directory on my Linux laptop, I edited the following file.

~/.config/castor/settings.toml

I chose a dark theme by borrowing settings from this web page.

https://sawv.org/2020/01/10/dark-theme-css-january-2020.html

This is my current Castor settings:

[general]
start_url = "gemini://gemini.circumlunar.space/capcom"

[colors]
h1 = "#c90"
h2 = "#c0c0c0"
h3 = "#c90"
list = "#c0c0c0"
text = "#9baec8"
background = "#1f232b"

[characters]
h1 = ""
h2 = ""
h3 = ""
list = "🌼"

[monospace]
gemini=false
gopher=true
finger=true

It's hilarious that an emoji can be used to represent the bullet points in an unordered list.

The following CommonMark (Markdown-flavored) formatting commands are currently supported by the Gemini spec and Castor.

Castor or the Gemini spec preserves hard returns whereas in CommonMark, the CR/LF chars are ignored. In a .gmi file, if I hit the return key while typing a paragraph after typing 30 chars, then that's how the text is displayed within the Gemini client. In CommonMark, two spaces would need to be added at the end of the 30-char line to have the text line displayed as typed.

I assume that nothing stops Gemini client developers from adding more CommonMark formatting and customization options. A different client might add support for blockquotes, italicizing, bolding, and more while also providing typographical options in the settings file.

Gemini definitely leans toward my Markdown-only idea that I jotted down in January 2019.

http://sawv.org/2019/01/22/markdownonly-web-browser.html

Gemini has no plans to support embedding images within a post, which is probably good. This makes Gemini similar to Gopher.

Within my test hello.gmi file, I added the following link line.

=> /images/my-whole-wheat-sourdough-bread-april-2020.jpg   photo of my whole wheat sourdough bread

For the above image, I used the larger version of this image ...

https://live.staticflickr.com/65535/49806914667_208c498f57.jpg

... that exists in my web post about the naturally-leavened sourdough whole wheat bread that I made last month, described in this post:

https://sawv.org/2020/04/20/bread-baking-apr-20-2020.html

Anyway, even though images cannot be displayed or embedded within a Gemini post, Gemini links can point to the images. And after clicking the image link, Castor downloaded the image, and the image got displayed within the image viewer app that exists on my Ubuntu system.

screenshot of viewing an image at my gemini site

Enlarge screenshot

It's now 2:00 p.m., and I have done nothing today but learn about Gemini, which has been fun. This morning I made pour-over coffees, and the only thing that I have eaten today has been the focaccia bread that I made yesterday. I need to pull myself together and revisit Gemini later.

Well before doing something else, like eating, I decided to see if I could make the molly-brown executable work as a daemon by following the instructions on this page.

https://tildegit.org/solderpunk/molly-brown

Daemon tool: http://libslack.org/daemon

http://libslack.org/daemon/README

Me on my DO Droplet, I did the following:

mkdir daemon
cd daemon
wget http://libslack.org/daemon/download/daemon-0.6.4.tar.gz
tar -zxf daemon-0.6.4.tar.gz
cd daemon-0.6.4
./config
make
make test
make install
daemon /usr/sbin/molly-brown
ps aux | grep molly

And now Molly Brown runs as a daemon, and I can log off the server.


Regarding Castor, I slightly modified the file /src/draw.rs to increase the font sizes for the headings, list text, and the body text to make reading a little more comfortable for my eyes. After the slight change, I ran make and make install and I restarted Castor to see the changes.

The main article body font size is a little too big now, but it's better than being too small.

-30-