Skip to content

Commit df2a627

Browse files
author
Adriano Santos
committed
feat: add new options to actorsystem crd
1 parent bf053ec commit df2a627

File tree

2 files changed

+84
-43
lines changed

2 files changed

+84
-43
lines changed

spawn_operator/spawn_operator/lib/spawn_operator/versions/api/v1/actor_system.ex

+32-12
Original file line numberDiff line numberDiff line change
@@ -29,25 +29,45 @@ defmodule SpawnOperator.Versions.Api.V1.ActorSystem do
2929
default: "erlang"
3030
cookie:
3131
type: string
32-
systemToSystem:
32+
features:
3333
type: object
3434
properties:
35-
enabled:
36-
type: boolean
37-
natsClusterSecretRef:
38-
type: string
39-
tls:
40-
type: object
41-
properties:
42-
secretName:
43-
type: string
44-
certManager:
35+
erlangMtls:
36+
type: object
37+
properties:
38+
enabled:
39+
type: boolean
40+
secretName:
41+
type: string
42+
certManager:
43+
type: object
44+
properties:
45+
enabled:
46+
type: boolean
47+
issuerName:
48+
type: string
49+
multiCluster:
4550
type: object
4651
properties:
4752
enabled:
4853
type: boolean
49-
issuerName:
54+
default: true
55+
transport:
56+
type: string
57+
enum: ["nats"]
58+
default: "nats"
59+
nats:
60+
type: object
61+
properties:
62+
enabled:
63+
type: boolean
64+
default: true
65+
url:
66+
type: string
67+
default: "nats://nats.eigr-functions.svc.cluster.local:4222"
68+
credentialsSecretRef:
5069
type: string
70+
default: "native-nats-credentials"
5171
statestore:
5272
type: object
5373
properties:

spawn_operator/spawn_operator/manifest.yaml

+52-31
Original file line numberDiff line numberDiff line change
@@ -44,9 +44,9 @@ spec:
4444
cpu: 200m
4545
memory: 380Mi
4646
securityContext:
47-
runAsNonRoot: false
4847
allowPrivilegeEscalation: false
4948
readOnlyRootFilesystem: true
49+
runAsNonRoot: false
5050
volumeMounts:
5151
- mountPath: /app/.cache/bakeware/
5252
name: bakeware-cache
@@ -70,14 +70,14 @@ spec:
7070
periodSeconds: 5
7171
successThreshold: 1
7272
timeoutSeconds: 5
73+
serviceAccountName: spawn-operator
7374
volumes:
7475
- emptyDir: {}
7576
name: bakeware-cache
76-
serviceAccountName: spawn-operator
77+
replicas: 2
7778
selector:
7879
matchLabels:
7980
k8s-app: spawn-operator
80-
replicas: 2
8181
kind: Deployment
8282
apiVersion: apps/v1
8383

@@ -90,15 +90,14 @@ spec:
9090
group: spawn-eigr.io
9191
names:
9292
kind: Activator
93+
singular: activator
9394
plural: activators
9495
shortNames:
9596
- act
9697
- acts
97-
singular: activator
9898
versions:
9999
- name: v1
100100
deprecated: false
101-
storage: true
102101
schema:
103102
openAPIV3Schema:
104103
type: object
@@ -113,6 +112,7 @@ spec:
113112
subresources:
114113
status: {}
115114
served: true
115+
storage: true
116116
deprecationWarning:
117117
kind: CustomResourceDefinition
118118
apiVersion: apiextensions.k8s.io/v1
@@ -126,18 +126,17 @@ spec:
126126
group: spawn-eigr.io
127127
names:
128128
kind: ActorHost
129+
singular: actorhost
129130
plural: actorhosts
130131
shortNames:
131132
- ac
132133
- ah
133134
- actor
134135
- actors
135136
- hosts
136-
singular: actorhost
137137
versions:
138138
- name: v1
139139
deprecated: false
140-
storage: true
141140
schema:
142141
openAPIV3Schema:
143142
type: object
@@ -335,6 +334,7 @@ spec:
335334
subresources:
336335
status: {}
337336
served: true
337+
storage: true
338338
deprecationWarning:
339339
kind: CustomResourceDefinition
340340
apiVersion: apiextensions.k8s.io/v1
@@ -348,16 +348,15 @@ spec:
348348
group: spawn-eigr.io
349349
names:
350350
kind: ActorSystem
351+
singular: actorsystem
351352
plural: actorsystems
352353
shortNames:
353354
- as
354355
- actorsys
355356
- system
356-
singular: actorsystem
357357
versions:
358358
- name: v1
359359
deprecated: false
360-
storage: true
361360
schema:
362361
openAPIV3Schema:
363362
type: object
@@ -396,31 +395,52 @@ spec:
396395
properties:
397396
cookie:
398397
type: string
399-
kind:
400-
default: erlang
401-
enum:
402-
- erlang
403-
- quic
404-
type: string
405-
systemToSystem:
398+
features:
406399
properties:
407-
enabled:
408-
type: boolean
409-
natsClusterSecretRef:
410-
type: string
411-
type: object
412-
tls:
413-
properties:
414-
certManager:
400+
erlangMtls:
401+
properties:
402+
certManager:
403+
properties:
404+
enabled:
405+
type: boolean
406+
issuerName:
407+
type: string
408+
type: object
409+
enabled:
410+
type: boolean
411+
secretName:
412+
type: string
413+
type: object
414+
multiCluster:
415415
properties:
416416
enabled:
417+
default: true
417418
type: boolean
418-
issuerName:
419+
transport:
420+
default: nats
421+
enum:
422+
- nats
423+
type: string
424+
type: object
425+
nats:
426+
properties:
427+
credentialsSecretRef:
428+
default: native-nats-credentials
429+
type: string
430+
enabled:
431+
default: true
432+
type: boolean
433+
url:
434+
default: nats://nats.eigr-functions.svc.cluster.local:4222
419435
type: string
420436
type: object
421-
secretName:
422-
type: string
423437
type: object
438+
kind:
439+
default: erlang
440+
enum:
441+
- erlang
442+
- quic
443+
type: string
424444
type: object
425445
statestore:
426446
properties:
@@ -458,6 +478,7 @@ spec:
458478
subresources:
459479
status: {}
460480
served: true
481+
storage: true
461482
deprecationWarning:
462483
kind: CustomResourceDefinition
463484
apiVersion: apiextensions.k8s.io/v1
@@ -680,12 +701,12 @@ metadata:
680701
labels:
681702
k8s-app: spawn-operator
682703
kind: ClusterRoleBinding
683-
subjects:
684-
- name: spawn-operator
685-
kind: ServiceAccount
686-
namespace: eigr-functions
687704
apiVersion: rbac.authorization.k8s.io/v1
688705
roleRef:
689706
name: spawn-operator
690707
kind: ClusterRole
691708
apiGroup: rbac.authorization.k8s.io
709+
subjects:
710+
- name: spawn-operator
711+
kind: ServiceAccount
712+
namespace: eigr-functions

0 commit comments

Comments
 (0)