#investigating the glibc issue 🧵/cc @

1 messages · Page 1 of 1 (latest)

austere hedge
#

seems likely - we must not have /usr/bin/sh?

dapper wing
austere hedge
#

@normal grail hrmmm this might be unique to the approach our wolfi module takes to installing packages

#

or maybe that module is just more bleeding-edge and thus able to pick up the brokenness

austere hedge
dapper wing
#

So it's a combination of multiple things?

austere hedge
dapper wing
#

0.16.1 breaks too, so I'm not sure it comes from us? It appeared sudently

dapper wing
normal grail
#

Yeah I wouldn't be surprised if the logic in modules/alpine just got out of sync with Wolfi assumptions. We could try going down from edge/main but agree it'd be nicer if we can find a quick fix

normal grail
# austere hedge maybe this broke it? https://github.com/wolfi-dev/os/commit/8229c0379cada98fb950...

https://github.com/sipsma/dagger/blob/fd199d89fe3e26f08c20a1677d45d668d90561be/modules/alpine/main.go#L187-L187 that feels potentially related; the script used to use busybox but now just wants /usr/bin/sh which probably doesn't get setup

GitHub

A portable devkit for CI/CD pipelines. Contribute to sipsma/dagger development by creating an account on GitHub.

austere hedge
normal grail
#

I'll try a fix

spark birch
#

DId you guys find a way to unlock it locally, for the local dev loop ?

#

I don't really care about pin / unpin for this local instance 👼

normal grail
#

Or just change all the uses of wolfi in CI to be plain old Alpine, I don't think we really care about wolfi specifically

normal grail
#

Making some progress, the problem appears to actually be that there's a trigger for busybox that does busybox --install -s and creates all the symlinks, but that trigger doesn't run right now until after glibc's trigger. Might just need an ordering fix

spark birch
#

#SKILL ISSUE :-p

normal grail
normal grail
# spark birch Thanks because i can't seem to make the above hack work ahah 🤣
diff --git a/modules/alpine/main.go b/modules/alpine/main.go
index 35a4180c9..6089072af 100644
--- a/modules/alpine/main.go
+++ b/modules/alpine/main.go
@@ -259,8 +259,15 @@ func (m *Alpine) withPkgs(
                        Exclude: pkg.rmFileNames,
                })
                ctr = ctr.With(pkgscript("post-install", pkg.name, pkg.postInstall))
+               // HACK: quick fix for busybox trigger needing to be run before glibc trigger (which needs /usr/bin/sh symlink to busybox created)
+               if pkg.name == "busybox" {
+                       ctr = ctr.With(pkgscript("trigger", pkg.name, pkg.trigger))
+               }
        }
        for _, pkg := range alpinePkgs {
+               if pkg.name == "busybox" {
+                       continue
+               }
                ctr = ctr.With(pkgscript("trigger", pkg.name, pkg.trigger))
        }

That fixes it

#

If you want to apply locally

#

I'll just send that out quick as a PR

#

Then hopefully I can follow up with something less dumb

normal grail
#

thank you @spark birch I'll let the engine build related CI run then merge

#

okay merged that, I'll see what it's gonna take to fix the trigger ordering generally

dapper wing
#

It works, I'm able to compile using v0.16.1, I don't know why it doesn't work with 0.16.2 but it's unrelated to that issue

normal grail
normal grail
dapper wing
#

It works if I set v0.16.1 engine, otherwise it fails like that:

#

There's no specific error message so I'm not able to understand why it fails

normal grail
normal grail
normal grail
#

like an actual error or something? or is it just suddenly canceled

spark birch
#

I cherry-picked your commit and it just works

dapper wing
gray nova
#

this still doesn't work for me, but I'm not sure if it's the same issue or different

#
admin@ip-172-31-4-147:~/vikram.dagger/docs/recorder$ dagger version
dagger v0.16.3-250307154740-11d93c834085 (docker-container://dagger-engine.dev) linux/amd64
admin@ip-172-31-4-147:~/vikram.dagger/docs/recorder$ dagger call generate-quickstart-recordings --base=../current_docs/ci/quickstart/snippets export --path=/tmp/out
✔ connect 0.2s
✔ load module 28.1s
✔ parsing command line arguments 0.0s

✔ Host.directory(path: "/home/admin/vikram.dagger/docs/current_docs/ci/quickstart/snippets"): Directory! 0.0s

✔ recorder: Recorder! 2m13s
✘ .generateQuickstartRecordings(
│ │ base: Host.directory(path: "/home/admin/vikram.dagger/docs/current_docs/ci/quickstart/snippets"): Directory!
│ ): Directory! 2m23s
! process "apk add curl" did not complete successfully: exit code: 99
│ ✔ git(url: "https://github.com/dagger/hello-dagger"): GitRepository! 0.0s
│ ✔ .branch(name: "main"): GitRef! 0.0s
│ ✔ .tree: Directory! 1.8s
gray nova
#

similar error with

dagger -m github.com/dagger/dagger/modules/wolfi@v0.16.2 -c 'container | with-exec apk,add,curl | with-exec curl,-L,dagger.io | stdout'
normal grail
#

@gray nova that wouldn’t have been expected to work before either, when using the wolfi module you need to specify the apk packages when calling the wolfi module rather than do apk add calls later

#

That’s just a current limitation

gray nova
#

So I guess it changed at some point, because it used to work

normal grail
#

Hm it might be pretty old then

#

Yeah it’s been a long time

gray nova
#

But I tried the screen recorder module just 2 weeks ago and it worked then

#

And it's the same error

#

They are both apk add errors

gray nova
#

Additional info: the original docs examples use Solomon's wolfi module. That wasn't working so I switched to the one above and got this error.