spinframework / spinframework/spin-operator
Enable configuring the Shim via the spin-operator
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 289
- Forks
- 34
- PR merge metrics
- No merged PRs in 30d
Description
Users should be able to set Pod environment variables via the SpinApp CRD. These can be used for configuring settings, such as open telemetry endpoints:
env:
- name: NODE_IP
valueFrom:
fieldRef:
fieldPath: status.hostIP
- name: OTEL_EXPORTER_OTLP_ENDPOINT
value: "http://$(NODE_IP):4318"
Proposal: add a SpinApp.spec.env
Workaround
Create deployment directly instead of creating a SpinApp CR, bypassing the Spin operator:
apiVersion: apps/v1
kind: Deployment
metadata:
name: spin-test
spec:
replicas: 1
selector:
matchLabels:
app: spin-test
template:
metadata:
labels:
app: spin-test
spec:
runtimeClassName: wasmtime-spin-v2
containers:
- name: spin-test
image: ttl.sh/spin-foo-123:48h
command: ["/"]
ports:
- containerPort: 80
env:
- name: NODE_IP
valueFrom:
fieldRef:
fieldPath: status.hostIP
- name: OTEL_EXPORTER_OTLP_ENDPOINT
value: "http://$(NODE_IP):4318"
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Begin with the SpinApp CRD definition and the operator's generated Deployment, then trace how pod environment is currently configured. Implement the proposed spec.env field and confirm that the resulting Deployment preserves value and valueFrom entries, including the NODE_IP and OTEL example.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go, kubernetes, wasm
- Domain
- api, devops, infrastructure
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100