Skip to content

Commit a1cae53

Browse files
committed
refactor(supervisor): remove shared application Service
Signed-off-by: Taylor Mutch <taylormutch@gmail.com>
1 parent 5a08cae commit a1cae53

6 files changed

Lines changed: 19 additions & 38 deletions

File tree

‎.agents/skills/helm-dev-environment/SKILL.md‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -616,5 +616,6 @@ supervisor listener at port 9443 without discovery or a proxy. Provision the
616616
operator TLS Secret and an ingress-client NetworkPolicy first. Follow
617617
`e2e/kubernetes/app-listener/README.md` for direct in-cluster verification,
618618
shared-member selection, and the HA follow-up checks. Keep the fixture disabled
619-
in default profiles. Shared headless app Services enumerate members and must not
620-
be treated as load-balanced routes for sandboxes with different owners.
619+
in default profiles. Shared supervisors expose app ports on their Pod IPs
620+
without a shared app Service. Select the member owning the sandbox; automatic
621+
owner selection belongs to the later discovery API.

‎crates/openshell-supervisor/README.md‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -280,7 +280,7 @@ This path uses application or trusted-edge authentication independently from
280280
gateway authentication. It validates Host against SNI, preserves public
281281
Host/Origin and application cookies, strips gateway/edge identity material, and
282282
retains service-specific bearer passthrough. It has no discovery API or public
283-
URL selection. A shared pool's headless Service enumerates member addresses;
284-
clients must select the member owning their sandbox rather than connect to an
285-
arbitrary member. HA takeover may preserve the workload generation; existing ingress streams
283+
URL selection. Shared supervisors expose the app listener on each member's Pod
284+
IP without a shared app Service. Clients must select the member owning their
285+
sandbox. HA takeover may preserve the workload generation; existing ingress streams
286286
are not migrated. Runtime ownership fencing must reject stale connectors.

‎deploy/helm/openshell/templates/supervisor.yaml‎

Lines changed: 0 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -202,26 +202,4 @@ spec:
202202
- key: ca.crt
203203
path: ca.crt
204204
{{- end }}
205-
{{- if and (get $app "enabled") (get $appDeployment "create_service") }}
206-
---
207-
# Enumerates supervisor member addresses. Select the current owner before
208-
# connecting; this is not a load-balanced app endpoint for arbitrary members.
209-
apiVersion: v1
210-
kind: Service
211-
metadata:
212-
name: {{ $name }}-app
213-
namespace: {{ .Release.Namespace }}
214-
labels:
215-
{{- include "openshell.labels" . | nindent 4 }}
216-
app.kubernetes.io/component: supervisor-app
217-
spec:
218-
clusterIP: None
219-
selector:
220-
{{- include "openshell.supervisorSelectorLabels" . | nindent 4 }}
221-
ports:
222-
- name: app
223-
port: {{ $appPort }}
224-
targetPort: app
225-
protocol: TCP
226-
{{- end }}
227205
{{- end }}

‎docs/how-it-works/gateways/configuration.mdx‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1587,10 +1587,10 @@ On Kubernetes, provide a TLS Secret with `tls.crt` and `tls.key` matching
15871587
clients to reach the app port through NetworkPolicy. The driver mounts the Secret
15881588
only in supervisor containers. Restart supervisors after changing certificates.
15891589
With `create_service = true`, dedicated supervisors get a sandbox-owned headless
1590-
`os-app-<sandbox-id>` Service; shared supervisors get a separate
1591-
`<supervisor-name>-app` headless Service. Shared endpoints enumerate members:
1592-
select the supervisor owning the sandbox, rather than load-balancing requests
1593-
across different owners.
1590+
`os-app-<sandbox-id>` Service. This option applies only to dedicated supervisors.
1591+
Shared supervisors expose the app listener directly on each member's Pod IP;
1592+
no shared app Service is created. Select the supervisor owning the sandbox
1593+
when routing application traffic.
15941594

15951595
The Helm chart grants dedicated endpoint management the Service `patch` and
15961596
`delete` permissions when `create_service` is set. If you supply RBAC separately,

‎e2e/kubernetes/app-listener/README.md‎

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,12 @@ this stage. Use these direct-listener hostnames instead:
2020
- `default--<sandbox>.services.example.com` for the unnamed service.
2121
- `default--<sandbox>--web.services.example.com` for the named service.
2222

23-
Inspect supervisor Pods and the app Service's EndpointSlices. For dedicated
24-
supervisors, use `os-app-<sandbox-id>`. For shared supervisors, enumerate members
25-
through `<supervisor-name>-app` and select the Pod IP actually owning the sandbox.
26-
Do not select an arbitrary address when more than one member is present.
23+
Inspect supervisor Pods. Dedicated supervisors optionally expose
24+
`os-app-<sandbox-id>`; inspect that Service's EndpointSlices. Shared supervisors
25+
have no app Service: select the Pod IP actually owning the sandbox and use its
26+
configured app port. Do not select an arbitrary member when more than one is
27+
present. Check ownership through supervisor admission/release logs in this
28+
stage; automated owner selection belongs to the later discovery API.
2729

2830
From a permitted client Pod, mount only the public app certificate/CA and run:
2931

‎skills/debug-openshell-cluster/SKILL.md‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1490,9 +1490,9 @@ mount or app port. TLS material is mounted only in supervisors and reloads on
14901490
supervisor restart.
14911491

14921492
Inspect supervisor Pods, app Services, and EndpointSlices with `kubectl`. A
1493-
dedicated endpoint is `os-app-<sandbox-id>`; a shared endpoint is
1494-
`<supervisor-name>-app`. Headless shared endpoints enumerate members: select the
1495-
current sandbox owner, not an arbitrary member IP. Preserve service SNI and Host
1493+
dedicated endpoint is `os-app-<sandbox-id>`. Shared supervisors have no app
1494+
Service: connect to the current sandbox owner's Pod IP and configured app port.
1495+
Preserve service SNI and Host
14961496
when using curl's `--connect-to`, and verify the application certificate. A
14971497
port-forward bypasses Service and NetworkPolicy forwarding; also test from a
14981498
permitted in-cluster client. Operators provide ingress network rules.

0 commit comments

Comments
 (0)