RuntimeTools / appmetrics

Node Application Metrics provides a foundational infrastructure for collecting resource and performance monitoring data for Node.js-based applications.
https://developer.ibm.com/open/node-application-metrics/
Apache License 2.0
970 stars 125 forks source link

Error omr-agentcore/libhcmqtt.so , I cannot install package on docker node bullseys-slim:18.10 #660

Open jirayuth289 opened 2 months ago

jirayuth289 commented 2 months ago

My Dockerfile

FROM node:18.10-bullseye-slim

WORKDIR /app

RUN apt-get update \
  && apt-get install -y g++ gcc make build-essential python \
  && apt-get clean

RUN npm install node-gyp -g

COPY --chown=node:node . /app

RUN npm ci --only=production
.
.

After run build

collect2: error: ld returned 1 exit status make: *** [omr-agentcore/hcmqtt.target.mk:180: Release/obj.target/omr-agentcore/libhcmqtt.so] Error 1

23.79 npm ERR! code 1 23.79 npm ERR! path /app/node_modules/appmetrics 23.79 npm ERR! command failed 23.79 npm ERR! command sh -c -- node showBuildInfo.js && node-gyp rebuild 23.79 npm ERR! Wed, 15 May 2024 04:50:46 GMT 23.79 npm ERR! **** 23.79 npm ERR! You are installing the Node Application Metrics monitoring and profiling module. 23.79 npm ERR! Licensed under the Apache License, Version 2.0 (the "License") 23.79 npm ERR! you may not use this file except in compliance with the License. 23.79 npm ERR! You may obtain a copy of the License at 23.79 npm ERR! 23.79 npm ERR! http://www.apache.org/licenses/LICENSE-2.0 23.79 npm ERR! 23.79 npm ERR! Unless required by applicable law or agreed to in writing, software 23.79 npm ERR! distributed under the License is distributed on an "AS IS" BASIS, 23.79 npm ERR! WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 23.79 npm ERR! See the License for the specific language governing permissions and 23.79 npm ERR! limitations under the License. 23.79 npm ERR! **** 23.79 npm ERR! 23.79 npm ERR! 23.79 npm ERR! **** 23.79 npm ERR! Appmetrics uses node-gyp to compile and build local binary libraries to enhance execution performance. If the following compilation and build logs contain errors, make sure you have the node-gyp pre-requisites installed (https://github.com/nodejs/node-gyp#installation). If you have them and the build still had errors, see if there are any related issues at https://github.com/RuntimeTools/appmetrics/issues). If there aren't, feel free to open a new issue to report the bug. 23.79 npm ERR! **** 23.79 npm ERR! 23.79 npm ERR! 23.79 npm ERR! make: Entering directory '/app/node_modules/appmetrics/build' 23.79 npm ERR! ACTION binding_gyp_appmetrics_target_Set_appmetrics_reported_version_build_level Release/obj.target/appmetrics/geni/appmetrics.cpp 23.79 npm ERR! infile: ./src/appmetrics.cpp 23.79 npm ERR! outfile: /app/node_modules/appmetrics/build/Release/obj.target/appmetrics/geni/appmetrics.cpp 23.79 npm ERR! Replacing '"99.99.99.29991231"' with '"5.1.1.202405150450"' 23.79 npm ERR! CXX(target) Release/obj.target/appmetrics/geni/appmetrics.o 23.79 npm ERR! CXX(target) Release/obj.target/appmetrics/src/headlessutils.o 23.79 npm ERR! CXX(target) Release/obj.target/appmetrics/src/objecttracker.o 23.79 npm ERR! SOLINK_MODULE(target) Release/obj.target/appmetrics.node 23.79 npm ERR! COPY Release/appmetrics.node 23.79 npm ERR! CXX(target) Release/obj.target/heapdump/src/heapdump/heapdump.o 23.79 npm ERR! SOLINK_MODULE(target) Release/obj.target/heapdump.node 23.79 npm ERR! COPY Release/heapdump.node 23.79 npm ERR! ACTION omr_agentcore_binding_gyp_agentcore_target_Set_core_reported_version_build_level Release/obj.target/agentcore/geni/monitoring/agent/Agent.cpp 23.79 npm ERR! infile: ./src/ibmras/monitoring/agent/Agent.cpp 23.79 npm ERR! outfile: /app/node_modules/appmetrics/build/Release/obj.target/agentcore/geni/monitoring/agent/Agent.cpp 23.79 npm ERR! Replacing '"99.99.99.29991231"' with '"4.0.5.202405150450"' 23.79 npm ERR! CXX(target) Release/obj.target/agentcore/omr-agentcore/src/ibmras/common/Logger.o 23.79 npm ERR! CXX(target) Release/obj.target/agentcore/omr-agentcore/src/ibmras/common/LogManager.o 23.79 npm ERR! CXX(target) Release/obj.target/agentcore/omr-agentcore/src/ibmras/common/MemoryManager.o 23.79 npm ERR! CXX(target) Release/obj.target/agentcore/omr-agentcore/src/ibmras/common/util/FileUtils.o 23.79 npm ERR! CXX(target) Release/obj.target/agentcore/omr-agentcore/src/ibmras/common/util/LibraryUtils.o 23.79 npm ERR! CXX(target) Release/obj.target/agentcore/omr-agentcore/src/ibmras/common/port/linux/Thread.o 23.79 npm ERR! CXX(target) Release/obj.target/agentcore/omr-agentcore/src/ibmras/common/port/linux/Process.o 23.79 npm ERR! CXX(target) Release/obj.target/agentcore/omr-agentcore/src/ibmras/common/port/Lock.o 23.79 npm ERR! CXX(target) Release/obj.target/agentcore/omr-agentcore/src/ibmras/common/port/ThreadData.o 23.79 npm ERR! CXX(target) Release/obj.target/agentcore/omr-agentcore/src/ibmras/common/Properties.o 23.79 npm ERR! CXX(target) Release/obj.target/agentcore/omr-agentcore/src/ibmras/common/PropertiesFile.o 23.79 npm ERR! CXX(target) Release/obj.target/agentcore/omr-agentcore/src/ibmras/common/util/strUtils.o 23.79 npm ERR! CXX(target) Release/obj.target/agentcore/omr-agentcore/src/ibmras/common/util/sysUtils.o 23.79 npm ERR! CXX(target) Release/obj.target/agentcore/geni/monitoring/agent/Agent.o 23.79 npm ERR! CXX(target) Release/obj.target/agentcore/omr-agentcore/src/ibmras/monitoring/agent/threads/ThreadPool.o 23.79 npm ERR! CXX(target) Release/obj.target/agentcore/omr-agentcore/src/ibmras/monitoring/agent/threads/WorkerThread.o 23.79 npm ERR! CXX(target) Release/obj.target/agentcore/omr-agentcore/src/ibmras/monitoring/agent/SystemReceiver.o 23.79 npm ERR! CXX(target) Release/obj.target/agentcore/omr-agentcore/src/ibmras/monitoring/connector/ConnectorManager.o 23.79 npm ERR! CXX(target) Release/obj.target/agentcore/omr-agentcore/src/ibmras/monitoring/agent/Bucket.o 23.79 npm ERR! CXX(target) Release/obj.target/agentcore/omr-agentcore/src/ibmras/monitoring/agent/BucketList.o 23.79 npm ERR! CXX(target) Release/obj.target/agentcore/omr-agentcore/src/ibmras/monitoring/Plugin.o 23.79 npm ERR! CXX(target) Release/obj.target/agentcore/omr-agentcore/src/ibmras/monitoring/connector/configuration/ConfigurationConnector.o 23.79 npm ERR! SOLINK(target) Release/obj.target/omr-agentcore/libagentcore.so 23.79 npm ERR! COPY Release/libagentcore.so 23.79 npm ERR! CXX(target) Release/obj.target/hcapiplugin/omr-agentcore/src/ibmras/monitoring/connector/api/APIConnector.o 23.79 npm ERR! SOLINK(target) Release/obj.target/omr-agentcore/libhcapiplugin.so 23.79 npm ERR! COPY Release/libhcapiplugin.so 23.79 npm ERR! CXX(target) Release/obj.target/envplugin/omr-agentcore/src/ibmras/monitoring/plugins/common/environment/envplugin.o 23.79 npm ERR! SOLINK(target) Release/obj.target/omr-agentcore/libenvplugin.so 23.79 npm ERR! COPY Release/libenvplugin.so 23.79 npm ERR! CXX(target) Release/obj.target/cpuplugin/omr-agentcore/src/ibmras/monitoring/plugins/common/cpu/cpuplugin.o 23.79 npm ERR! SOLINK(target) Release/obj.target/omr-agentcore/libcpuplugin.so 23.79 npm ERR! COPY Release/libcpuplugin.so 23.79 npm ERR! CXX(target) Release/obj.target/memoryplugin/omr-agentcore/src/ibmras/monitoring/plugins/common/memory/MemoryPlugin.o 23.79 npm ERR! SOLINK(target) Release/obj.target/omr-agentcore/libmemoryplugin.so 23.79 npm ERR! COPY Release/libmemoryplugin.so 23.79 npm ERR! CXX(target) Release/obj.target/headlessplugin/omr-agentcore/src/ibmras/monitoring/connector/headless/HLConnector.o 23.79 npm ERR! SOLINK(target) Release/obj.target/omr-agentcore/libheadlessplugin.so 23.79 npm ERR! COPY Release/libheadlessplugin.so 23.79 npm ERR! CC(target) Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/Clients.o 23.79 npm ERR! CC(target) Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/Heap.o 23.79 npm ERR! CC(target) Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/LinkedList.o 23.79 npm ERR! CC(target) Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/Log.o 23.79 npm ERR! CC(target) Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/Messages.o 23.79 npm ERR! CC(target) Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/MQTTAsync.o 23.79 npm ERR! CC(target) Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/MQTTPacket.o 23.79 npm ERR! CC(target) Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/MQTTPacketOut.o 23.79 npm ERR! CC(target) Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/MQTTPersistence.o 23.79 npm ERR! CC(target) Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/MQTTPersistenceDefault.o 23.79 npm ERR! CC(target) Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/MQTTProtocolClient.o 23.79 npm ERR! CC(target) Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/MQTTProtocolOut.o 23.79 npm ERR! CC(target) Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/SocketBuffer.o 23.79 npm ERR! CC(target) Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/Socket.o 23.79 npm ERR! CC(target) Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/StackTrace.o 23.79 npm ERR! CC(target) Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/Thread.o 23.79 npm ERR! CC(target) Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/Tree.o 23.79 npm ERR! CC(target) Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/utf-8.o 23.79 npm ERR! CXX(target) Release/obj.target/hcmqtt/omr-agentcore/src/ibmras/monitoring/connector/mqtt/MQTTConnector.o 23.79 npm ERR! SOLINK(target) Release/obj.target/omr-agentcore/libhcmqtt.so 23.79 npm ERR! make: Leaving directory '/app/node_modules/appmetrics/build' 23.79 npm ERR! gyp info it worked if it ends with ok 23.79 npm ERR! gyp info using node-gyp@5.1.1 23.79 npm ERR! gyp info using node@18.10.0 | linux | arm64 23.79 npm ERR! gyp info find Python using Python version 2.7.18 found at "/usr/bin/python" 23.79 npm ERR! gyp WARN EACCES current user ("node") does not have permission to access the dev dir "/root/.cache/node-gyp/18.10.0" 23.79 npm ERR! gyp WARN EACCES attempting to reinstall using temporary dev dir "/tmp/.node-gyp" 23.79 npm ERR! gyp http GET https://nodejs.org/download/release/v18.10.0/node-v18.10.0-headers.tar.gz 23.79 npm ERR! gyp http 200 https://nodejs.org/download/release/v18.10.0/node-v18.10.0-headers.tar.gz 23.79 npm ERR! gyp http GET https://nodejs.org/download/release/v18.10.0/SHASUMS256.txt 23.79 npm ERR! gyp http 200 https://nodejs.org/download/release/v18.10.0/SHASUMS256.txt 23.79 npm ERR! (node:41) [DEP0150] DeprecationWarning: Setting process.config is deprecated. In the future the property will be read-only. 23.79 npm ERR! (Use node --trace-deprecation ... to show where the warning was created) 23.79 npm ERR! gyp info spawn /usr/bin/python 23.79 npm ERR! gyp info spawn args [ 23.79 npm ERR! gyp info spawn args '/app/node_modules/node-gyp/gyp/gyp_main.py', 23.79 npm ERR! gyp info spawn args 'binding.gyp', 23.79 npm ERR! gyp info spawn args '-f', 23.79 npm ERR! gyp info spawn args 'make', 23.79 npm ERR! gyp info spawn args '-I', 23.79 npm ERR! gyp info spawn args '/app/node_modules/appmetrics/build/config.gypi', 23.79 npm ERR! gyp info spawn args '-I', 23.79 npm ERR! gyp info spawn args '/app/node_modules/node-gyp/addon.gypi', 23.79 npm ERR! gyp info spawn args '-I', 23.79 npm ERR! gyp info spawn args '/tmp/.node-gyp/18.10.0/include/node/common.gypi', 23.79 npm ERR! gyp info spawn args '-Dlibrary=shared_library', 23.79 npm ERR! gyp info spawn args '-Dvisibility=default', 23.79 npm ERR! gyp info spawn args '-Dnode_root_dir=/tmp/.node-gyp/18.10.0', 23.79 npm ERR! gyp info spawn args '-Dnode_gyp_dir=/app/node_modules/node-gyp', 23.79 npm ERR! gyp info spawn args '-Dnode_lib_file=/tmp/.node-gyp/18.10.0/<(target_arch)/node.lib', 23.79 npm ERR! gyp info spawn args '-Dmodule_root_dir=/app/node_modules/appmetrics', 23.79 npm ERR! gyp info spawn args '-Dnode_engine=v8', 23.79 npm ERR! gyp info spawn args '--depth=.', 23.79 npm ERR! gyp info spawn args '--no-parallel', 23.79 npm ERR! gyp info spawn args '--generator-output', 23.79 npm ERR! gyp info spawn args 'build', 23.79 npm ERR! gyp info spawn args '-Goutput_dir=.' 23.79 npm ERR! gyp info spawn args ] 23.79 npm ERR! gyp info spawn make 23.79 npm ERR! gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ] 23.79 npm ERR! Release/obj.target/appmetrics/geni/appmetrics.cpp: In function 'void emitMessage(uv_async_t, int)': 23.79 npm ERR! Release/obj.target/appmetrics/geni/appmetrics.cpp:424:44: warning: 'v8::Local Nan::Callback::Call(int, v8::Local) const' is deprecated [-Wdeprecated-declarations] 23.79 npm ERR! 424 | listener->callback->Call(argc, argv); 23.79 npm ERR! | ^ 23.79 npm ERR! In file included from Release/obj.target/appmetrics/geni/appmetrics.cpp:22: 23.79 npm ERR! ../../nan/nan.h:1748:3: note: declared here 23.79 npm ERR! 1748 | Call(int argc, v8::Local argv[]) const { 23.79 npm ERR! | ^~~~ 23.79 npm ERR! Release/obj.target/appmetrics/geni/appmetrics.cpp: In function 'void lrtime(const Nan::FunctionCallbackInfo&)': 23.79 npm ERR! Release/obj.target/appmetrics/geni/appmetrics.cpp:593:64: warning: ignoring return value of 'v8::Maybe v8::Object::Set(v8::Local, uint32_t, v8::Local)', declared with attribute 'warn_unused_result' [-Wunused-result] 23.79 npm ERR! 593 | result->Set(context, 0, v8::Number::New(isolate, ts.tv_sec)); 23.79 npm ERR! | ^ 23.79 npm ERR! In file included from /tmp/.node-gyp/18.10.0/include/node/v8-array-buffer.h:13, 23.79 npm ERR! from /tmp/.node-gyp/18.10.0/include/node/v8.h:24, 23.79 npm ERR! from /tmp/.node-gyp/18.10.0/include/node/node.h:73, 23.79 npm ERR! from Release/obj.target/appmetrics/geni/appmetrics.cpp:21: 23.79 npm ERR! /tmp/.node-gyp/18.10.0/include/node/v8-object.h:247:37: note: declared here 23.79 npm ERR! 247 | V8_WARN_UNUSED_RESULT Maybe Set(Local context, uint32_t index, 23.79 npm ERR! | ^~~ 23.79 npm ERR! Release/obj.target/appmetrics/geni/appmetrics.cpp:594:78: warning: ignoring return value of 'v8::Maybe v8::Object::Set(v8::Local, uint32_t, v8::Local)', declared with attribute 'warn_unused_result' [-Wunused-result] 23.79 npm ERR! 594 | result->Set(context, 1, v8::Integer::NewFromUnsigned(isolate, ts.tv_nsec)); 23.79 npm ERR! | ^ 23.79 npm ERR! In file included from /tmp/.node-gyp/18.10.0/include/node/v8-array-buffer.h:13, 23.80 npm ERR! from /tmp/.node-gyp/18.10.0/include/node/v8.h:24, 23.80 npm ERR! from /tmp/.node-gyp/18.10.0/include/node/node.h:73, 23.80 npm ERR! from Release/obj.target/appmetrics/geni/appmetrics.cpp:21: 23.80 npm ERR! /tmp/.node-gyp/18.10.0/include/node/v8-object.h:247:37: note: declared here 23.80 npm ERR! 247 | V8_WARN_UNUSED_RESULT Maybe Set(Local context, uint32_t index, 23.80 npm ERR! | ^~~ 23.80 npm ERR! Release/obj.target/appmetrics/geni/appmetrics.cpp: In function 'void init(v8::Local, v8::Local)': 23.80 npm ERR! Release/obj.target/appmetrics/geni/appmetrics.cpp:713:52: warning: cast between incompatible function types from 'void ()(uv_async_t, int)' {aka 'void ()(uv_async_s, int)'} to 'uv_async_cb' {aka 'void ()(uv_async_s)'} [-Wcast-function-type] 23.80 npm ERR! 713 | uv_async_init(uv_default_loop(), messageAsync, (uv_async_cb)emitMessage); 23.80 npm ERR! | ^~~~~~~~ 23.80 npm ERR! In file included from Release/obj.target/appmetrics/geni/appmetrics.cpp:21: 23.80 npm ERR! Release/obj.target/appmetrics/geni/appmetrics.cpp: At global scope: 23.80 npm ERR! /tmp/.node-gyp/18.10.0/include/node/node.h:890:7: warning: cast between incompatible function types from 'void ()(v8::Local, v8::Local)' to 'node::addon_register_func' {aka 'void ()(v8::Local, v8::Local, void)'} [-Wcast-function-type] 23.80 npm ERR! 890 | (node::addon_register_func) (regfunc), \ 23.80 npm ERR! | ^~~~~~~~~ 23.80 npm ERR! /tmp/.node-gyp/18.10.0/include/node/node.h:924:3: note: in expansion of macro 'NODE_MODULE_X' 23.80 npm ERR! 924 | NODE_MODULE_X(modname, regfunc, NULL, 0) // NOLINT (readability/null_usage) 23.80 npm ERR! | ^~~~~ 23.80 npm ERR! Release/obj.target/appmetrics/geni/appmetrics.cpp:768:1: note: in expansion of macro 'NODE_MODULE' 23.80 npm ERR! 768 | NODE_MODULE(appmetrics, init) 23.80 npm ERR! | ^~~ 23.80 npm ERR! ../src/headlessutils.cpp: In function 'void headless::asyncfunc(uv_async_t)': 23.80 npm ERR! ../src/headlessutils.cpp:51:39: warning: 'v8::Local Nan::Callback::Call(int, v8::Local) const' is deprecated [-Wdeprecated-declarations] 23.80 npm ERR! 51 | headless::zipFunction->Call(1, argv); 23.80 npm ERR! | ^ 23.80 npm ERR! In file included from ../src/headlessutils.h:21, 23.80 npm ERR! from ../src/headlessutils.cpp:18: 23.80 npm ERR! ../../nan/nan.h:1748:3: note: declared here 23.80 npm ERR! 1748 | Call(int argc, v8::Local argv[]) const { 23.80 npm ERR! | ^~~~ 23.80 npm ERR! ../src/objecttracker.cpp: In function 'Nan::NAN_METHOD_RETURN_TYPE getObjectHistogram(Nan::NAN_METHOD_ARGS_TYPE)': 23.80 npm ERR! ../src/objecttracker.cpp:131:46: warning: ignoring return value of 'v8::Maybe v8::Object::Set(v8::Local, v8::Local, v8::Local)', declared with attribute 'warn_unused_result' [-Wunused-result] 23.80 npm ERR! 131 | histogram->Set(currentContext, name, tuple); 23.80 npm ERR! | ^ 23.80 npm ERR! In file included from /tmp/.node-gyp/18.10.0/include/node/v8-array-buffer.h:13, 23.80 npm ERR! from /tmp/.node-gyp/18.10.0/include/node/v8.h:24, 23.80 npm ERR! from /tmp/.node-gyp/18.10.0/include/node/node.h:73, 23.80 npm ERR! from ../src/objecttracker.cpp:20: 23.80 npm ERR! /tmp/.node-gyp/18.10.0/include/node/v8-object.h:244:37: note: declared here 23.80 npm ERR! 244 | V8_WARN_UNUSED_RESULT Maybe Set(Local context, 23.80 npm ERR! | ^~~ 23.80 npm ERR! ../src/objecttracker.cpp:136:49: warning: ignoring return value of 'v8::Maybe v8::Object::Set(v8::Local, v8::Local, v8::Local)', declared with attribute 'warn_unused_result' [-Wunused-result] 23.80 npm ERR! 136 | tuple->Set(currentContext, countName, newcount); 23.80 npm ERR! | ^ 23.80 npm ERR! In file included from /tmp/.node-gyp/18.10.0/include/node/v8-array-buffer.h:13, 23.80 npm ERR! from /tmp/.node-gyp/18.10.0/include/node/v8.h:24, 23.80 npm ERR! from /tmp/.node-gyp/18.10.0/include/node/node.h:73, 23.80 npm ERR! from ../src/objecttracker.cpp:20: 23.80 npm ERR! /tmp/.node-gyp/18.10.0/include/node/v8-object.h:244:37: note: declared here 23.80 npm ERR! 244 | V8_WARN_UNUSED_RESULT Maybe Set(Local context, 23.80 npm ERR! | ^~~ 23.80 npm ERR! ../src/objecttracker.cpp:138:46: warning: ignoring return value of 'v8::Maybe v8::Object::Set(v8::Local, v8::Local, v8::Local)', declared with attribute 'warn_unused_result' [-Wunused-result] 23.80 npm ERR! 138 | tuple->Set(currentContext,sizeName, newsize); 23.80 npm ERR! | ^ 23.80 npm ERR! In file included from /tmp/.node-gyp/18.10.0/include/node/v8-array-buffer.h:13, 23.80 npm ERR! from /tmp/.node-gyp/18.10.0/include/node/v8.h:24, 23.80 npm ERR! from /tmp/.node-gyp/18.10.0/include/node/node.h:73, 23.80 npm ERR! from ../src/objecttracker.cpp:20: 23.80 npm ERR! /tmp/.node-gyp/18.10.0/include/node/v8-object.h:244:37: note: declared here 23.80 npm ERR! 244 | V8_WARN_UNUSED_RESULT Maybe Set(Local context, 23.80 npm ERR! | ^~~ 23.80 npm ERR! ../src/heapdump/heapdump.cc: In function 'void {anonymous}::InvokeCallback(const char)': 23.80 npm ERR! ../src/heapdump/heapdump.cc:143:32: warning: 'v8::Local node::MakeCallback(v8::Isolate, v8::Local, v8::Local, int, v8::Local)' is deprecated: Use MakeCallback(..., async_context) [-Wdeprecated-declarations] 23.80 npm ERR! 143 | argc, argv); 23.80 npm ERR! | ^ 23.80 npm ERR! In file included from ../src/heapdump/heapdump.cc:15: 23.80 npm ERR! /tmp/.node-gyp/18.10.0/include/node/node.h:195:50: note: declared here 23.80 npm ERR! 195 | NODE_EXTERN v8::Local MakeCallback( 23.80 npm ERR! | ^~~~ 23.80 npm ERR! /tmp/.node-gyp/18.10.0/include/node/node.h:112:42: note: in definition of macro 'NODE_DEPRECATED' 23.80 npm ERR! 112 | attribute((deprecated(message))) declarator 23.80 npm ERR! | ^~~~~~ 23.80 npm ERR! ../src/heapdump/heapdump.cc: In function 'void {anonymous}::Initialize(v8::Local)': 23.80 npm ERR! ../src/heapdump/heapdump.cc:165:51: warning: ignoring return value of 'v8::Maybe v8::Object::Set(v8::Local, v8::Local, v8::Local)', declared with attribute 'warn_unused_result' [-Wunused-result] 23.80 npm ERR! 165 | C::Integer::New(isolate, kForkFlag)); 23.80 npm ERR! | ^ 23.80 npm ERR! In file included from /tmp/.node-gyp/18.10.0/include/node/v8-array-buffer.h:13, 23.80 npm ERR! from /tmp/.node-gyp/18.10.0/include/node/v8.h:24, 23.80 npm ERR! from /tmp/.node-gyp/18.10.0/include/node/node.h:73, 23.80 npm ERR! from ../src/heapdump/heapdump.cc:15: 23.80 npm ERR! /tmp/.node-gyp/18.10.0/include/node/v8-object.h:244:37: note: declared here 23.80 npm ERR! 244 | V8_WARN_UNUSED_RESULT Maybe Set(Local context, 23.80 npm ERR! | ^~~ 23.80 npm ERR! ../src/heapdump/heapdump.cc:167:53: warning: ignoring return value of 'v8::Maybe v8::Object::Set(v8::Local, v8::Local, v8::Local)', declared with attribute 'warn_unused_result' [-Wunused-result] 23.80 npm ERR! 167 | C::Integer::New(isolate, kSignalFlag)); 23.80 npm ERR! | ^ 23.80 npm ERR! In file included from /tmp/.node-gyp/18.10.0/include/node/v8-array-buffer.h:13, 23.80 npm ERR! from /tmp/.node-gyp/18.10.0/include/node/v8.h:24, 23.80 npm ERR! from /tmp/.node-gyp/18.10.0/include/node/node.h:73, 23.80 npm ERR! from ../src/heapdump/heapdump.cc:15: 23.80 npm ERR! /tmp/.node-gyp/18.10.0/include/node/v8-object.h:244:37: note: declared here 23.80 npm ERR! 244 | V8_WARN_UNUSED_RESULT Maybe Set(Local context, 23.80 npm ERR! | ^~~ 23.80 npm ERR! ../src/heapdump/heapdump.cc:170:56: warning: ignoring return value of 'v8::Maybe v8::Object::Set(v8::Local, v8::Local, v8::Local)', declared with attribute 'warn_unused_result' [-Wunused-result] 23.80 npm ERR! 170 | ->GetFunction(context).ToLocalChecked()); 23.80 npm ERR! | ^ 23.80 npm ERR! In file included from /tmp/.node-gyp/18.10.0/include/node/v8-array-buffer.h:13, 23.80 npm ERR! from /tmp/.node-gyp/18.10.0/include/node/v8.h:24, 23.80 npm ERR! from /tmp/.node-gyp/18.10.0/include/node/node.h:73, 23.80 npm ERR! from ../src/heapdump/heapdump.cc:15: 23.80 npm ERR! /tmp/.node-gyp/18.10.0/include/node/v8-object.h:244:37: note: declared here 23.80 npm ERR! 244 | V8_WARN_UNUSED_RESULT Maybe Set(Local context, 23.80 npm ERR! | ^~~ 23.80 npm ERR! ../src/heapdump/heapdump.cc:173:56: warning: ignoring return value of 'v8::Maybe v8::Object::Set(v8::Local, v8::Local, v8::Local)', declared with attribute 'warn_unused_result' [-Wunused-result] 23.80 npm ERR! 173 | ->GetFunction(context).ToLocalChecked()); 23.80 npm ERR! | ^ 23.80 npm ERR! In file included from /tmp/.node-gyp/18.10.0/include/node/v8-array-buffer.h:13, 23.80 npm ERR! from /tmp/.node-gyp/18.10.0/include/node/v8.h:24, 23.80 npm ERR! from /tmp/.node-gyp/18.10.0/include/node/node.h:73, 23.80 npm ERR! from ../src/heapdump/heapdump.cc:15: 23.80 npm ERR! /tmp/.node-gyp/18.10.0/include/node/v8-object.h:244:37: note: declared here 23.80 npm ERR! 244 | V8_WARN_UNUSED_RESULT Maybe Set(Local context, 23.80 npm ERR! | ^~~ 23.80 npm ERR! In file included from ../src/heapdump/heapdump.cc:15: 23.80 npm ERR! ../src/heapdump/heapdump.cc: At global scope: 23.80 npm ERR! /tmp/.node-gyp/18.10.0/include/node/node.h:890:7: warning: cast between incompatible function types from 'void ()(v8::Local)' to 'node::addon_register_func' {aka 'void ()(v8::Local, v8::Local, void)'} [-Wcast-function-type] 23.80 npm ERR! 890 | (node::addon_register_func) (regfunc), \ 23.80 npm ERR! | ^~~~~~~~~ 23.80 npm ERR! /tmp/.node-gyp/18.10.0/include/node/node.h:924:3: note: in expansion of macro 'NODE_MODULE_X' 23.80 npm ERR! 924 | NODE_MODULE_X(modname, regfunc, NULL, 0) // NOLINT (readability/null_usage) 23.80 npm ERR! | ^~~~~ 23.80 npm ERR! ../src/heapdump/heapdump.cc:188:1: note: in expansion of macro 'NODE_MODULE' 23.80 npm ERR! 188 | NODE_MODULE(addon, Initialize) 23.80 npm ERR! | ^~~ 23.80 npm ERR! In file included from ../omr-agentcore/src/ibmras/common/port/linux/Thread.cpp:23: 23.80 npm ERR! ../omr-agentcore/src/ibmras/common/port/linux/Thread.cpp: In function 'void ibmras::common::port::wrapper(void)': 23.80 npm ERR! ../omr-agentcore/src/ibmras/common/port/linux/Thread.cpp:56:24: warning: cast between incompatible function types from 'ibmras::common::port::THREAD_CALLBACK' {aka 'void ()(ibmras::common::port::ThreadData)'} to 'void ()(void)' [-Wcast-function-type] 23.80 npm ERR! 56 | pthread_cleanup_push(reinterpret_cast<void ()(void)>(data->getStopMethod()), data); 23.80 npm ERR! | ^~~~~~~~~~~~ 23.80 npm ERR! ../omr-agentcore/org.eclipse.paho.mqtt.c/src/MQTTAsync.c: In function 'MQTTAsync_cycle': 23.80 npm ERR! ../omr-agentcore/org.eclipse.paho.mqtt.c/src/MQTTAsync.c:2561:13: warning: variable 'nosockets_count' set but not used [-Wunused-but-set-variable] 23.80 npm ERR! 2561 | static int nosockets_count = 0; 23.80 npm ERR! | ^~~~~~~ 23.80 npm ERR! ../omr-agentcore/org.eclipse.paho.mqtt.c/src/MQTTPersistenceDefault.c: In function 'pstopen': 23.80 npm ERR! ../omr-agentcore/org.eclipse.paho.mqtt.c/src/MQTTPersistenceDefault.c:101:3: warning: 'sprintf' argument 3 overlaps destination object 'pCrtDirName' [-Wrestrict] 23.80 npm ERR! 101 | sprintf( pCrtDirName, "%s/%s", pCrtDirName, pToken ); 23.80 npm ERR! | ^~~~~~~~~~~~ 23.80 npm ERR! /usr/bin/ld: ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/Log.o:(.bss+0x490): multiple definition of Log_levels'; ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/Heap.o:(.bss+0x78): first defined here 23.80 npm ERR! /usr/bin/ld: ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/Messages.o:(.bss+0x0): multiple definition ofLog_levels'; ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/Heap.o:(.bss+0x78): first defined here 23.80 npm ERR! /usr/bin/ld: ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/MQTTAsync.o:(.bss+0x1f0): multiple definition of Log_levels'; ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/Heap.o:(.bss+0x78): first defined here 23.80 npm ERR! /usr/bin/ld: ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/MQTTPacket.o:(.bss+0xc): multiple definition ofLog_levels'; ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/Heap.o:(.bss+0x78): first defined here 23.80 npm ERR! /usr/bin/ld: ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/MQTTPacketOut.o:(.bss+0x0): multiple definition of Log_levels'; ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/Heap.o:(.bss+0x78): first defined here 23.80 npm ERR! /usr/bin/ld: ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/MQTTPersistence.o:(.bss+0x0): multiple definition ofLog_levels'; ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/Heap.o:(.bss+0x78): first defined here 23.80 npm ERR! /usr/bin/ld: ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/MQTTPersistenceDefault.o:(.bss+0x0): multiple definition of Log_levels'; ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/Heap.o:(.bss+0x78): first defined here 23.80 npm ERR! /usr/bin/ld: ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/MQTTProtocolClient.o:(.bss+0x0): multiple definition ofLog_levels'; ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/Heap.o:(.bss+0x78): first defined here 23.80 npm ERR! /usr/bin/ld: ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/MQTTProtocolOut.o:(.bss+0x0): multiple definition of Log_levels'; ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/Heap.o:(.bss+0x78): first defined here 23.80 npm ERR! /usr/bin/ld: ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/SocketBuffer.o:(.bss+0x30): multiple definition ofLog_levels'; ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/Heap.o:(.bss+0x78): first defined here 23.80 npm ERR! /usr/bin/ld: ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/Socket.o:(.bss+0x288): multiple definition of Log_levels'; ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/Heap.o:(.bss+0x78): first defined here 23.80 npm ERR! /usr/bin/ld: ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/StackTrace.o:(.bss+0x966d0): multiple definition ofLog_levels'; ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/Heap.o:(.bss+0x78): first defined here 23.80 npm ERR! /usr/bin/ld: ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/Thread.o:(.bss+0x0): multiple definition of Log_levels'; ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/Heap.o:(.bss+0x78): first defined here 23.80 npm ERR! /usr/bin/ld: ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/utf-8.o:(.bss+0x0): multiple definition ofLog_levels'; ./Release/obj.target/hcmqtt/omr-agentcore/org.eclipse.paho.mqtt.c/src/Heap.o:(.bss+0x78): first defined here 23.80 npm ERR! collect2: error: ld returned 1 exit status 23.80 npm ERR! make: *** [omr-agentcore/hcmqtt.target.mk:180: Release/obj.target/omr-agentcore/libhcmqtt.so] Error 1 23.80 npm ERR! gyp ERR! build error 23.80 npm ERR! gyp ERR! stack Error: make failed with exit code: 2 23.80 npm ERR! gyp ERR! stack at ChildProcess.onExit (/app/node_modules/node-gyp/lib/build.js:194:23) 23.80 npm ERR! gyp ERR! stack at ChildProcess.emit (node:events:513:28) 23.80 npm ERR! gyp ERR! stack at ChildProcess._handle.onexit (node:internal/child_process:291:12) 23.80 npm ERR! gyp ERR! System Linux 6.4.16-linuxkit 23.80 npm ERR! gyp ERR! command "/usr/local/bin/node" "/app/node_modules/.bin/node-gyp" "rebuild" 23.80 npm ERR! gyp ERR! cwd /app/node_modules/appmetrics 23.80 npm ERR! gyp ERR! node -v v18.10.0 23.80 npm ERR! gyp ERR! node-gyp -v v5.1.1 23.80 npm ERR! gyp ERR! not ok 23.80 23.80 npm ERR! A complete log of this run can be found in: 23.80 npm ERR! /root/.npm/_logs/2024-05-15T04_50_37_854Z-debug-0.log

Dockerfile:14 12 | COPY --chown=node:node . /app 13 |
14 | >>> RUN npm ci --only=production 15 |
16 | EXPOSE 8080 ERROR: failed to solve: process "/bin/sh -c npm ci --only=production" did not complete successfully: exit code: 1