cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

deploy error when using CAP and HANA database

0 Likes
3,619

I try to deploy a project to cloud foundry . Steps are followed by link https://developers.sap.com/tutorials/hana-cloud-cap-deploy-mta.html. Below errors occur.

npm notice New minor version of npm available! 8.1.2 -> 8.5.1 (STDOUT, STG)#

npm notice (STDOUT, STG)#npm notice (STDOUT, STG)#

npm ERR! errno ENOTFOUND (STDOUT, STG)#

npm ERR! syscall getaddrinfo (STDOUT, STG)#

npm ERR! code ENOTFOUND (STDOUT, STG)#

npm ERR! network 'proxy' config is set properly. See: 'npm help config' (STDOUT, STG)#

................

npm ERR! network This is a problem related to network connectivity. (STDOUT, STG)#

npm ERR! network request to http://nginx-redirector.repo-cache.svc.cluster.local/repository/appstudio-npm-group/@sap/audit-loggi... failed, reason: getaddrinfo ENOTFOUND nginx-redirector.repo-cache.svc.cluster.local (STDOUT, STG)#

**ERROR** Unable to build dependencies: exit status 1 (STDOUT, STG)#

Accepted Solutions (0)

Answers (1)

Answers (1)

chgeo
Product and Topic Expert
Product and Topic Expert
0 Likes

In mta.yaml, change `npm ci` to `npm install`. Remove the `npm-ci` builder line.

Alternatively, you would need to create a 'clean' package-lock.json. You can try with a `.npmrc file` with this content:

@sap:registry=https://registry.npmjs.org
registry=https://registry.npmjs.org/
bbauwens
Discoverer
0 Likes

Having exactly the same issue... I already have "npm install" in mta.yaml.

Where does this .npmrc file needs to be located in the project folder structure, root or db?

chgeo
Product and Topic Expert
Product and Topic Expert
0 Likes

It’s in the project root folder, the place where package-lock.json gets created/updated.

0 Likes

Hi Christian Georgi,

I follow the above steps. It seems that package-lock.json file will be regenated automatically. And the content seems not changed.

And the same error still exists.

chgeo
Product and Topic Expert
Product and Topic Expert
0 Likes

Check your .npmrc file. There was a line break missing in the code sample of my previous comment.
Check with `npm config list` that `registry` and `@sap:registry` keys are set properly.

After that try first creating the file, avoiding the expensive build roundtrip

rm -f package-lock.json && npm install

Then check the package-lock file that no bad registry URL is included.

0 Likes

Hi Christian Georgi,

I have followed the above steps, Below is my setting.

After I run the command "rm -f package-lock.json && npm install",

the content is still the same as

"resolved": "http://nginx-redirector.repo-cache.svc.cluster.local/repository/appstudio-npm-group/@colors/colors/-/colors-1.5.0.tgz".It seems not working.
chgeo
Product and Topic Expert
Product and Topic Expert
0 Likes

Interesting. Stuff might have been cached by npm. Use

npm cache clean -f

to clean this cache and try again.

0 Likes

Hi Christian Georgi,

It doesn't work, As it is a trial account, I have no rooot permission.

chgeo
Product and Topic Expert
Product and Topic Expert
0 Likes

Well, from the screenshot, the executions with `-f` worked, didn't they?
The command w/o the -f is known to not present the above warning/errors. This is normal.