4 ms·
Question - how can dependency hell be solved when using such a tool? It seems so elegant and I love the "it just works" attitude, and I do understand that dock
by yard2010 2y ago
Question - how can dependency hell be solved when using such a tool?
It seems so elegant and I love the "it just works" attitude, and I do understand that docker can't be used everywhere due to its technical (and mental) overhead, but I love it because it allows to isolate everything, freeze everything in time so running a container 5 years for now "just works".
In my humble workflow, I'm using lazydocker to manage the containers, gitlab workflow (action?) for deployment on push and a small VPS to build and push the containers to gitlab registry and to run it, on the same VPS. It's a little bit overkill - I could use a combination of a Dockerfile and a compose.yml with docker compose build. Also, I didn't figure out scaling yet. Good thing I don't need it! Otherwise I would swap docker for k8s and lazydocker for k9s.
(I'm open to suggestions. I just got into devops, and I love it!)
- myaccountonhn 2y agoPersonally I use the same approach to piku, but instead rebuild my Nixos config on push. My projects use nix flakes, so I get both something that I know will run on my server and on my local machine with the full development environment. No containers needed technically, but I use systemd nspawn to run the software in its own sandboxed namespace. My entire server is then managed declaratively, so if I want to add a new project, it’s like 3-5 lines of Nginx config and push, that’s all. Something goes wrong? Just revert the commit.
- ku1ik 2y agoThis sounds super interesting! Do you have an example of such a config somewhere, that you can share?
- myaccountonhn 2y agoI did a write-up of setting up nixos with git deploys here: https://mccd.space/posts/git-to-deploy/ https://mccd.space/posts/git-to-deploy/. As far as the nixos config is concerned, there is nothing crazy in it. It is just a regular nix config with nginx (https://nixos.wiki/wiki/Nginx https://nixos.wiki/wiki/Nginx). You can see there that adding nginx is just four lines of code, ~eight with ssl. Use it to proxy to your applications that are setup as systemd services (https://wiki.nixos.org/wiki/Systemd/User_Services https://wiki.nixos.org/wiki/Systemd/User_Services). Edit: btw I'm a big fan of asciinema! ty for making it. :)
- nextaccountic 2y agoQuestion, could one use piku for that? (Would it be able to rebuild nixos on each commit?)