Skip to content

chore: add envbox documentation #7198

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 5 commits into from
Apr 26, 2023
Merged

chore: add envbox documentation #7198

merged 5 commits into from
Apr 26, 2023

Conversation

sreya
Copy link
Collaborator

@sreya sreya commented Apr 19, 2023

fixes #6789

Unsure whether we should be adding the template to the repo at this point or not. We can keep it in envbox if we want. I figured we could keep it in examples/ but not add it to templates init until we feel comfortable offering it as a starter template.

@sreya sreya requested a review from bpmct April 19, 2023 05:14
Copy link
Member

@bpmct bpmct left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also, I'm fine having it in examples :)

Comment on lines 159 to 171
```yaml
# An example of referencing a secret in an environment variable.
kind: Pod
spec:
containers:
- name: envbox
env:
- name: CODER_IMAGE_PULL_SECRET
valueFrom:
secretKeyRef:
name: <name>
key: .dockerconfigjson
```
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It might make sense to show this in Terraform instead of YAML since 99% of people on this doc will be looking to add this to their envbox template in Coder. Or show both 🤷🏼

env {
  name = "CODER_IMAGE_PULL_SECRET"
  value_from {
    secret_key_ref {
      name = "<name>"
      key = ".dockerconfigjson"
    }
  }
}

Comment on lines 146 to 148
node_selector = {
sreya-test = true
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh this too!

| `CODER_AGENT_TOKEN` | The [Coder Agent](https://coder.com/docs/v2/latest/about/architecture#agents) token to pass to the inner container. | True |
| `CODER_INNER_ENVS` | The environment variables to pass to the inner container. A wildcard can be used to match a prefix. Ex: `CODER_INNER_ENVS=KUBERNETES_*,MY_ENV,MY_OTHER_ENV` | false |
| `CODER_INNER_HOSTNAME` | The hostname to use for the inner container. | false |
| `CODER_IMAGE_PULL_SECRET` | The docker credentials to use when pulling the inner container. The recommended way to do this is to create an [Image Pull Secret](https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/#registry-secret-existing-credentials) and then reference the secret using an [environment variable](https://kubernetes.io/docs/tasks/inject-data-application/distribute-credentials-secure/#define-container-environment-variables-using-secret-data). | false |
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry. I totally missed this part 🤦🏼

If you want to remove this from the docker in docker docs in favor of this, that's fine.

@sreya sreya merged commit f1763f2 into main Apr 26, 2023
@sreya sreya deleted the jon/envboxdocs branch April 26, 2023 21:42
@github-actions github-actions bot locked and limited conversation to collaborators Apr 26, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

envbox: add docs to DinD
2 participants