- Newest
- Most votes
- Most comments
Hello.
Networking and Firewalls: Ensure that the network policies/firewalls in your ECS setup allow for communication between the NGINX service and the authentication service on the necessary ports (8999 and 8083, based on your config).
Service Discovery: Make sure that authentication.ecs-demo.test is being resolved correctly by NGINX. Sometimes, DNS resolution can be an issue within container orchestration systems. You might want to try and replace it with the internal IP address of the service temporarily to rule out DNS issues.
Logs and Errors: If you're tailing /dev/stdout and /dev/stderr and not seeing logs, it might be possible that NGINX is failing before it writes anything meaningful. Ensure that NGINX is actually able to start successfully and listen on the desired port.
Proxy Parameters: Often, when working with proxying requests, it's necessary to forward original headers and handle redirects and errors smoothly. Consider incorporating the following into your location blocks:
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
Health Checks: Verify if AWS's ECS health checks are configured appropriately for your services and if the services are being marked as healthy.
Ensure that your task definition has the correct port mappings. Confirm that your ECS service has the correct task definition and desired task count. Verify if the security group attached to your ECS service allows for inbound traffic on ports 8999 and 8083.
Regards, Andrii
Relevant content
- asked a year ago
- Accepted Answerasked 2 years ago
- AWS OFFICIALUpdated 2 months ago
- AWS OFFICIALUpdated a year ago
- AWS OFFICIALUpdated 2 years ago
- AWS OFFICIALUpdated 2 years ago