I have Dagster setup on AWS ECS. It works, but now...
# ask-community
p
I have Dagster setup on AWS ECS. It works, but now I want to add a kind of E2E test, where I start given job and later check if that job made modifications to S3, database etc. I am unable to find a way to launch Dagster Job on AWS ECS without using Dagit (for example: trigger it in code using some command). Is there any way to trigger a Dagster Job on AWS ECS from code? E.g. start it using CLI? If that is impossible, then I have idea for a workaround. To give you more details: I deploy the AWS ECS Dagster infrastructure using AWS CDK - I have a separate stack just for those E2E. I want to trigger the Dagster job to run as soon as that AWS CDK stack with infrastructure is deployed. Maybe it is possible to set Scheduler to run the Job as soon as possible - however, how can I force it so that this job is run only once? Thanks in advance! 😉
🤖 1
s
Hi Piotr, I’m not very knowledgable on AWS, but is the host/port of the gRPC server hosting your code location exposed? Then you can use:
Copy code
$ dagster job launch --grpc-host=<host> --grpc-port=<port> --job=<job-name> ...
See
dagster job launch --help
for details.
p
Hello @sean, thanks for the response! gRPC is not exposed (it is in private VPC), but maybe I could make it work somehow. Thanks for the suggestion!
s
FWIW there is also the GQL API and GQL Python client, which will go through the dagit process (rather than direct to code server via grpc): https://docs.dagster.io/concepts/dagit/graphql