> ## Documentation Index
> Fetch the complete documentation index at: https://docs.trainy.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Env Secrets

> Example task yamls for secrets

## Prerequisites

#### Setup

1. Create a `--kind=env` secret

```
$ konduktor secret create --kind=env --inline FOO=bar my-env-name
```

2. Check that the secret was properly created with:

```
$ konduktor secret list
```

For more details, check out the setup of secrets <a href="/secrets" target="_blank">here</a>.

#### Current Working Directory

```
$ ls
task.yaml
```

#### Launching

```
$ konduktor launch task.yaml
```

## Task.yaml

```
name: env-secrets

resources:
  cpus: 1
  memory: 1
  image_id: ubuntu
  labels:
    kueue.x-k8s.io/queue-name: user-queue
    maxRunDurationSeconds: "3200"

run: |
  echo "=== ENV TEST: FOO ==="
  echo "FOO=$FOO"
  echo "======================"
```
