{"action":"opened","issue":{"url":"https://api.github.com/repos/UnitedIncome/serverless-python-requirements/issues/258","repository_url":"https://api.github.com/repos/UnitedIncome/serverless-python-requirements","labels_url":"https://api.github.com/repos/UnitedIncome/serverless-python-requirements/issues/258/labels{/name}","comments_url":"https://api.github.com/repos/UnitedIncome/serverless-python-requirements/issues/258/comments","events_url":"https://api.github.com/repos/UnitedIncome/serverless-python-requirements/issues/258/events","html_url":"https://github.com/UnitedIncome/serverless-python-requirements/issues/258","id":366242643,"node_id":"MDU6SXNzdWUzNjYyNDI2NDM=","number":258,"title":"Own built package is not found while building docker Image for serverless","user":{"login":"canicola","id":8946183,"node_id":"MDQ6VXNlcjg5NDYxODM=","avatar_url":"https://avatars2.githubusercontent.com/u/8946183?v=4","gravatar_id":"","url":"https://api.github.com/users/canicola","html_url":"https://github.com/canicola","followers_url":"https://api.github.com/users/canicola/followers","following_url":"https://api.github.com/users/canicola/following{/other_user}","gists_url":"https://api.github.com/users/canicola/gists{/gist_id}","starred_url":"https://api.github.com/users/canicola/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/canicola/subscriptions","organizations_url":"https://api.github.com/users/canicola/orgs","repos_url":"https://api.github.com/users/canicola/repos","events_url":"https://api.github.com/users/canicola/events{/privacy}","received_events_url":"https://api.github.com/users/canicola/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2018-10-03T09:12:06Z","updated_at":"2018-10-03T09:12:06Z","closed_at":null,"author_association":"NONE","body":"I want to deploy a some functions using serverless via aws. My current working directory looks like this:\r\n\r\n```\r\ntree -L 2 lambda/\r\nlambda/\r\n└── tagdoc\r\n    ├── pkgg-0.1.0.tar.gz\r\n    ├── handler.py\r\n    ├── nltk_data\r\n    ├── node_modules\r\n    ├── package.json\r\n    ├── package-lock.json\r\n    ├── README.md\r\n    ├── requirements.txt\r\n    ├── serverless.yml\r\n    └── srv\r\n\r\n4 directories, 8 files\r\n```\r\n\r\nThe requirement.txt just includes one single line: `pkgg-0.1.0.tar.gz`. However, when I try to deploy I get the following error. It always fails during the building of the Docker image for lambci:\r\n\r\n```\r\nSLS_DEBUG=* serverless deploy --stage dev --aws-profile default\r\nServerless: Load command config\r\nServerless: Load command config:credentials\r\nServerless: Load command create\r\nServerless: Load command install\r\nServerless: Load command package\r\nServerless: Load command deploy\r\nServerless: Load command deploy:function\r\nServerless: Load command deploy:list\r\nServerless: Load command deploy:list:functions\r\nServerless: Load command invoke\r\nServerless: Load command invoke:local\r\nServerless: Load command info\r\nServerless: Load command logs\r\nServerless: Load command login\r\nServerless: Load command logout\r\nServerless: Load command metrics\r\nServerless: Load command print\r\nServerless: Load command remove\r\nServerless: Load command rollback\r\nServerless: Load command rollback:function\r\nServerless: Load command slstats\r\nServerless: Load command plugin\r\nServerless: Load command plugin\r\nServerless: Load command plugin:install\r\nServerless: Load command plugin\r\nServerless: Load command plugin:uninstall\r\nServerless: Load command plugin\r\nServerless: Load command plugin:list\r\nServerless: Load command plugin\r\nServerless: Load command plugin:search\r\nServerless: Load command config\r\nServerless: Load command config:credentials\r\nServerless: Load command rollback\r\nServerless: Load command rollback:function\r\nServerless: Load command requirements\r\nServerless: Load command requirements:clean\r\nServerless: Load command requirements:install\r\nServerless: Load command requirements:cleanCache\r\nServerless: Invoke deploy\r\nServerless: Invoke package\r\nServerless: Invoke aws:common:validate\r\nServerless: Invoke aws:common:cleanupTempDir\r\nServerless: Generated requirements from /home/ola/projects/lambda/tagdoc/requirements.txt in /home/ola/projects/lambda/tagdoc/.serverless/requirements.txt...\r\nServerless: Installing requirements from /home/ola/projects/lambda/tagdoc/.serverless/requirements/requirements.txt ...\r\nServerless: Docker Image: lambci/lambda:build-python3.6\r\nRequirement 'pkgg-0.1.0.tar.gz' looks like a filename, but the file does not exist\r\nProcessing ./pkgg-0.1.0.tar.gz\r\nCould not install packages due to an EnvironmentError: [Errno 2] No such file or directory: '/var/task/pkgg-0.1.0.tar.gz'\r\n\r\n\r\n  Error --------------------------------------------------\r\n\r\n  null\r\n\r\n     For debugging logs, run again after setting the \"SLS_DEBUG=*\" environment variable.\r\n\r\n  Stack Trace --------------------------------------------\r\n\r\nError: null\r\n    at installRequirements (/home/ola/projects/lambda/tagdoc/node_modules/serverless-python-requirements/lib/pip.js:262:11)\r\n    at installRequirementsIfNeeded (/home/ola/projects/lambda/tagdoc/node_modules/serverless-python-requirements/lib/pip.js:448:3)\r\n    at ServerlessPythonRequirements.installAllRequirements (/home/ola/projects/lambda/tagdoc/node_modules/serverless-python-requirements/lib/pip.js:527:29)\r\nFrom previous event:\r\n    at PluginManager.invoke (/usr/lib/node_modules/serverless/lib/classes/PluginManager.js:390:22)\r\n    at PluginManager.spawn (/usr/lib/node_modules/serverless/lib/classes/PluginManager.js:408:17)\r\n    at Deploy.BbPromise.bind.then.then (/usr/lib/node_modules/serverless/lib/plugins/deploy/deploy.js:123:50)\r\nFrom previous event:\r\n    at Object.before:deploy:deploy [as hook] (/usr/lib/node_modules/serverless/lib/plugins/deploy/deploy.js:113:10)\r\n    at BbPromise.reduce (/usr/lib/node_modules/serverless/lib/classes/PluginManager.js:390:55)\r\nFrom previous event:\r\n    at PluginManager.invoke (/usr/lib/node_modules/serverless/lib/classes/PluginManager.js:390:22)\r\n    at PluginManager.run (/usr/lib/node_modules/serverless/lib/classes/PluginManager.js:421:17)\r\n    at variables.populateService.then.then (/usr/lib/node_modules/serverless/lib/Serverless.js:157:33)\r\n    at runCallback (timers.js:810:20)\r\n    at tryOnImmediate (timers.js:768:5)\r\n    at processImmediate [as _immediateCallback] (timers.js:745:5)\r\nFrom previous event:\r\n    at Serverless.run (/usr/lib/node_modules/serverless/lib/Serverless.js:144:8)\r\n    at serverless.init.then (/usr/lib/node_modules/serverless/bin/serverless:43:50)\r\n    at <anonymous>\r\n\r\n  Get Support --------------------------------------------\r\n     Docs:          docs.serverless.com\r\n     Bugs:          github.com/serverless/serverless/issues\r\n     Issues:        forum.serverless.com\r\n```\r\n\r\nI use the following serverless.yml file (running everything on Debian 9.5):\r\n\r\n```\r\n# Welcome to Serverless!\r\n#\r\n# This file is the main config file for your service.\r\n# It's very minimal at this point and uses default values.\r\n# You can always add more config options for more control.\r\n# We've included some commented out config examples here.\r\n# Just uncomment any of them to get that config option.\r\n#\r\n# For full config options, check the docs:\r\n#    docs.serverless.com\r\n#\r\n# Happy Coding!\r\n\r\nservice: tagdoc # NOTE: update this with your service name\r\n\r\n# You can pin your service to only deploy with a specific Serverless version\r\n# Check out our docs for more details\r\n# frameworkVersion: \"=X.X.X\"\r\n\r\nprovider:\r\n  name: aws\r\n  runtime: python3.6\r\n  region: eu-central-1\r\n# you can overwrite defaults here\r\n#  stage: dev\r\n\r\nplugins:\r\n  - serverless-python-requirements\r\n\r\n# You need to have Docker installed to be able to set dockerizePip:\r\n# true or dockerizePip: non-linux. Alternatively, you can set\r\n# dockerizePip: false, and it will not use Docker packaging. But,\r\n# Docker packaging is essential if you need to build native packages\r\n# that are part of your dependencies like Psycopg2, NumPy, Pandas, etc\r\ncustom:\r\n  pythonRequirements:\r\n    dockerizePip: true\r\n\r\n# you can define service wide environment variables here\r\n#  environment:\r\n#    variable1: value1\r\n\r\n# you can add packaging information here\r\npackage:\r\n  include:\r\n    - ./nltk_data/*\r\n\r\nfunctions:\r\n  ttxt:\r\n    handler: handler.ttxt\r\n    events:\r\n      - http:\r\n          path: /ttxt\r\n          method: get\r\n          integration: lambda\r\n          request:\r\n            template:\r\n              application/json: '{ \"txt\" : \"$input.params(''txt'')\" }'\r\n          response:\r\n            headers:\r\n  turl:\r\n    handler: handler.turl\r\n    events:\r\n      - http:\r\n          path: /turl\r\n          method: get\r\n          integration: lambda\r\n          request:\r\n            template:\r\n              application/json: '{ \"url\" : \"$input.params(''url'')\" }'\r\n          response:\r\n            headers:\r\n              Content-Type: \"'application/json'\"\r\n```\r\n\r\nThe weird thing is I share the repo with a friend and he is able to deploy. I did a clean clone of the repo but it still fails. What is causing the issue?"}}
{"actor":{"display_login":"canicola"}}