Error: "hdb" couldn't be found
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 322
- Forks
- 99
- PR merge metrics
- No merged PRs in 30d
Description
Hi team,
We are trying to move our existing Docker container to distroless container method.
In local, we are able to build the image and run the container but when we push it to our repo, our kyma k8s deployment pod is crashing.
Error:
[cds] - loading server from { file: 'srv/server.js' }
[utility] - Enter-UtilityService-Constructor()
[server] - [CDS][Event][BOOTSTRAP]
[cds] - loaded model from 18 file(s):
srv/server.cds
db/common.cds
app/services.cds
srv/api/v2/dataCenterService.cds
srv/api/v1/dataCentersService.cds
srv/api/v1/dataCenterService.cds
srv/api/v1/dataCenterMonitorService.cds
srv/api/common-apis/masterDataService.cds
srv/api/common-apis/flexiConfiguration.cds
srv/api/common-apis/decisionTree.cds
app/datacenter/annotations.cds
app/cloud_service/annotations.cds
app/admin/annotations.cds
srv/api/api.cds
srv/health/health.cds
db/data-model.cds
db/API-schema/API-response.cds
node_modules/@sap/cds/common.cds
/app/node_modules/@sap/cds/libx/_runtime/hana/driver.js:198
throw new Error(`"${name}" could not be found. Please make sure it is installed.`)
^
Error: "hdb" could not be found. Please make sure it is installed.
at _getHanaDriver (/app/node_modules/@sap/cds/libx/_runtime/hana/driver.js:198:13)
at Object.<anonymous> (/app/node_modules/@sap/cds/libx/_runtime/hana/driver.js:205:18)
at Module._compile (node:internal/modules/cjs/loader:1376:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1435:10)
at Module.load (node:internal/modules/cjs/loader:1207:32)
at Module._load (node:internal/modules/cjs/loader:10
at Module.require (node:internal/modules/cjs/loader:1235:19)
at require (node:internal/modules/helpers:176:18)
at Object.<anonymous> (/app/node_modules/@sap/cds/libx/_runtime/hana/pool.js:5:14)
at Module._compile (node:internal/modules/cjs/loader:1376:14)
Node.js v20.10.0
We have all the dependencies and packages in our package.json and we are also able to verify it in our local running container but in our kyma k8s pod, it says that it is not able to find the hdb package.
Kindly help us in understanding and fixing this issue
Please let me know if you need any additional resource(s)/help
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with package.json, the Docker image contents, and the srv/server.js startup path shown in the logs. Compare the locally built image with the image deployed to the Kyma Kubernetes pod, then verify why hdb is unavailable there and confirm that the pod starts successfully with the declared dependencies.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- docker, javascript, kubernetes, nodejs
- Domain
- devops, infrastructure
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100