localstack / localstack/localstack-mcp-server
Deployer health check blocks deploys to remote/ephemeral instances (requires a local gateway)
Nadie ha tomado este issue todavía.
- Lenguaje dominante
- TypeScript
- Estrellas
- 27
- Forks
- 13
- Métricas de merge de PR
- Sin PR fusionados en 30 d
Descripción
Summary
The localstack-deployer tool runs a pre-deploy reachability check against a local gateway (http://${LOCALSTACK_HOSTNAME:-localhost}:${LOCALSTACK_PORT:-4566}/_localstack/health). When you want the deploy to target a remote Ephemeral Instance (which is HTTPS-only, e.g. https://ls-<id>.sandbox.localstack.cloud), that check can never pass on its own, so the deploy is blocked with:
LocalStack Not Running — LocalStack is not reachable at http://localhost:4566 ...
even though the actual deploy would succeed against the ephemeral instance. The result is that you must keep a throwaway local LocalStack running purely to satisfy the health gate, while the real deploy is redirected elsewhere.
Why this matters
A natural workflow is to give each agent (or each CI job / worktree) its own Ephemeral Instance in the cloud and deploy straight to it via the MCP server. The deployer can already do this: tflocal/cdklocal pick up the endpoint from the environment, and setting per-service {SERVICE}_ENDPOINT=https://ls-<id>.sandbox.localstack.cloud in the MCP server's env makes terraform apply land resources on the ephemeral instance correctly. The only thing standing in the way is the pre-deploy health probe.
Details
- The env builder forwards the process env to
tflocal, so per-service*_ENDPOINThttps values reach the provider and resources deploy to the ephemeral instance as expected. - The health gate, however, is hardcoded to an
http://host:portprobe. Ephemeral instances only answer onhttps://<host>(443);http://<host>:443andhttp://<host>:80do not respond, so the gate fails. - Confirmed: with a local LocalStack running (gate satisfied) + per-service
*_ENDPOINT=https://ls-<id>...set, a Terraform deploy vialocalstack-deployerlands entirely on the ephemeral instance. With the local instance stopped, the same deploy is refused by the gate beforetflocalever runs.
Steps to reproduce
- Create an ephemeral instance:
localstack ephemeral create --name demo-> note thehttps://ls-<id>.sandbox.localstack.cloudendpoint. - Configure the MCP server
envwithAWS_ENDPOINT_URLand per-service{SERVICE}_ENDPOINTall set to that https endpoint (and the auth token). - Stop any local LocalStack.
- Call
localstack-deployer(deploy, terraform) on a small project. - It fails with "LocalStack is not reachable at http://localhost:4566" instead of deploying to the ephemeral instance.
Suggested fix
When a remote endpoint is configured (e.g. AWS_ENDPOINT_URL / *_ENDPOINT points at a non-local host, or an explicit ephemeral endpoint is provided), the pre-deploy reachability check should probe that endpoint (honouring https), or be skipped, rather than always probing http://localhost:4566. Ideally the tool would accept an explicit target/endpoint so a deploy can be aimed at an ephemeral instance without needing a local gateway at all.
Environment
@localstack/localstack-mcp-server(latest vianpx)terraform-local(tflocal) 0.26.0, Terraform 1.14.9- Ephemeral Instances (public preview), image
localstack/localstack-pro:latest
Guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Línea de trabajo
Comienza localizando el pre-deploy health check y el env builder de localstack-deployer descritos en el issue. Reproduce el fallo con un endpoint HTTPS efímero remoto y sin gateway local; después, verifica que se comprueba el endpoint remoto configurado o que se omite el check, y que el deploy continúa a través de tflocal.
Escrito por el modelo de indexación a partir del texto del issue.
Evaluación
- Stack tecnológico
- terraform, typescript
- Área
- cloud, devops, infrastructure
- Tipo de issue
- Error
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Estado de actividad
- Activo
- Claridad
- Bastante claro
- Aptitud para principiantes
- 55/100