Area: Deployment Issues
Sub-Area: Remote Executor / Terraform Module Configuration
Applies to: Cloud
Issue
You deploy the DataHub Cloud Remote Executor on Amazon ECS with Terraform. After you move to executor image v1.1.0-cloud or later, the container fails to start. The ECS task stops right away, and the error says the dockerize executable is not found in $PATH.
You Might Be Asking
- Why does my Remote Executor container fail to start after I upgraded to a newer executor image?
- Why does my Terraform deployment still call
dockerize? - Should I point the Terraform module at
main, or at a release tag? - How do I pin the executor image version with the Terraform module?
- Does the module's version number have to match my DataHub Cloud version?
Cause
Executor images up to v1.0.x-cloud contained the dockerize tool and used it to wait for GMS before starting. Starting with v1.1.0-cloud, the images are built on Wolfi instead of Ubuntu and no longer contain dockerize. The startup script /start_datahub_executor.sh now waits for the GMS /health endpoint itself, using curl. The image's default command is exec /start_datahub_executor.sh.
If your ECS container definition still sets the container command to dockerize ..., ECS tries to run a program that isn't in the image, and the container fails to start. This happens with any container definition that keeps the old command. Terraform module tags v2.0.0 and v2.0.1 set the command to dockerize /start_datahub_executor.sh. A command you set yourself, or one in a copy of the module that you maintain, can do the same. Images older than v1.1.0-cloud still contain dockerize. Module tags v2.0.0 and v2.0.1 also use such an image by default. This is why the problem shows up only after you upgrade the image.
Solution
- Check the command your running task definition uses:
aws ecs describe-task-definition --task-definition <task-family> \
--query 'taskDefinition.containerDefinitions[].command'
If the output contains dockerize, continue with the next steps.
- Pin the Terraform module to tag
v2.1.0or later with?ref=. Tagv2.1.0is the first module release that runs/start_datahub_executor.shwithoutdockerize. Don't track themainbranch: everyterraform initagainst a branch can pull in module changes you haven't reviewed. The docs show the source in this form:
module "remote_executor" {
source = "git::https://github.com/acryldata/datahub-terraform-modules.git//remote-ingestion-executor?ref=v2.1.0"
datahub = {
url = "https://<your-company>.acryl.io/gms"
executor_pool_id = "<your-pool-id>"
}
# ... other inputs from the setup guide
}
See the Terraform tab of Deploy on Amazon ECS for the full example and the list of inputs.
- The module has no input to override the container command. If your own Terraform code, or a copy of the module that you maintain, sets the container command, remove that command so the image's default command runs. If you must set a command, use the absolute path:
command = ["/start_datahub_executor.sh"]
Don't use ./start_datahub_executor.sh. The image's working directory is /datahub-executor, so the relative path points to a file that doesn't exist.
- Set the executor image version, if you want a specific one. The input is
image_taginside thedatahubobject. There is no top-level image tag variable.
datahub = {
url = "https://<your-company>.acryl.io/gms"
executor_pool_id = "<your-pool-id>"
image_tag = "v2.4.4-cloud" # pick a version from your release notes
}
If you leave datahub.image_tag unset, the module tag in ?ref= decides the image version. It doesn't follow the latest image. Module tags (such as v2.1.0) and image tags (such as v2.4.4-cloud) have separate version numbers. Pick an image from the Recommended Versions list in the release notes for your DataHub Cloud version, for example the v2.4.0 release notes.
- Re-initialize and apply:
terraform init
terraform plan
terraform apply
Before you confirm the apply, check that the planned container definition no longer contains dockerize. ECS then replaces the running task with a rolling update.
- Confirm the new task starts. The executor log shows
Waiting for GMS at <url> (timeout 240s)...and thenGMS is ready.. If it logsTimeout waiting for GMS at <url>instead, the container can't reach your DataHub Cloud URL. Check thatdatahub.urlends in/gmsand that the task's subnets have outbound HTTPS access.
Additional Notes
The same dockerize removal affects other deployment methods that override the container command, and custom images that call dockerize or install packages with apt-get. See Remote Executor Image Base OS Change: Migrating from Ubuntu to Wolfi and, for Kubernetes, Remote Executor Helm Upgrade Times Out Because the Executor Pod Never Becomes Ready.