-
Notifications
You must be signed in to change notification settings - Fork 948
chore: add workspaceProxy to helm chart #7398
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -23,3 +23,5 @@ | |
.vscode/ | ||
Makefile | ||
artifacthub-repo.yml | ||
|
||
tests |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,177 @@ | ||
--- | ||
# Source: coder/templates/coder.yaml | ||
apiVersion: v1 | ||
kind: ServiceAccount | ||
metadata: | ||
name: "coder" | ||
annotations: | ||
{} | ||
labels: | ||
helm.sh/chart: coder-0.1.0 | ||
app.kubernetes.io/name: coder | ||
app.kubernetes.io/instance: release-name | ||
app.kubernetes.io/part-of: coder | ||
app.kubernetes.io/version: "0.1.0" | ||
app.kubernetes.io/managed-by: Helm | ||
--- | ||
# Source: coder/templates/rbac.yaml | ||
apiVersion: rbac.authorization.k8s.io/v1 | ||
kind: Role | ||
metadata: | ||
name: coder-workspace-perms | ||
rules: | ||
- apiGroups: [""] | ||
resources: ["pods"] | ||
verbs: ["*"] | ||
- apiGroups: [""] | ||
resources: ["persistentvolumeclaims"] | ||
verbs: ["*"] | ||
--- | ||
# Source: coder/templates/rbac.yaml | ||
apiVersion: rbac.authorization.k8s.io/v1 | ||
kind: RoleBinding | ||
metadata: | ||
name: "coder" | ||
subjects: | ||
- kind: ServiceAccount | ||
name: "coder" | ||
roleRef: | ||
apiGroup: rbac.authorization.k8s.io | ||
kind: Role | ||
name: coder-workspace-perms | ||
--- | ||
# Source: coder/templates/service.yaml | ||
apiVersion: v1 | ||
kind: Service | ||
metadata: | ||
name: coder | ||
labels: | ||
helm.sh/chart: coder-0.1.0 | ||
app.kubernetes.io/name: coder | ||
app.kubernetes.io/instance: release-name | ||
app.kubernetes.io/part-of: coder | ||
app.kubernetes.io/version: "0.1.0" | ||
app.kubernetes.io/managed-by: Helm | ||
annotations: | ||
{} | ||
spec: | ||
type: LoadBalancer | ||
sessionAffinity: ClientIP | ||
ports: | ||
- name: "http" | ||
port: 80 | ||
targetPort: "http" | ||
protocol: TCP | ||
externalTrafficPolicy: "Cluster" | ||
selector: | ||
app.kubernetes.io/name: coder | ||
app.kubernetes.io/instance: release-name | ||
--- | ||
# Source: coder/templates/coder.yaml | ||
apiVersion: apps/v1 | ||
kind: Deployment | ||
metadata: | ||
name: coder | ||
labels: | ||
helm.sh/chart: coder-0.1.0 | ||
app.kubernetes.io/name: coder | ||
app.kubernetes.io/instance: release-name | ||
app.kubernetes.io/part-of: coder | ||
app.kubernetes.io/version: "0.1.0" | ||
app.kubernetes.io/managed-by: Helm | ||
annotations: | ||
{} | ||
spec: | ||
replicas: 1 | ||
selector: | ||
matchLabels: | ||
app.kubernetes.io/name: coder | ||
app.kubernetes.io/instance: release-name | ||
template: | ||
metadata: | ||
labels: | ||
helm.sh/chart: coder-0.1.0 | ||
app.kubernetes.io/name: coder | ||
app.kubernetes.io/instance: release-name | ||
app.kubernetes.io/part-of: coder | ||
app.kubernetes.io/version: "0.1.0" | ||
app.kubernetes.io/managed-by: Helm | ||
annotations: | ||
{} | ||
spec: | ||
serviceAccountName: "coder" | ||
restartPolicy: Always | ||
terminationGracePeriodSeconds: 60 | ||
affinity: | ||
podAntiAffinity: | ||
preferredDuringSchedulingIgnoredDuringExecution: | ||
- podAffinityTerm: | ||
labelSelector: | ||
matchExpressions: | ||
- key: app.kubernetes.io/instance | ||
operator: In | ||
values: | ||
- coder | ||
topologyKey: kubernetes.io/hostname | ||
weight: 1 | ||
containers: | ||
- name: coder | ||
image: "ghcr.io/coder/coder:latest" | ||
imagePullPolicy: IfNotPresent | ||
command: | ||
- /opt/coder | ||
args: | ||
- proxy | ||
- server | ||
resources: | ||
{} | ||
lifecycle: | ||
{} | ||
env: | ||
- name: CODER_HTTP_ADDRESS | ||
value: "0.0.0.0:8080" | ||
- name: CODER_PROMETHEUS_ADDRESS | ||
value: "0.0.0.0:2112" | ||
# Set the default access URL so a `helm apply` works by default. | ||
# See: https://github.com/coder/coder/issues/5024 | ||
- name: CODER_ACCESS_URL | ||
value: "http://coder.default.svc.cluster.local" | ||
# Used for inter-pod communication with high-availability. | ||
- name: KUBE_POD_IP | ||
valueFrom: | ||
fieldRef: | ||
fieldPath: status.podIP | ||
- name: CODER_DERP_SERVER_RELAY_URL | ||
value: "http://$(KUBE_POD_IP):8080" | ||
|
||
- name: CODER_PRIMARY_ACCESS_URL | ||
value: https://dev.coder.com | ||
- name: CODER_PROXY_SESSION_TOKEN | ||
valueFrom: | ||
secretKeyRef: | ||
key: token | ||
name: coder-workspace-proxy-session-token | ||
ports: | ||
- name: "http" | ||
containerPort: 8080 | ||
protocol: TCP | ||
securityContext: | ||
allowPrivilegeEscalation: false | ||
readOnlyRootFilesystem: null | ||
runAsGroup: 1000 | ||
runAsNonRoot: true | ||
runAsUser: 1000 | ||
seccompProfile: | ||
type: RuntimeDefault | ||
readinessProbe: | ||
httpGet: | ||
path: /api/v2/buildinfo | ||
port: "http" | ||
scheme: "HTTP" | ||
livenessProbe: | ||
httpGet: | ||
path: /api/v2/buildinfo | ||
port: "http" | ||
scheme: "HTTP" | ||
volumeMounts: [] | ||
volumes: [] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
coder: | ||
workspaceProxy: true | ||
|
||
image: | ||
tag: latest | ||
|
||
env: | ||
- name: CODER_PRIMARY_ACCESS_URL | ||
value: "https://dev.coder.com" | ||
- name: CODER_PROXY_SESSION_TOKEN | ||
valueFrom: | ||
secretKeyRef: | ||
name: coder-workspace-proxy-session-token | ||
key: token |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,28 @@ | ||
# coder -- Primary configuration for `coder server`. | ||
coder: | ||
# coder.replicaCount -- The number of Kubernetes deployment replicas. | ||
# This should only be increased if High Availability is enabled. | ||
# coder.replicaCount -- The number of Kubernetes deployment replicas. This | ||
# should only be increased if High Availability is enabled. | ||
# | ||
# This is an Enterprise feature. Contact [email protected]. | ||
replicaCount: 1 | ||
|
||
# coder.workspaceProxy -- Whether or not this deployment of Coder is a Coder | ||
# Workspace Proxy. Workspace Proxies reduce the latency between the user and | ||
# their workspace for web connections (workspace apps and web terminal) and | ||
# proxied connections from the CLI. Workspace Proxies are optional and only | ||
# recommended for geographically sparse teams. | ||
# | ||
# Make sure you set CODER_PRIMARY_ACCESS_URL and CODER_PROXY_SESSION_TOKEN in | ||
# the environment below. You can get a proxy token using the CLI: | ||
# coder proxy create \ | ||
# --name "proxy-name" \ | ||
# --display-name "Proxy Name" \ | ||
# --icon "/emojis/xyz.png" | ||
# | ||
# This is an Enterprise feature. Contact [email protected] | ||
# Docs: https://coder.com/docs/v2/latest/admin/workspace-proxies | ||
workspaceProxy: false | ||
|
||
# coder.image -- The image to use for Coder. | ||
image: | ||
# coder.image.repo -- The repository of the image. | ||
|
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this be hardcoded?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a test file, not the actual values.yaml file.