Using Caddy as reverse proxy for standalone Runestone installs

22 views
Skip to first unread message

Bradley Miller

unread,
Jun 12, 2026, 6:59:29 PM (8 days ago) Jun 12
to PreTeXt development
Sean, Harris, and others who run their own servers, and devs (Andrew) who run servers:

Safari and other browsers have become increasingly diligent about non https sites even localhost!

I just pushed a PR that I would love you to help test.  I’m replacing nginx with caddy so that you can run a standalone version of Runestone with minimal hassle about certs.  For devs on macos you will be able to test with minimal hassle as well because you can configure a local trusted certificate.  With no action everything will remain the same for localhost testing (no https) but see the sample.env  or projects/caddy/README.md for how you can install a local cert!

Running local dev as close to production as possible is a good thing. So please consider giving this a try.  I hope to merge this next week.

Brad

Brad Miller
Professor Emeritus, Luther College
Founder, Runestone Academy LTD
Blog: http://reputablejournal.com

Set up a time to meet with me.


Sean Fitzpatrick

unread,
Jun 12, 2026, 7:45:32 PM (8 days ago) Jun 12
to PreTeXt development
I will try to count this as a PROTEUS activity so I can work on it next week ;-)

(I'm attending remotely this year.)

Currently I'm running the Docker setup (I'm pulling containers rather than building.) I've got https running fine, but I can still do some testing. 

I assume I'll need to build containers in this case? Probably I'll just test on my laptop rather than a server. We could spin up a new VM, but I've got to go through IT to expose it to the outside world.

--
You received this message because you are subscribed to the Google Groups "PreTeXt development" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pretext-dev...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/pretext-dev/0D49FB2A-BBD3-459F-8CC5-8AF5D11BD938%40runestone.academy.

Bradley Miller

unread,
Jun 14, 2026, 3:53:22 PM (6 days ago) Jun 14
to PreTeXt development
I merged the PR.  It sits beside nginx until we are comfortable with it.  I have tried it out in production with the author server and it works fine as it stands now, caddy is the default, but you can easily disable it and use nginx instead if we run into any issues.

Brad

Brad Miller
Professor Emeritus, Luther College
Founder, Runestone Academy LTD
Blog: http://reputablejournal.com

Set up a time to meet with me.

Sean Fitzpatrick

unread,
Jun 15, 2026, 5:07:45 PM (5 days ago) Jun 15
to PreTeXt development
Well, heck. 

It took me 5 minutes to change over to Caddy, and everything appears to be up and running. All that I did: 
- git pull
- edit docker-compose.yml
- edit .env
- add my email to the Caddyfile

I'll try not to think about how many hours I spent fighting to get CertBot and nginx to play nicely together in Docker! 

So far I haven't done my other usual upgrade steps (poetry build, Docker pull, database update). But: 

(a) I'm at home, and my list of steps to make sure I don't mess up is in my office 
(b) If it ain't broke...

Bradley Miller

unread,
Jun 15, 2026, 7:47:53 PM (5 days ago) Jun 15
to PreTeXt development
Sean,

Thats great to hear!

For database migrations they are now built into the rsmanage image.  So at this point you don’t need anything from the repo except the docker-compose.yml file and a .env file.

docker compose run —rm rsmanage check-db-migrations.sh

If migrations are needed it will tell you what to run, namely docker compose run --rm rsmanage alembic upgrade head

Updated docs and the new one script install instructions are here:  https://docs.runestone.academy/en/latest/running.html

Brad

Brad Miller
Professor Emeritus, Luther College
Founder, Runestone Academy LTD
Blog: http://reputablejournal.com

Set up a time to meet with me.

Sean Fitzpatrick

unread,
Jun 16, 2026, 9:06:23 AM (4 days ago) Jun 16
to prete...@googlegroups.com
Wow! So no more poetry install --with=dev etc.
My installation is in this weird spot: parts of it (like the database, which is local) come from before the pre-built containers were available.
I wonder if it would be worth the cost of losing my old course data to start over again with the install script.

Reply all
Reply to author
Forward
0 new messages