I am trying to run the sample code available at (https://neo4j.com/developer/go/) using golang neo4j driver but running into issues.
I have build the seabolt 1.7.4 from source.
Have the following variables in place
PKG_CONFIG_PATH pointing to seabolt-1.7.4/build/dist/share/pkgconfig
When I try to build my code with command
env GOOS=linux go build -ldflags="-s -w" --tags seabolt_static -o bin/user users/user.go
I get the following error
../firstname.lastname@example.org/connector_worker.go:30:14: undefined: Config
../email@example.com/connector_worker.go:31:15: undefined: seaboltConnector
Can anyone point me in right direction.
We also getting the same issue / waiting on response from Neo4J other than check the version number
../../github.com/neo4j-drivers/gobolt/connector_worker.go:30:14: undefined: Config
../../github.com/neo4j-drivers/gobolt/connector_worker.go:31:15: undefined: seaboltConnector
Go driver doesn't support cross compilation scenarios (just because it depends on a native library - seabolt - through cgo). Does it successfully build when you don't specify
GOOS as part of the
go build command, i.e. does it build and run on macos?
The only suggestion I could make for you is probably to use a docker based pipeline so that you can build a static binary that you could deploy to your staging environment. I think this Dockerfile would be a good starting point.