mirror of
https://github.com/hanzoai/container.git
synced 2026-10-30 15:06:01 +00:00
* core: begin migration to ubuntu * core: update cloud image link * k3s: update version * core: fix boot for ubuntu * vm: add ability to set custom hostname * core: checkpoint: remove qemu wrapper * core: checkpoint: remove qemu wrapper * cli: minor bug fix for terminal output * cli: fix broken terminal output for deb download * cli: improve terminal output for deb download * vm: fix docker permission on initial create * net: remove gvproxy, migrate to user-v2 * docker: fix host-gateway address * vm: avoid re-installing packages * k3s: fix broken coredns * core: improve downloader * vm: add binfmt for cross-platform containers * containerd: fix for ubuntu * containerd: fix broken working directory detection * chore: remove obsolete env var * chore: minor refactor for binfmt * cli: fix ip address for colima list * docker: add daemon support for proxy env vars * vm: add more utilities * ci: remove obsolete ubuntu layer * ci: move to gh from hub * core: use custom directory for Lima * chore: minor factor, remove obsolete variable * docker: workaround initial user permission issue * chore: remove obsolete code * vm: fix binfmt cache * core: enforce Lima version requirement * docker: workaround permission issue * vm: enable inotify by default * core: enable binfmt only on host arch * docs: prepare for v0.6.0 * nix: update Go version in shell * nix: update build * build: add integration test script * ci: remove aarch64, defer until proper m1 support * build: fix colima path in integration test script
33 lines
1011 B
Nix
33 lines
1011 B
Nix
{ pkgs ? import <nixpkgs> }:
|
|
|
|
with pkgs;
|
|
|
|
buildGo120Module {
|
|
name = "colima";
|
|
pname = "colima";
|
|
src = ./.;
|
|
nativeBuildInputs = [ installShellFiles makeWrapper git ];
|
|
vendorSha256 = "sha256-7DIhSjHpaCyHyXKhR8KWQc2YGaD8CMq+BZHF4zIkL50=";
|
|
CGO_ENABLED = 1;
|
|
|
|
subPackages = [ "cmd/colima" ];
|
|
|
|
# `nix-build` has .git folder but `nix build` does not, this caters for both cases
|
|
preConfigure = ''
|
|
export VERSION="$(git describe --tags --always || echo nix-build-at-"$(date +%s)")"
|
|
export REVISION="$(git rev-parse HEAD || echo nix-unknown)"
|
|
ldflags="-X github.com/abiosoft/colima/config.appVersion=$VERSION
|
|
-X github.com/abiosoft/colima/config.revision=$REVISION"
|
|
'';
|
|
|
|
postInstall = ''
|
|
wrapProgram $out/bin/colima \
|
|
--prefix PATH : ${lib.makeBinPath [ qemu lima ]}
|
|
installShellCompletion --cmd colima \
|
|
--bash <($out/bin/colima completion bash) \
|
|
--fish <($out/bin/colima completion fish) \
|
|
--zsh <($out/bin/colima completion zsh)
|
|
'';
|
|
}
|
|
|