docker icon indicating copy to clipboard operation
docker copied to clipboard

No way to build my own image

Open djiworks opened this issue 2 years ago • 4 comments

What I run

DOCKER_BUILDKIT=0 sudo docker compose build calcom

What I get

=> CACHED [builder 5/7] COPY calcom/packages ./packages                                                                                            0.0s
 => ERROR [builder 6/7] RUN yarn global add turbo &&     yarn config set network-timeout 1000000000 -g &&     turbo prune --scope=@calcom/web --d  25.9s

#0 15.17 yarn config v1.22.19                                                                                                                            
#0 15.19 success Set "network-timeout" to "1000000000".
#0 15.19 Done in 0.03s.
#0 16.94  ERROR  could not determine if yarn is using `nodeLinker: node-modules`: .yarnrc.yml: open /calcom/.yarnrc.yml: no such file or directory
#0 16.94 Turbo error: could not determine if yarn is using `nodeLinker: node-modules`: .yarnrc.yml: open /calcom/.yarnrc.yml: no such file or directory
------
failed to solve: executor failed running [/bin/sh -c yarn global add turbo &&     yarn config set network-timeout 1000000000 -g &&     turbo prune --scope=@calcom/web --docker &&     yarn install]: exit code: 1

What I tried (1)

Copy the file from calcom during build phases adding this line into Dockerfile COPY calcom/.yarnrc.yml ./

diff --git a/Dockerfile b/Dockerfile
index e628b00..9c827ba 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -17,6 +17,7 @@ ENV NEXT_PUBLIC_WEBAPP_URL=http://NEXT_PUBLIC_WEBAPP_URL_PLACEHOLDER \
     NODE_OPTIONS=--max-old-space-size=${MAX_OLD_SPACE_SIZE}
 
 COPY calcom/package.json calcom/yarn.lock calcom/turbo.json calcom/git-init.sh calcom/git-setup.sh ./
+COPY calcom/.yarnrc.yml ./^M
 COPY calcom/apps/web ./apps/web
 COPY calcom/packages ./packages

Results:

=> CACHED [builder 6/8] COPY calcom/packages ./packages                                                                                            0.0s
 => ERROR [builder 7/8] RUN yarn global add turbo &&     yarn config set network-timeout 1000000000 -g &&     turbo prune --scope=@calcom/web --do  2.9s
------                                                                                                                                                   
 > [builder 7/8] RUN yarn global add turbo &&     yarn config set network-timeout 1000000000 -g &&     turbo prune --scope=@calcom/web --docker &&     yarn install:                                                                                                                                              
#0 1.764 node:internal/modules/cjs/loader:1024                                                                                                           
#0 1.764   throw err;                                                                                                                                    
#0 1.764   ^                                                                                                                                             
#0 1.764                                                                                                                                                 
#0 1.764 Error: Cannot find module '/calcom/.yarn/releases/yarn-3.4.1.cjs'                                                                               
#0 1.764     at Function.Module._resolveFilename (node:internal/modules/cjs/loader:1021:15)                                                              
#0 1.764     at Function.Module._load (node:internal/modules/cjs/loader:866:27)                                                                          
#0 1.764     at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:81:12)
#0 1.764     at node:internal/main/run_main_module:22:47 {
#0 1.764   code: 'MODULE_NOT_FOUND',
#0 1.764   requireStack: []
#0 1.764 }
------
failed to solve: executor failed running [/bin/sh -c yarn global add turbo &&     yarn config set network-timeout 1000000000 -g &&     turbo prune --scope=@calcom/web --docker &&     yarn install]: exit code: 1

What I tried (2)

diff --git a/.yarnrc.yml b/.yarnrc.yml
index fd204f870..4df026a47 100644
--- a/.yarnrc.yml
+++ b/.yarnrc.yml
@@ -4,4 +4,4 @@ plugins:
   - path: .yarn/plugins/@yarnpkg/plugin-interactive-tools.cjs
     spec: "@yarnpkg/plugin-interactive-tools"
 
