Hi all, I’m running a flow on ECS and have encount...
# ask-community
c
Hi all, I’m running a flow on ECS and have encountered a strange issue. After setting my deployment configurations (mainly network configurations) in
prefect.yaml
, the job variables appear in my deployment configuration but are not passed through to my ECS Task. A task definition is created with the name of my work pool and a UUID (e.g.,
prefect_ecs-dev-pool_79227824-ac2e-48de-8639-58bc6fae1f6c
), but it does not include the configured variables. As a result, network settings and IAM roles are missing (managed to bypass this by allowing my worker to pass roles to my task… for now.). I’ve already discussed this with @Bianca Hoch but am still unsure why this is happening. Hoping the community can help us troubleshoot! Thanks in advance. Secondary ask; I’m using webhooks in Prefect Cloud and would like to validate incoming webhooks. To do this, I need access to the raw, unprocessed request body to generate a signature and match it against the signature in the headers. However, it seems that Prefect modifies the raw body in some way, making it impossible to validate my signature. While I appreciate the ability to extract webhook parameters directly into my flow, it would be helpful to have an option to pass the full request payload so I can handle it myself - without manipulation by prefect. I’ve tried several approaches to pass the raw body to my function, but I either get validation errors in my automation or signatures that don’t match. Has anyone else encountered this, or found a workaround? Would love any insights. Thanks!
j
hey for #1 if I'm understanding correctly it looks like you've hardcoded a number of things into your work pool's job configuration. For example, by default network configuration looks like this:
Copy code
"network_configuration": "{{ network_configuration }}"
This will use
job_variables
from the deployment if it's set, otherwise fall back to the default set on the work pool properties
hardcoding it into the job configuration is totally valid! But implies you don't want users of the work pool to be able to dynamically pass this setting
sorry I misread the 2nd image, could you share what your work pool's job configuration looks like?
Oh I think you may need to pass the vpc id in your deployment variables as well?