-
Notifications
You must be signed in to change notification settings - Fork 137
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
run go app with oracle client dependency #1670
Comments
probably going to need a bit more information than that
|
that contain the oracle client for linux, as i do with container, I tried to run: but the message is yet: goroutine 1 [running]: how should i set LD_LIBRARY_PATH as i do in my dockerfile ? Andrea |
is there a reason why you are attaching a volume to the app vs including that directory inside your image via 'Dirs' or 'MapDirs' ? also, it looks like you are hitting the same problem with or without the volume; do you have a minimal example to look at? i haven't downloaded oracledb yet but something like this should work:
two things to watch out for:
|
to give you a parallel with what I do with container, I use oracle client for linux, 2- to be honest I didn't use the parameter libDir of the driver till now, but following your example the output is the same: is there a way to have a more detailed debug output ? Andrea |
that panic is definitely something that should be more explicit (like what file it is failing to find) for sure but more than likely it's trying to add a file that it can't find on your mac - it might help to sprinkle some printfs into the BuildManifest function where it is failing https://github.com/nanovms/ops/blob/882d741c6db5ea41e99d1801adc31dea7790153f/lepton/image.go#L304 if you do a |
root@3621002adc2a:/go/src/cmd/web# ldd cmd/web/app were you able to build the example I pasted? |
ops is libc agnostic and if you build/run on linux it will try to resolve all those shared libraries (eg: auto-include them) but if you are just yanking down a binary without the libs it depends on to mac then you have a high chance of running into an issue like this - I'm going to guess that libdl dep you have is what is causing the issue and that is there because of the cgo build from the oracle lib that loads at run-time so just to be clear you can build/run this on linux just not mac? |
yeah, I will and ill let you know |
Hello, I' am trying to run a golang application who has dependency by oracle client, how should I proceed in order to run it as unikernel ?
uname -a
Darwin MacBook-Pro-3.homenet.telecomitalia.it 21.2.0 Darwin Kernel Version 21.2.0: Sun Nov 28 20:28:54 PST 2021; root:xnu-8019.61.5~1/RELEASE_X86_64 x86_64
this is the output I get:
ops run app_linux
100% |████████████████████████████████████████| [0s:0s]
panic: failed building manifest: file does not exist
goroutine 1 [running]:
github.com/nanovms/ops/cmd.runCommandHandler(0xc00048c580, 0xc000aa2300, 0x1, 0x1)
/Users/eyberg/go/src/github.com/nanovms/ops/cmd/cmd_run.go:62 +0x45c
github.com/spf13/cobra.(*Command).execute(0xc00048c580, 0xc000aa22e0, 0x1, 0x1, 0xc00048c580, 0xc000aa22e0)
/Users/eyberg/go/pkg/mod/github.com/spf13/[email protected]/command.go:846 +0x2c2
github.com/spf13/cobra.(*Command).ExecuteC(0xc0000f5080, 0x0, 0xffffffff, 0xc0000b0058)
/Users/eyberg/go/pkg/mod/github.com/spf13/[email protected]/command.go:950 +0x375
github.com/spf13/cobra.(*Command).Execute(...)
/Users/eyberg/go/pkg/mod/github.com/spf13/[email protected]/command.go:887
main.main()
/Users/eyberg/go/src/github.com/nanovms/ops/ops.go:8 +0x2a
thanks,
Andrea
The text was updated successfully, but these errors were encountered: