Skip to content

Package Artifact Not Working as Described #4692

Closed

Description

@kinmanlam

Hello,

I'm attempting to deploy a Python script as a service. This Python script requires libraries which I have built and packaged using an Amazon Linux EC2. I have verified the zip file works if I manually deploy it.

In my serverless.yml:

service:
    name: python-lambda
package:
    artifact: deployment-pkg.zip

EXPECTATION:
Based on the documentation, this should override the default packaging behavior and instead simply use the deployment-pkg.zip as is, and deploy the deployment-pkg.zip as the end result to my lambda function.

deployment-pkg.zip gets repackaged as python-lambda.zip contents being:

-libdep1\
-libdep2\
-source.py

REALITY:
I inspect the ./serverless folder which contains the deploy package the python-lambda.zip contents are:

-deployment-pkg.zip
-source.py

The overall result is when this package gets deploy, my lambda function complains it cannot find it's dependencies as that deployment package is not correctly structured.

I am running the latest version of serverless 1.26.0

Activity

  1. snurmine commented on Mar 11, 2019

    @snurmine
    Contributor

    Tested with master (06c8222), but serverless package didn't generate zip under .serverless.

    service: env-test
      
    package:
      artifact: foo.zip
    provider:
      name: aws
      runtime: nodejs6.10
    
    

    zoo.zip:

    foo/lib1/
    foo/lib2/
    foo/source.py
    foo/lib1/lib.py
    foo/lib2/lib2.py
    
  2. pgrzesik commented on Aug 31, 2021

    @pgrzesik
    Contributor

    Closing due to inactivity for over 2 years

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions