Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Let Lima install nerdctl instead of bundling it in the ISO #77

Open
jandubois opened this issue Jul 18, 2022 · 6 comments
Open

Let Lima install nerdctl instead of bundling it in the ISO #77

jandubois opened this issue Jul 18, 2022 · 6 comments

Comments

@jandubois
Copy link
Member

That's how it works for all other distros, and it allows updating of nerdctl without making a new alpine-lima release.

At the very least Lima should be able to update nerdctl to a newer version, even if the ISO already includes an older version.

@AkihiroSuda
Copy link
Member

AkihiroSuda commented Jul 19, 2022

The following binaries are dynamically linked with glibc (as of nerdctl-full v0.22.0)

@jandubois
Copy link
Member Author

The following binaries are dynamically linked with glibc (as of nerdctl-full v0.22.0)

That's ok; the only binaries from the nerdctl tarball we install right now are buildctl, buildkitd, and nerdctl:

for bin in buildctl buildkitd nerdctl; do
cp "${tmp}/nerdctl/bin/${bin}" "${tmp}/usr/local/bin/${bin}"
chmod u+s "${tmp}/usr/local/bin/${bin}"
done

So just being able to upgrade these 3 via lima would already be an advantage.

@afbjorklund
Copy link
Member

afbjorklund commented Dec 19, 2022

All 3 binaries are now available in Alpine 3.17, from buildctl and buildkit <sic> and nerdctl apks.

Will make a separate PR to make the setuid chmod optional, to require using sudo with nerdctl...

@afbjorklund
Copy link
Member

afbjorklund commented Dec 19, 2022

(1/6) Installing libseccomp (2.5.4-r0)
(2/6) Installing runc (1.1.4-r4)
(3/6) Installing containerd (1.6.12-r1)
(4/6) Installing containerd-openrc (1.6.12-r1)
(5/6) Installing cni-plugins (1.1.1-r9)
(6/6) Installing nerdctl (1.0.0-r2)

(1/1) Installing buildctl (0.10.6-r1)
(1/2) Installing buildkit (0.10.6-r1)
(2/2) Installing buildkit-openrc (0.10.6-r1)

lima-std:~$ sudo /etc/init.d/containerd start
 * /var/log/containerd.log: creating file
 * Starting Container Daemon ...                            [ ok ]
lima-std:~$ sudo /etc/init.d/buildkitd start
 * Caching service dependencies ... 
 * /var/lib/buildkit: creating directory
 * /var/log/buildkitd.log: creating file
 * Starting buildkitd ...                                   [ ok ]
lima-std:~$ nerdctl version
WARN[0000] environment variable XDG_RUNTIME_DIR is not set, see https://rootlesscontaine.rs/getting-started/common/login/ 
WARN[0000] environment variable XDG_RUNTIME_DIR is not set, see https://rootlesscontaine.rs/getting-started/common/login/ 
WARN[0000] environment variable XDG_RUNTIME_DIR is not set, see https://rootlesscontaine.rs/getting-started/common/login/ 
FATA[0000] rootless containerd not running? (hint: use `containerd-rootless-setuptool.sh install` to start rootless containerd): environment variable XDG_RUNTIME_DIR is not set, see https://rootlesscontaine.rs/getting-started/common/login/ 
lima-std:~$ sudo nerdctl version
Client:
 Version:	1.0.0
 OS/Arch:	linux/amd64
 Git commit:	<unknown>
 buildctl:
  Version:	0.10.6
  GitCommit:	alpine

Server:
 containerd:
  Version:	v1.6.12
  GitCommit:	a05d175400b1145e5e6a735a6710579d181e7fb0
 runc:
  Version:	1.1.4
  GitCommit:	5fd4c4d144137e991c4acebb2146ab1483a97925

@terev
Copy link

terev commented May 26, 2023

Hello 😄 . Is this possible yet? Noticed that buildkitd is out of date and it's currently bundled with nerctl. Was hoping to use the new attestation features.

@afbjorklund
Copy link
Member

I don't think that the nerdctl distribution ("nerdctl-full") comes in a musl flavor yet, it only supports glibc as far as I know

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants