Closed Tobi-De closed 2 weeks ago
Ok, some back and forth with Cofin got me thinking. The main reason I'm not using Docker (except for the fact that Kamal exists) is for simplicity; adding Docker to the mix would be one more tool to learn to get the app into production. Plus, I already have a nice, quite simple, and straightforward way to deploy my app with Docker and CapRover. I've gotten quite comfortable with Docker, so basing Fujin on it wouldn’t bring much added value for me. Like with Falco, the goal is to empower individuals (I've been vibing with recent Ruby on Rails talks), meaning most of the tools I'm building are geared toward a single individual building stuff (the main target audience being me). Even at work, I'm often on a one-man team.
With all that said, there is still an issue Fujin doesn’t fix: PostgreSQL + point-in-time backup without using a managed service. I narrowed down the focus to packaging Python apps so that the workflow is more reliable and simple, but I'm having a hard time figuring out how to make this work for additional services like PostgreSQL, or any others I might need—PostgreSQL is just the main one for now.
fujin pg install
fujin pg createdb
Cofin recommended this https://github.com/vitabaks/postgresql_cluster, which is really cool and could be very useful at work, but for a single person working on a prototype, that’s probably too much. He also recommended Podman and this.
Now, here’s what I’m thinking: adding a new key extensions
(better than custom commands) with a list of modules that can be imported and added. This reminded me of DJP and its plugin system based on Pluggy. The first one I'll go with is an extension based on Podman to set up and install services.
This extension will be added in a list in the fujin.toml
file as extensions = ["fujin-services"]
, and it will have its own config service with the ability to declare Docker/Podman services. One thing I’m thinking is that if I flesh out the hook system correctly and maybe add a top-level skip_project_install
, the extension could be used to deploy the project itself by extending the hooks and processes lists. Since systemd can manage Podman containers, it might come with its own custom process manager to replace the default, managing both a normal project or a container-based project.
This approach would let me keep containers out of the picture until I need postgres.
nah, will just do this #17 instead
custom cappa modules that can be dynamically imported and added to the cli