Posted on on adnano.co.
Sourcehut recently announced free static hosting for Gemini and the web via Sourcehut pages.
Sourcehut pages announcement
To publish your Kiln site to Sourcehut pages automatically, you'll need to add the following build manifest in the file ".build.yml" in the root of your site repository:
image: alpine/edge oauth: pages.sr.ht/PAGES:RW packages: - kiln environment: site: example.com sources: - https://git.sr.ht/~$username/$site tasks: - build: | cd $site kiln --html - package: | cd $site tar -C dst -cvz . > ../site.tar.gz tar -C html -cvz . > ../html.tar.gz - upload: | acurl -f https://pages.sr.ht/publish/$site \ -Fcontentemail@example.com \ -Fprotocol=GEMINI acurl -f https://pages.sr.ht/publish/$site \ -Fcontentfirstname.lastname@example.org \ -Fprotocol=HTTPS
This build manifest builds Gemini and HTML versions of your site and uploads both to Sourcehut pages. It will run automatically whenever you push a commit to your site repository, assuming that it is hosted on Sourcehut. Be sure to point your domain name towards Sourcehut pages' servers.
Sourcehut pages documentation
This work is licensed under a CC-BY-SA-4.0 license.
Have a comment on one of my posts? Send an email