No file found in the package path you provided


Serverless Version: 1.53.0
CI: AWS Codebuild
Functions: Packaged individually

My Issue:
No file found in the package path you provided.

What I’ve done so far:
I’ve found various articles and github issues around this issue from reading this seems to have been fixed since version >1.39.x. Which is why I am not sure what is going on. In my AWS codebuild, buildspec file I run the package command:

serverless package --package target/$STAGE --stage $STAGE -v -r us-east-1

I store artifacts like so:
- target/**/*
- serverless.yml

In my deploy stage which is using AWS codebuild and running a shell script I run the following command:
serverless deploy --stage $STAGE --package $CODEBUILD_SRC_DIR/target/$STAGE -v -r us-east-1

I am running an “ls” command in the CodeBuild environment to see what is in the --package directory and i see all my zip files. In the root directory I see the serverless.yml and file.

In the serverless-state.json I found the below which is the location in S3 but when I look at S3 i don’t see the files.
“artifactDirectoryName”: “serverless/project/dev/1569970953930-2019-10-01T23:02:33.930Z”, D

Everything looks to be in the correct place. But the deply command doesn’t seem to pick up the zip files.

Any guidance would be a big help!

Thank you

1 Like

Im having the same problem, did you found some solution?

1 Like

I’m also having the same problem and it seems there are outstanding bugs for this - - is at least one.

Is there a solution or does anyone know if there are plans to fix this? Seems its been broken since v1.39.

@serverless @services

Seems like maybe they fixed this for the deploy command - - but still need to do it for package command?