Skip to content
This repository has been archived by the owner on Apr 13, 2023. It is now read-only.

Initial deployment failing on Serverless: Copying Dependencies ... #195

Closed
silverslingshot1 opened this issue Jan 26, 2021 · 2 comments · Fixed by #220
Closed

Initial deployment failing on Serverless: Copying Dependencies ... #195

silverslingshot1 opened this issue Jan 26, 2021 · 2 comments · Fixed by #220
Labels
chore General improvements to the system but are not new features documentation Improvements or additions to documentation

Comments

@silverslingshot1
Copy link

silverslingshot1 commented Jan 26, 2021

I'm trying to deploy for the first time into my account, but it keeps failing on this step "Serverless: Copying Dependencies" with this error "EISDIR: illegal operation on a directory, symlink". I'm deploying from the mainline branch with no edits.

Installing dependencies...

The following dependencies will need to be installed:

None! All dependencies already satisfied
We just need to double-check that the boto3 python module is installed...
Requirement already satisfied: boto3 in c:\python39\lib\site-packages (1.16.59)
Requirement already satisfied: s3transfer<0.4.0,>=0.3.0 in c:\python39\lib\site-packages (from boto3) (0.3.4)
Requirement already satisfied: botocore<1.20.0,>=1.19.59 in c:\python39\lib\site-packages (from boto3) (1.19.59)
Requirement already satisfied: jmespath<1.0.0,>=0.7.1 in c:\python39\lib\site-packages (from boto3) (0.10.0)
Requirement already satisfied: urllib3<1.27,>=1.25.4; python_version != "3.4" in c:\python39\lib\site-packages (from botocore<1.20.0,>=1.19.59->boto3) (1.26.2)
Requirement already satisfied: python-dateutil<3.0.0,>=2.1 in c:\python39\lib\site-packages (from botocore<1.20.0,>=1.19.59->boto3) (2.8.1)
Requirement already satisfied: six>=1.5 in c:\python39\lib\site-packages (from python-dateutil<3.0.0,>=2.1->botocore<1.20.0,>=1.19.59->boto3) (1.15.0)
WARNING: You are using pip version 20.2.3; however, version 21.0 is available.
You should consider upgrading via the 'C:\Python39\python.exe -m pip install --upgrade pip' command.
yarn install v1.22.5
warning package-lock.json found. Your project contains lock files generated by tools other than Yarn. It is advised not to mix package managers in order to avoid resolution inconsistencies caused by unsynchronized lock files. To clear this warning, remove package-lock.json.
[1/5] Validating package.json...
[2/5] Resolving packages...
warning Resolution field "urijs@1.19.4" is incompatible with requested version "urijs@1.19.2"
[3/5] Fetching packages...
info fsevents@2.3.1: The platform "win32" is incompatible with this module.
info "fsevents@2.3.1" is an optional dependency and failed compatibility check. Excluding it from installation.
[4/5] Linking dependencies...
warning " > jest-mock-extended@1.0.8" has incorrect peer dependency "jest@^24.0.0".
warning "serverless > @serverless/components > inquirer-autocomplete-prompt@1.3.0" has unmet peer dependency "inquirer@^5.0.0 || ^6.0.0 || ^7.0.0".
[5/5] Building fresh packages...
[1/4] ⢀ snappy                                                                                                                                                                                                                      [-/4] ⢀ waiting...                                                                                                                                                                                                                  [-/4] ⠠ waiting...                                                                                                                                                                                                                  warning Error running install script for optional dependency: "D:\\AWS\\fhir-works-on-aws-deployment-mainline\\node_modules\\snappy: Command failed.
Exit code: 1
Command: prebuild-install || node-gyp rebuild
Arguments:
Directory: D:\\AWS\\fhir-works-on-aws-deployment-mainline\\node_modules\\snappy
Output:
prebuild-install WARN install No prebuilt binaries found (target=15.6.0 runtime=node arch=x64 libc= platform=win32)

D:\\AWS\\fhir-works-on-aws-deployment-mainline\\node_modules\\snappy>if not defined npm_config_node_gyp (node \"C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\node-gyp-bin\\\\..\\..\\node_modules\\node-gyp\\bin\\node-gyp.js\" rebuild )  else (node \"\" rebuild )
gyp info it worked if it ends with ok
gyp info using node-gyp@7.1.2
gyp info using node@15.6.0 | win32 | x64
gyp info find Python using Python version 3.9.1 found at \"C:\\Python39\\python.exe\"
gyp ERR! find VS
gyp ERR! find VS msvs_version not set from command line or npm config
gyp ERR! find VS VCINSTALLDIR not set, not running in VS Command Prompt
gyp ERR! find VS checking VS2019 (16.8.30711.63) found at:
gyp ERR! find VS \"C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\Community\"
gyp ERR! find VS - \"Visual Studio C++ core features\" missing
gyp ERR! find VS checking VS2017 (15.9.28307.718) found at:
gyp ERR! find VS \"C:\\Program Files (x86)\\Microsoft Visual Studio\\2017\\Community\"
gyp ERR! find VS - \"Visual Studio C++ core features\" missing
gyp ERR! find VS could not find a version of Visual Studio 2017 or newer to use
gyp ERR! find VS looking for Visual Studio 2015
gyp ERR! find VS - not found
gyp ERR! find VS not looking for VS2013 as it is only supported up to Node.js 8
gyp ERR! find VS
gyp ERR! find VS **************************************************************
gyp ERR! find VS You need to install the latest version of Visual Studio
gyp ERR! find VS including the \"Desktop development with C++\" workload.
gyp ERR! find VS For more information consult the documentation at:
gyp ERR! find VS https://github.com/nodejs/node-gyp#on-windows
gyp ERR! find VS **************************************************************
gyp ERR! find VS
gyp ERR! configure error
gyp ERR! stack Error: Could not find any Visual Studio installation to use
gyp ERR! stack     at VisualStudioFinder.fail (C:\\Program Files\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\lib\\find-visualstudio.js:121:47)
gyp ERR! stack     at C:\\Program Files\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\lib\\find-visualstudio.js:74:16
gyp ERR! stack     at VisualStudioFinder.findVisualStudio2013 (C:\\Program Files\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\lib\\find-visualstudio.js:351:14)
gyp ERR! stack     at C:\\Program Files\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\lib\\find-visualstudio.js:70:14
gyp ERR! stack     at C:\\Program Files\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\lib\\find-visualstudio.js:372:16
gyp ERR! stack     at C:\\Program Files\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\lib\\util.js:54:7
gyp ERR! stack     at C:\\Program Files\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\lib\\util.js:33:16
gyp ERR! stack     at ChildProcess.exithandler (node:child_process:340:5)
gyp ERR! stack     at ChildProcess.emit (node:events:379:20)
gyp ERR! stack     at maybeClose (node:internal/child_process:1065:16)
gyp ERR! System Windows_NT 10.0.18363
gyp ERR! command \"C:\\\\Program Files\\\\nodejs\\\\node.exe\" \"C:\\\\Program Files\\\\nodejs\\\\node_modules\\\\npm\\\\node_modules\\\\node-gyp\\\\bin\\\\node-gyp.js\" \"rebuild\"
gyp ERR! cwd D:\\AWS\\fhir-works-on-aws-deployment-mainline\\node_modules\\snappy
gyp ERR! node -v v15.6.0
success Saved lockfile.
Done in 317.02s.
yarn run v1.22.5
$ tsc
Done in 58.88s.
yarn run v1.22.5
$ jest --silent --passWithNoTests --testPathPattern=src/*
No tests found, exiting with code 0
Done in 21.11s.


Deploying FHIR Server
(This may take some time, usually ~20-30 minutes)


Serverless: Running "serverless" installed locally (in service node_modules)
Serverless: Deprecation warning: Starting with next major version, default value of provider.lambdaHashingVersion will be equal to "20201221"
            More Info: https://www.serverless.com/framework/docs/deprecations/#LAMBDA_HASHING_VERSION_V2
Serverless: Deprecation warning: Starting with next major version, API Gateway naming will be changed from "{stage}-{service}" to "{service}-{stage}".
            Set "provider.apiGateway.shouldStartNameWithService" to "true" to adapt to the new behavior now.
            More Info: https://www.serverless.com/framework/docs/deprecations/#AWS_API_GATEWAY_NAME_STARTING_WITH_SERVICE
Serverless: Deprecation warning: Starting with next major version, API Gateway-specific configuration keys "apiKeys", "resourcePolicy" and "usagePlan" will be relocated from "provider" to "provider.apiGateway"
            More Info: https://www.serverless.com/framework/docs/deprecations/#AWS_API_GATEWAY_SPECIFIC_KEYS
Serverless: Compiling with Typescript...
Serverless: Using local tsconfig.json at "D:\AWS\fhir-works-on-aws-deployment-mainline\tsconfig.json"
Serverless: TypeScript compiled.
Serverless: Copying Extras...
Serverless: Finished Copying Extras
Serverless: Copying Dependencies ...

  Error --------------------------------------------------

  Error: EISDIR: illegal operation on a directory, symlink 'D:\AWS\fhir-works-on-aws-deployment-mainline\package.json' -> 'D:\AWS\fhir-works-on-aws-deployment-mainline\.build\package.json'

     For debugging logs, run again after setting the "SLS_DEBUG=*" environment variable.

  Get Support --------------------------------------------
     Docs:          docs.serverless.com
     Bugs:          github.com/serverless/serverless/issues
     Issues:        forum.serverless.com

  Your Environment Information ---------------------------
     Operating System:          win32
     Node Version:              14.4.0
     Framework Version:         2.20.1 (standalone)
     Plugin Version:            4.4.2
     SDK Version:               2.3.2
     Components Version:        3.5.1
@silverslingshot1
Copy link
Author

I just wanted to let others know that this issue was caused by the fact that I was trying to deploy it from partition D on Windows for some reason. I moved the package on C in a new folder called temp and it worked all the way to trying to deploy the lambda function where it failed because of the package being too large. There is another issue raised with that one and I've put my comment there.
Hopefully if others have this issue it might help them

@rsmayda
Copy link
Contributor

rsmayda commented Jan 27, 2021

Thanks for letting us know! We will plan to add this to our 'Troubleshooting' section

@rsmayda rsmayda added chore General improvements to the system but are not new features documentation Improvements or additions to documentation labels Feb 8, 2021
@rsmayda rsmayda linked a pull request Feb 22, 2021 that will close this issue
@rsmayda rsmayda closed this as completed Mar 18, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
chore General improvements to the system but are not new features documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants