calcom / docker

The Docker configuration for Cal.com is an effort powered by people within the community. Cal.com, Inc. does not provide official support for Docker, but we will accept fixes and documentation. Use at your own risk.
MIT License
662 stars 344 forks source link

Update node to version 19 #254

Closed jokay closed 1 year ago

jokay commented 1 year ago

Update node to use version 19.

krumware commented 1 year ago

I believe cal.com core is still on node:18, so we'd like to maintain parity there, but will check.

jokay commented 1 year ago

Yes, this makes sense :+1:

jokay commented 1 year ago

As you said, it's tested only on node:18, see here therefore we can close this PR.

It works using node:19 but I would stay at the same version as the application as well.

jokay commented 1 year ago

@krumware my problem is, if I don't change it to use node:19 the build will succeed but it won't run.

This is what I get in the logs during start if build with node:18:

node[1]: ../src/node_platform.cc:68:std::unique_ptr<long unsigned int> node::WorkerThreadsTaskRunner::DelayedTaskScheduler::Start(): Assertion `(0) == (uv_thread_create(t.get(), start_thread, this))' failed.
 1: 0xb7a940 node::Abort() [node]
 2: 0xb7a9be  [node]
 3: 0xbe98be  [node]
 4: 0xbe99a1 node::NodePlatform::NodePlatform(int, v8::TracingController*, v8::PageAllocator*) [node]
 5: 0xb38f5b node::InitializeOncePerProcess(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > const&, node::ProcessFlags::Flags) [node]
 6: 0xb395ab node::Start(int, char**) [node]
 7: 0x7f63bbc9518a  [/lib/x86_64-linux-gnu/libc.so.6]
 8: 0x7f63bbc95245 __libc_start_main [/lib/x86_64-linux-gnu/libc.so.6]
 9: 0xabbdee _start [node]
node[1]: ../src/node_platform.cc:68:std::unique_ptr<long unsigned int> node::WorkerThreadsTaskRunner::DelayedTaskScheduler::Start(): Assertion `(0) == (uv_thread_create(t.get(), start_thread, this))' failed.
 1: 0xb7a940 node::Abort() [node]
 2: 0xb7a9be  [node]
 3: 0xbe98be  [node]
 4: 0xbe99a1 node::NodePlatform::NodePlatform(int, v8::TracingController*, v8::PageAllocator*) [node]
 5: 0xb38f5b node::InitializeOncePerProcess(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > const&, node::ProcessFlags::Flags) [node]
 6: 0xb395ab node::Start(int, char**) [node]
 7: 0x7fa3e963718a  [/lib/x86_64-linux-gnu/libc.so.6]
 8: 0x7fa3e9637245 __libc_start_main [/lib/x86_64-linux-gnu/libc.so.6]
 9: 0xabbdee _start [node]
node[1]: ../src/node_platform.cc:68:std::unique_ptr<long unsigned int> node::WorkerThreadsTaskRunner::DelayedTaskScheduler::Start(): Assertion `(0) == (uv_thread_create(t.get(), start_thread, this))' failed.
 1: 0xb7a940 node::Abort() [node]
 2: 0xb7a9be  [node]
 3: 0xbe98be  [node]
 4: 0xbe99a1 node::NodePlatform::NodePlatform(int, v8::TracingController*, v8::PageAllocator*) [node]
 5: 0xb38f5b node::InitializeOncePerProcess(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > const&, node::ProcessFlags::Flags) [node]
 6: 0xb395ab node::Start(int, char**) [node]
 7: 0x7f8e2ad9d18a  [/lib/x86_64-linux-gnu/libc.so.6]
 8: 0x7f8e2ad9d245 __libc_start_main [/lib/x86_64-linux-gnu/libc.so.6]
 9: 0xabbdee _start [node]
node[1]: ../src/node_platform.cc:68:std::unique_ptr<long unsigned int> node::WorkerThreadsTaskRunner::DelayedTaskScheduler::Start(): Assertion `(0) == (uv_thread_create(t.get(), start_thread, this))' failed.
 1: 0xb7a940 node::Abort() [node]
 2: 0xb7a9be  [node]
 3: 0xbe98be  [node]
 4: 0xbe99a1 node::NodePlatform::NodePlatform(int, v8::TracingController*, v8::PageAllocator*) [node]
 5: 0xb38f5b node::InitializeOncePerProcess(std::vector<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::allocator<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> > > > const&, node::ProcessFlags::Flags) [node]
 6: 0xb395ab node::Start(int, char**) [node]
 7: 0x7f28f1fdf18a  [/lib/x86_64-linux-gnu/libc.so.6]
 8: 0x7f28f1fdf245 __libc_start_main [/lib/x86_64-linux-gnu/libc.so.6]
 9: 0xabbdee _start [node]
krumware commented 1 year ago

What cpu architecture are you running the build on? This seems like something beyond the node version.

jokay commented 1 year ago

Build is on amd64 (Docker 24.0.2) and it will run on amd64 (Docker 19.03.15).

The only change I made is from node:18 to node:19 in the Dockerfile to make it runnable.