Show HN: Unregistry – “docker push” directly to servers without a registry
101–110 of 178 posts
Re: Show HN: Unregistry – “docker push” directly to servers without a registry
#102Re: Show HN: Unregistry – “docker push” directly to servers without a registry
#103Considering the nature of servers, security boundaries and hardening, > Linux via Homebrew Please don't encourage this on Linux. It happens to offer a Linux setup as an afterthought but behaves like a pigeon on a chessboard rather than a package manager.
We're using it to distribute internal tools across macOS and Linux developers. It excels in this. Are there any good alternatives?
Re: Show HN: Unregistry – “docker push” directly to servers without a registry
#104I've been very happy doing this: DOCKER_HOST=“ssh://user@remotehost” docker-compose up -d It works with plain docker, too. Another user is getting at the same idea when they mention docker contexts, which is just a different way to set the variable. Did you know about this approach? In the snippet above, the image will be built on the remote machine and then run. The context (files) are sent over the wire as needed.…
Re: Show HN: Unregistry – “docker push” directly to servers without a registry
#105Re: Show HN: Unregistry – “docker push” directly to servers without a registry
#106Earlier quoted context omitted.
Thank you! Can you please clarify what kind of support you mean for docker compose?
Right now, I use ssh to trigger a docker compose restart that pulls all the latest images on some of my servers (we have a few dedicated hosting/on premise setups). That then needs to reach out to our registry to pull images. So, it's this weird mix of push pull that ends up needing a central registry. What would be nicer instead is some variation of docker compose pussh that pushes the latest versions of local image…
The connection back to HQ only lasts as long as necessary to pull the layers, tagging works as expected, etc etc. It's like having an on-demand hosted registry and requires no additional cruft on the remotes. I've been migrating to Podman and this process works flawlessly there too, fwiw.
Re: Show HN: Unregistry – “docker push” directly to servers without a registry
#107Earlier quoted context omitted.
We're using it to distribute internal tools across macOS and Linux developers. It excels in this. Are there any good alternatives?
100% Nix, it works on every distro, MacOS, WSL2 and won't pollute your system (it'll create /nix and patch your bashrc on installation and everything from there on goes into /nix).
I tried it, but I have not been able to easily replicate our Homebrew env. We have a private repo with pre-compiled binaries, and a simple Homebrew formula that downloads the utilities and installs them. Compiling the binaries requires quite a few tools (C++, sigh).
I got stuck at the point where I needed to use a private repo in Nix.
Re: Show HN: Unregistry – “docker push” directly to servers without a registry
#108Earlier quoted context omitted.
100% Nix, it works on every distro, MacOS, WSL2 and won't pollute your system (it'll create /nix and patch your bashrc on installation and everything from there on goes into /nix).
Downside: it's Nix. I tried it, but I have not been able to easily replicate our Homebrew env. We have a private repo with pre-compiled binaries, and a simple Homebrew formula that downloads the utilities and installs them. Compiling the binaries requires quite a few tools (C++, sigh). I got stuck at the point where I needed to use a private repo in Nix.
Perfectly doable with Nix. Ignore the purists and do the hackiest way that works. It's too bad that tutorials get lost on concepts (which are useful to know but a real turn down) instead of focusing on some hands-on practical how-to.
This should about do it and is really not that different nor difficult than formulas or brew install:
git init mychannel
cd mychannel
cat > default.nix { },
}:
{
foo = pkgs.callPackage ./pkgs/foo { };
}
NIX
mkdir -p pkgs/foo
cat > pkgs/foo/default.nix foo foo!
git add .
git commit -a -m 'init channel'
git add origin git@github.com:OWNER/mychannel
git push origin main
nix-channel --add https://github.com/OWNER/mychannel/archive/main.tar.gz mychannel
nix-channel --update
nix-env -iA mychannel.foo
foo # => foo!
(I just cobbled that up together, if it doesn't work as is it's damn close; flakes left as an exercise to the reader)Note: if it's a private repo then in /etc/nix/netrc (or ~/.config/nix/netrc for single user installs):
machine github.com
password ghp_YOurToKEn
> Compiling the binaries requires quite a few tools (C++, sigh).Instantly sounds like a whole reason to use nix and capture those tools as part of the dependency set.