Gregory Hunt
07/13/2023, 7:55 PMNate
07/17/2023, 3:51 PMGregory Hunt
07/17/2023, 3:52 PMNate
07/17/2023, 3:55 PMprefect.deployments.steps.run_shell_script
which adds some logic in a shell script?Gregory Hunt
07/17/2023, 3:55 PMNate
07/17/2023, 4:00 PMif docker inspect "$IMAGE:$TAG" >/dev/null 2>&1; then
echo "Image exists"
else
echo "Image does not exist. Building the image."
docker build -t "$IMAGE:$TAG" .
fi
exit 0
and add this to your defintions
in prefect.yaml and give it to each deployment as the build
step?Gregory Hunt
07/17/2023, 4:01 PMNate
07/17/2023, 4:02 PMbuild
section, it will run when you do prefect deploy
Gregory Hunt
07/17/2023, 4:03 PMNate
07/17/2023, 4:05 PM