https://pantsbuild.org/ logo
#general
Title
# general
b

brash-student-40401

01/10/2023, 3:24 PM
This is hopefully a quick/silly error on my part, but I can't seem to get past it - my
./pants publish src/services/app/lambdas/svc1/Dockerfile
is failing with
Copy code
stderr:
COPY failed: file not found in build context or excluded by .dockerignore: stat src/services/app/lambdas/svc1/requirements.txt: file does not exist
Anything referenced in that directory, which does in fact exist, is failing. What's the proper format for referencing stuff in the Dockerfile?
h

happy-kitchen-89482

01/10/2023, 3:31 PM
Is there a
files()
or
resources()
target that owns that requirements.txt?
Does it show up when you
./pants dependencies src/services/app/lambdas/svc1/Dockerfile
?
b

brash-student-40401

01/10/2023, 3:31 PM
No - create it, and then have the Docker target depend on it?
That seems like it worked, thanks! (It did work!)
h

happy-kitchen-89482

01/10/2023, 4:24 PM
Great. Currently there has to be a target for dependencies (inferred or explicit) to point to