Skip to content

Commit

Permalink
Added JMAP and Webadmin endpoints.
Browse files Browse the repository at this point in the history
Signed-off-by: sami <[email protected]>
  • Loading branch information
samiulsami committed Jul 12, 2024
1 parent 6bc40c9 commit d14f8b0
Show file tree
Hide file tree
Showing 7 changed files with 27 additions and 10 deletions.
5 changes: 3 additions & 2 deletions apis/installer/v1alpha1/inbox_agent_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -96,8 +96,9 @@ type InboxAgentApiserver struct {
}

type InboxServerInfo struct {
Endpoint string `json:"endpoint"`
Token string `json:"token"`
JMAPEndpoint string `json:"jmapEndpoint"`
WebadminEndpoint string `json:"webadminEndpoint"`
Token string `json:"token"`
}

// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
Expand Down
3 changes: 2 additions & 1 deletion charts/inbox-agent/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,8 @@ The following table lists the configurable parameters of the `inbox-agent` chart
| apiserver.servingCerts.serverKey | Private key for the serving certificate used by webhook server. | <code>""</code> |
| monitoring.agent | Name of monitoring agent (either "prometheus.io/operator" or "prometheus.io/builtin") | <code>"none"</code> |
| monitoring.serviceMonitor.labels | Specify the labels for ServiceMonitor. Prometheus crd will select ServiceMonitor using these labels. Only usable when monitoring agent is `prometheus.io/operator`. | <code>{}</code> |
| inboxServer.endpoint | | <code>""</code> |
| inboxServer.jmapEndpoint | | <code>""</code> |
| inboxServer.webadminEndpoint | | <code>""</code> |
| inboxServer.token | | <code>""</code> |


Expand Down
5 changes: 3 additions & 2 deletions charts/inbox-agent/templates/operator/config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,6 @@ metadata:
{{- include "inbox-agent.labels" . | nindent 4 }}
type: Opaque
stringData:
endpoint: {{ .Values.inboxServer.endpoint }}
token: {{ .Values.inboxServer.token }}
jmapEndpoint: {{ .Values.inboxServer.jmapEndpoint }}
webadminEndpoint: {{ .Values.inboxServer.webadminEndpoint }}
token: {{.Values.inboxServer.token}}
7 changes: 6 additions & 1 deletion charts/inbox-agent/templates/operator/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,12 @@ spec:
valueFrom:
secretKeyRef:
name: {{ include "inbox-agent.fullname" . }}-config
key: endpoint
key: jmapEndpoint
- name: INBOX_SERVER_WEBADMIN_ENDPOINT
valueFrom:
secretKeyRef:
name: {{ include "inbox-agent.fullname" . }}-config
key: webadminEndpoint
- name: INBOX_SERVER_TOKEN
valueFrom:
secretKeyRef:
Expand Down
7 changes: 6 additions & 1 deletion charts/inbox-agent/templates/webhook/deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -69,11 +69,16 @@ spec:
valueFrom:
fieldRef:
fieldPath: metadata.namespace
- name: INBOX_SERVER_WEBADMIN_ENDPOINT
valueFrom:
secretKeyRef:
name: {{ include "inbox-agent.fullname" . }}-config
key: webadminEndpoint
- name: INBOX_SERVER_JMAP_ENDPOINT
valueFrom:
secretKeyRef:
name: {{ include "inbox-agent.fullname" . }}-config
key: endpoint
key: jmapEndpoint
- name: INBOX_SERVER_TOKEN
valueFrom:
secretKeyRef:
Expand Down
7 changes: 5 additions & 2 deletions charts/inbox-agent/values.openapiv3_schema.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -945,13 +945,16 @@ properties:
type: array
inboxServer:
properties:
endpoint:
jmapEndpoint:
type: string
token:
type: string
webadminEndpoint:
type: string
required:
- endpoint
- jmapEndpoint
- token
- webadminEndpoint
type: object
logLevel:
format: int32
Expand Down
3 changes: 2 additions & 1 deletion charts/inbox-agent/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -137,5 +137,6 @@ monitoring:
labels: {}

inboxServer:
endpoint: ""
jmapEndpoint: ""
webadminEndpoint: ""
token: ""

0 comments on commit d14f8b0

Please sign in to comment.