-yarnPath: .yarn/releases/yarn-3.4.1.cjs
+# yarnPath: .yarn/releases/yarn-3.4.1.cjs

Results:

 => [builder 6/8] COPY calcom/packages ./packages                                                                                                   7.0s
 => ERROR [builder 7/8] RUN yarn global add turbo &&     yarn config set network-timeout 1000000000 -g &&     turbo prune --scope=@calcom/web --d  24.8s
------                                                                                                                                                   
 > [builder 7/8] RUN yarn global add turbo &&     yarn config set network-timeout 1000000000 -g &&     turbo prune --scope=@calcom/web --docker &&     yarn install:                                                                                                                                              
#0 2.971 yarn global v1.22.19                                                                                                                            
#0 3.019 [1/4] Resolving packages...                                                                                                                     
#0 5.970 [2/4] Fetching packages...                                                                                                                      
#0 11.89 [3/4] Linking dependencies...                                                                                                                   
#0 13.03 [4/4] Building fresh packages...                                                                                                                
#0 13.17 success Installed "[email protected]" with binaries:                                                                                                  
#0 13.17       - turbo                                                                                                                                   
#0 13.17 Done in 10.21s.                                                                                                                                 
#0 13.45 yarn config v1.22.19                                                                                                                            
#0 13.47 success Set "network-timeout" to "1000000000".
#0 13.47 Done in 0.03s.
#0 14.51 Generating pruned monorepo for @calcom/web in /calcom/out
#0 14.69  - Added @calcom/app-store
#0 14.69  - Added @calcom/app-store-cli
#0 14.69  - Added @calcom/config
#0 14.69  - Added @calcom/core
#0 14.85  - Added @calcom/dailyvideo
#0 14.86  - Added @calcom/dayjs
#0 14.86  - Added @calcom/embed-core
#0 14.86  - Added @calcom/embed-react
#0 14.86  - Added @calcom/embed-snippet
#0 14.86  - Added @calcom/eslint-plugin-eslint
#0 14.88  - Added @calcom/features
#0 14.89  - Added @calcom/lib
#0 15.37  - Added @calcom/office365video
#0 15.40  - Added @calcom/prisma
#0 15.40  - Added @calcom/trpc
#0 15.40  - Added @calcom/tsconfig
#0 15.41  - Added @calcom/types
#0 15.42  - Added @calcom/ui
#0 15.46  - Added @calcom/web
#0 16.66  - Added @calcom/zoomvideo
#0 16.92 yarn install v1.22.19
#0 17.14 [1/5] Validating package.json...
#0 17.18 error [email protected]: The engine "node" is incompatible with this module. Expected version ">=18.x". Got "16.19.1"
#0 17.19 error Found incompatible module.
#0 17.19 info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
------
failed to solve: executor failed running [/bin/sh -c yarn global add turbo &&     yarn config set network-timeout 1000000000 -g &&     turbo prune --scope=@calcom/web --docker &&     yarn install]: exit code: 1

What I tried (3)

diff --git a/Dockerfile b/Dockerfile
index e628b00..21c7567 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -1,4 +1,4 @@
-FROM node:16 as builder
+FROM node:18 as builder^M
 
 WORKDIR /calcom

Results:

=> [builder 6/8] COPY calcom/packages ./packages                                                                                                  10.1s
 => ERROR [builder 7/8] RUN yarn global add turbo &&     yarn config set network-timeout 1000000000 -g &&     turbo prune --scope=@calcom/web --  237.5s 
 => [runner  4/10] COPY calcom/package.json calcom/yarn.lock calcom/turbo.json ./                                                                   2.5s 
------                                                                                                                                                   
 > [builder 7/8] RUN yarn global add turbo &&     yarn config set network-timeout 1000000000 -g &&     turbo prune --scope=@calcom/web --docker &&     yarn install:                                                                                                                                              
