Title: fix(pii): listen on 5001 to avoid app :3000 collision (awsvpc) by TheodoreSpeaks · Pull Request #5182 · simstudioai/sim · GitHub
Open Graph Title: fix(pii): listen on 5001 to avoid app :3000 collision (awsvpc) by TheodoreSpeaks · Pull Request #5182 · simstudioai/sim
X Title: fix(pii): listen on 5001 to avoid app :3000 collision (awsvpc) by TheodoreSpeaks · Pull Request #5182 · simstudioai/sim
Description: Summary The sim/pii image hardcoded uvicorn --port 3000, so it always bound 3000. In the app ECS task (awsvpc), all containers share one network namespace and the app owns 3000 — a sim/pii sidecar on 3000 collides with it and breaks the task. (The stock mcr presidio images ran on 5002/5001, which is why they coexisted with the app.) Fix: the sidecar now listens on 5001 — exec-form CMD on 5001, EXPOSE 5001, healthcheck on 5001. Why hardcode 5001 (not a configurable $PORT) An earlier revision made the port configurable via $PORT, but EXPOSE can't be parameterized in a Dockerfile, so it always showed 5001 regardless of the runtime port (Greptile P2). We own both the image and the taskdef and only ever need one port, so hardcoding 5001 keeps EXPOSE/healthcheck/CMD consistent and avoids the mismatch. (Implication: the taskdef just needs containerPort: 5001; a PORT env on the sidecar is a no-op.) Deploy ordering Must be in ECR before the infra taskdef points the sidecar at sim/pii — otherwise the taskdef would run the old 3000-binding image and collide with the app. Independent of the app-rewire PR (which deploys after the taskdef). Sequence: this → infra taskdef (containerPort 5001, PII_URL=http://localhost:5001) → app-rewire. Testing Built locally and verified the service binds 5001 and /analyze returns spans on that port. The hardcoded build produces an identical runtime process (uvicorn server:app --host 0.0.0.0 --port 5001) to the verified revision; CI rebuilds the image on merge. Type of Change Bug fix Checklist Code follows project style guidelines Self-reviewed my changes Tests added/updated and passing No new warnings introduced I confirm that I have read and agree to the terms outlined in the Contributor License Agreement (CLA)
Open Graph Description: Summary The sim/pii image hardcoded uvicorn --port 3000, so it always bound 3000. In the app ECS task (awsvpc), all containers share one network namespace and the app owns 3000 — a sim/pii sidecar...
X Description: Summary The sim/pii image hardcoded uvicorn --port 3000, so it always bound 3000. In the app ECS task (awsvpc), all containers share one network namespace and the app owns 3000 — a sim/pii sidecar...
Opengraph URL: https://github.com/simstudioai/sim/pull/5182
X: @github
Domain: github.com
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react-reconciler,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@d5750093facf |
| route-pattern | /:user_id/:repository/pull/:id/files(.:format) |
| route-controller | pull_requests |
| route-action | files |
| fetch-nonce | v2:7ab8d7fd-a5ff-4a0a-a568-9e7d675eb99d |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | C752:47529:632922:8CF92A:6AFB45DA |
| html-safe-nonce | cbaf0dca7c6721aba663f1ce7af6294478a08dfbfb20edacea7e1f5c401da6b7 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJDNzUyOjQ3NTI5OjYzMjkyMjo4Q0Y5MkE6NkFGQjQ1REEiLCJ2aXNpdG9yX2lkIjoiNjY0OTcwMzAwMzUyNTQzMjc5NCIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 481e35c845352a2b9548ea23e78d3b8eb91ea6028b4f7ae00a8f9a11a1a0b545 |
| hovercard-subject-tag | pull_request:3918320426 |
| github-keyboard-shortcuts | repository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/simstudioai/sim/pull/5182/files |
| twitter:image | https://avatars.githubusercontent.com/u/19564703?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/19564703?s=400&v=4 |
| og:image:alt | Summary The sim/pii image hardcoded uvicorn --port 3000, so it always bound 3000. In the app ECS task (awsvpc), all containers share one network namespace and the app owns 3000 — a sim/pii sidecar... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | d849b928f455c800985398e7f1b659425adb312a5fa14fba5d9a14e62e9fe5dd |
| turbo-cache-control | no-preview |
| diff-view | unified |
| go-import | github.com/simstudioai/sim git https://github.com/simstudioai/sim.git |
| octolytics-dimension-user_id | 199344406 |
| octolytics-dimension-user_login | simstudioai |
| octolytics-dimension-repository_id | 912559512 |
| octolytics-dimension-repository_nwo | simstudioai/sim |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 912559512 |
| octolytics-dimension-repository_network_root_nwo | simstudioai/sim |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | true |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | a6c2f87cbcb6414452377b4967858ed6a66f1109 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width