#0 2.494 yarn global v1.22.19                                                                                                                            
#0 2.562 [1/4] Resolving packages...                                                                                                                     
#0 3.100 [2/4] Fetching packages...                                                                                                                      
#0 8.596 [3/4] Linking dependencies...
#0 12.45 [4/4] Building fresh packages...
#0 13.38 success Installed "[email protected]" with binaries:
#0 13.38       - turbo
#0 13.38 Done in 10.89s.
#0 14.20 yarn config v1.22.19
#0 14.22 success Set "network-timeout" to "1000000000".
#0 14.23 Done in 0.03s.
#0 16.16 Generating pruned monorepo for @calcom/web in /calcom/out
#0 16.46  - Added @calcom/app-store
#0 16.46  - Added @calcom/app-store-cli
#0 16.46  - Added @calcom/config
#0 16.47  - Added @calcom/core
#0 17.24  - Added @calcom/dailyvideo
...
#0 18.97  - Added @calcom/zoomvideo
#0 19.27 yarn install v1.22.19
#0 19.49 [1/5] Validating package.json...
#0 19.53 [2/5] Resolving packages...
#0 89.33 warning jest-environment-jsdom > jsdom > [email protected]: Use your platform's native performance.now() and performance.timeOrigin.
#0 118.4 warning workspace-aggregator-e474f423-c6b8-45fe-b968-04fe120a367a > @calcom/web > @types/[email protected]: This is a stub types definition. stripe provides its own type definitions, so you do not need this installed.
#0 124.8 warning workspace-aggregator-e474f423-c6b8-45fe-b968-04fe120a367a > @calcom/routing-forms > [email protected]: Please migrate to new @react-awesome-query-builder/*. See https://github.com/ukrbublik/react-awesome-query-builder#migration-to-600
#0 136.8 warning workspace-aggregator-e474f423-c6b8-45fe-b968-04fe120a367a > @calcom/web > @vercel/edge-functions-ui > [email protected]: All features of next-transpile-modules are now natively built-in Next.js 13.1. Please use Next's transpilePackages option :)
#0 143.9 warning Resolution field "@types/[email protected]" is incompatible with requested version "@types/node@^12.12.6"
#0 143.9 warning Resolution field "@types/[email protected]" is incompatible with requested version "@types/node@^12.12.6"
#0 144.1 warning Resolution field "@types/[email protected]" is incompatible with requested version "@types/node@^12.12.6"
#0 165.5 warning workspace-aggregator-e474f423-c6b8-45fe-b968-04fe120a367a > @calcom/exchangecalendar > @ewsjs/xhr > [email protected]: request has been deprecated, see https://github.com/request/request/issues/3142
#0 165.5 warning workspace-aggregator-e474f423-c6b8-45fe-b968-04fe120a367a > @calcom/salesforce > jsforce > [email protected]: request has been deprecated, see https://github.com/request/request/issues/3142
...
#0 233.0 warning workspace-aggregator-e474f423-c6b8-45fe-b968-04fe120a367a > @calcom/web > web3 > web3-eth > web3-eth-ens > content-hash > multihashes > [email protected]: This module has been superseded by the multiformats module
#0 234.8 warning workspace-aggregator-e474f423-c6b8-45fe-b968-04fe120a367a > @calcom/rainbow > wagmi > @walletconnect/ethereum-provider > eip1193-provider > @json-rpc-tools/provider > @json-rpc-tools/utils > @json-rpc-tools/[email protected]: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info.
#0 236.2 Error: Couldn't find any versions for "@calcom/embed-react" that matches "workspace:*"
#0 236.2     at MessageError.ExtendableBuiltin (/opt/yarn-v1.22.19/lib/cli.js:721:66)
#0 236.2     at new MessageError (/opt/yarn-v1.22.19/lib/cli.js:750:123)
#0 236.2     at Function.<anonymous> (/opt/yarn-v1.22.19/lib/cli.js:50351:13)
#0 236.2     at Generator.next (<anonymous>)
#0 236.2     at step (/opt/yarn-v1.22.19/lib/cli.js:310:30)
#0 236.2     at /opt/yarn-v1.22.19/lib/cli.js:321:13
#0 236.2     at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
#0 236.2 Error: Couldn't find any versions for "@calcom/embed-core" that matches "workspace:*"
#0 236.2     at MessageError.ExtendableBuiltin (/opt/yarn-v1.22.19/lib/cli.js:721:66)
#0 236.2     at new MessageError (/opt/yarn-v1.22.19/lib/cli.js:750:123)
#0 236.2     at Function.<anonymous> (/opt/yarn-v1.22.19/lib/cli.js:50351:13)
#0 236.2     at Generator.next (<anonymous>)
#0 236.2     at step (/opt/yarn-v1.22.19/lib/cli.js:310:30)
#0 236.2     at /opt/yarn-v1.22.19/lib/cli.js:321:13
#0 236.2     at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
#0 236.2 Error: Couldn't find any versions for "@calcom/embed-core" that matches "workspace:*"
#0 236.2     at MessageError.ExtendableBuiltin (/opt/yarn-v1.22.19/lib/cli.js:721:66)
#0 236.2     at new MessageError (/opt/yarn-v1.22.19/lib/cli.js:750:123)
#0 236.2     at Function.<anonymous> (/opt/yarn-v1.22.19/lib/cli.js:50351:13)
#0 236.2     at Generator.next (<anonymous>)
#0 236.2     at step (/opt/yarn-v1.22.19/lib/cli.js:310:30)
#0 236.2     at /opt/yarn-v1.22.19/lib/cli.js:321:13
#0 236.2     at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
#0 236.2 Error: Couldn't find any versions for "@calcom/embed-snippet" that matches "workspace:*"
#0 236.2     at MessageError.ExtendableBuiltin (/opt/yarn-v1.22.19/lib/cli.js:721:66)
#0 236.2     at new MessageError (/opt/yarn-v1.22.19/lib/cli.js:750:123)
#0 236.2     at Function.<anonymous> (/opt/yarn-v1.22.19/lib/cli.js:50351:13)
#0 236.2     at Generator.next (<anonymous>)
#0 236.2     at step (/opt/yarn-v1.22.19/lib/cli.js:310:30)
#0 236.2     at /opt/yarn-v1.22.19/lib/cli.js:321:13
#0 236.2     at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
#0 236.2 Error: Couldn't find any versions for "@calcom/embed-snippet" that matches "workspace:*"
#0 236.2     at MessageError.ExtendableBuiltin (/opt/yarn-v1.22.19/lib/cli.js:721:66)
#0 236.2     at new MessageError (/opt/yarn-v1.22.19/lib/cli.js:750:123)
#0 236.2     at Function.<anonymous> (/opt/yarn-v1.22.19/lib/cli.js:50351:13)
#0 236.2     at Generator.next (<anonymous>)
#0 236.2     at step (/opt/yarn-v1.22.19/lib/cli.js:310:30)
#0 236.2     at /opt/yarn-v1.22.19/lib/cli.js:321:13
#0 236.2     at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
------
failed to solve: executor failed running [/bin/sh -c yarn global add turbo &&     yarn config set network-timeout 1000000000 -g &&     turbo prune --scope=@calcom/web --docker &&     yarn install]: exit code: 1

djiworks avatar Mar 20 '23 07:03 djiworks

Same.

AlexisSerneels avatar May 09 '23 18:05 AlexisSerneels

Are you still having issues?

krumware avatar Jun 14 '23 08:06 krumware

yes, i still have the issues

Bouchiba43 avatar Dec 07 '23 08:12 Bouchiba43

Have you updated to the latest submodule? These dependency issues have since been resolved.

krumware avatar Dec 07 '23 16:12 krumware