Skip to content

Commit f1f4f36

Browse files
Add Docs
Signed-off-by: Carlos Eduardo Arango Gutierrez <[email protected]>
1 parent 45e4356 commit f1f4f36

File tree

16 files changed

+935
-136
lines changed

16 files changed

+935
-136
lines changed

.github/workflows/ci.yaml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,11 @@ jobs:
2727

2828
golang:
2929
uses: ./.github/workflows/golang.yaml
30-
30+
31+
docs-check:
32+
uses: ./.github/workflows/docs_check.yaml
33+
secrets: inherit
34+
3135
image:
3236
uses: ./.github/workflows/image.yaml
3337
needs: [golang, code-scanning]

.github/workflows/docs_check.yaml

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
## Copyright (c) 2025, NVIDIA CORPORATION. All rights reserved.##
2+
## Licensed under the Apache License, Version 2.0 (the "License");
3+
## you may not use this file except in compliance with the License.
4+
## You may obtain a copy of the License at
5+
##
6+
## http://www.apache.org/licenses/LICENSE-2.0
7+
##
8+
## Unless required by applicable law or agreed to in writing, software
9+
## distributed under the License is distributed on an "AS IS" BASIS,
10+
## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11+
## See the License for the specific language governing permissions and
12+
## limitations under the License.
13+
##
14+
15+
name: Docs
16+
17+
on:
18+
workflow_call:
19+
20+
jobs:
21+
lint:
22+
runs-on: ubuntu-latest
23+
24+
steps:
25+
- name: Checkout repository
26+
uses: actions/checkout@v4
27+
28+
- name: Set up Ruby
29+
uses: ruby/setup-ruby@v1
30+
with:
31+
ruby-version: '3.5'
32+
33+
- name: Install mdl
34+
run: gem install mdl -v 0.13.0
35+
36+
- name: Run Markdown lint
37+
run: |
38+
find docs/ -path docs/vendor -prune -false -o -name '*.md' | xargs mdl -s docs/mdl-style.rb

Makefile

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,9 @@
88
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
99
# See the License for the specific language governing permissions and
1010
# limitations under the License.
11-
.PHONY: build fmt verify release lint vendor mod-tidy mod-vendor mod-verify check-vendor
11+
.PHONY: build fmt verify release lint vendor mod-tidy mod-vendor mod-verify check-vendor mdlint
1212

13+
CONTAINER_RUN_CMD ?= docker run
1314
GO_CMD ?= go
1415
GO_FMT ?= gofmt
1516
GO_SRC := $(shell find . -type f -name '*.go' -not -path "./vendor/*")
@@ -88,6 +89,14 @@ coverage: test
8889
cat $(COVERAGE_FILE) | grep -v "_mock.go" > $(COVERAGE_FILE).no-mocks
8990
go tool cover -func=$(COVERAGE_FILE).no-mocks
9091

92+
mdlint:
93+
${CONTAINER_RUN_CMD} \
94+
--rm \
95+
--volume "${PWD}:/workdir:ro,z" \
96+
--workdir /workdir \
97+
ruby:slim \
98+
/workdir/scripts/mdlint.sh
99+
91100
release:
92101
@rm -rf bin
93102
@mkdir -p bin

README.md

Lines changed: 70 additions & 134 deletions
Original file line numberDiff line numberDiff line change
@@ -2,170 +2,106 @@
22

33
> * Tech preview, under heavy development *
44
5-
A tool for creating and managing GPU ready Cloud test environments.
5+
A tool for creating and managing GPU-ready Cloud test environments.
66

7-
## Installation
7+
---
8+
9+
## 📖 Documentation
10+
11+
- [Quick Start](docs/quick-start.md)
12+
- [Prerequisites](docs/prerequisites.md)
13+
- [Commands Reference](docs/commands/)
14+
- [Contributing Guide](docs/contributing/)
15+
- [Examples](docs/examples/)
16+
17+
---
18+
19+
## 🚀 Quick Start
20+
21+
See [docs/quick-start.md](docs/quick-start.md) for a full walkthrough.
822

923
```bash
1024
make build
11-
mv ./bin/holodeck /usr/local/bin/holodeck
25+
sudo mv ./bin/holodeck /usr/local/bin/holodeck
26+
holodeck --help
1227
```
1328

14-
### Prerequisites
29+
---
1530

16-
If utilizing the AWS provider, a valid AWS credentials must be available in the environment.
31+
## 🛠️ Prerequisites
1732

18-
```yaml
19-
apiVersion: holodeck.nvidia.com/v1alpha1
20-
kind: Environment
21-
metadata:
22-
name: holodeck
23-
description: "Devel infra environment"
24-
spec:
25-
provider: aws
26-
```
33+
- Go 1.20+
34+
- (For AWS) Valid AWS credentials in your environment
35+
- (For SSH) Reachable host and valid SSH key
2736

28-
If utilizing the SSH provider, a valid SSH key must and reachable host must be available in the environment file.
29-
30-
```yaml
31-
apiVersion: holodeck.nvidia.com/v1alpha1
32-
kind: Environment
33-
metadata:
34-
name: holodeck
35-
description: "Devel infra environment"
36-
spec:
37-
provider: aws
38-
auth:
39-
keyName: user
40-
privateKey: "/Users/user/.ssh/user.pem"
41-
instance:
42-
hostUrl: "<some-reachable-host-ip>"
43-
```
37+
See [docs/prerequisites.md](docs/prerequisites.md) for details.
38+
39+
---
40+
41+
## 📝 How to Contribute
42+
43+
See [docs/contributing/](docs/contributing/) for full details.
44+
45+
### Main Makefile Targets
46+
47+
- `make build` – Build the holodeck binary
48+
- `make test` – Run all tests
49+
- `make lint` – Run linters
50+
- `make clean` – Remove build artifacts
51+
52+
---
4453

45-
## Usage
54+
## 🧑‍💻 Usage
55+
56+
See [docs/commands/](docs/commands/) for detailed command documentation and examples.
4657

4758
```bash
4859
holodeck --help
4960
```
5061

51-
### The Environment CRD
52-
53-
```yaml
54-
apiVersion: holodeck.nvidia.com/v1alpha1
55-
kind: Environment
56-
metadata:
57-
name: holodeck
58-
description: "Devel infra environment"
59-
spec:
60-
provider: aws # or ssh currently supported
61-
auth:
62-
keyName: user
63-
privateKey: "/Users/user/.ssh/user.pem"
64-
instance: # if provider is ssh you need to define here the hostUrl
65-
type: g4dn.xlarge
66-
region: eu-north-1
67-
ingressIpRanges:
68-
- 192.168.1.0/26
69-
image:
70-
architecture: amd64
71-
imageId: ami-0fe8bec493a81c7da # Ubuntu 22.04 image
72-
containerRuntime:
73-
install: true
74-
name: containerd
75-
version: 1.6.24
76-
kubernetes:
77-
install: true
78-
installer: kubeadm # supported installers: kubeadm, kind, microk8s
79-
version: v1.28.5
80-
```
81-
82-
The dependencies are resolved automatically, from top to bottom. Following the
83-
pattern:
62+
### Example: Create an environment
8463

85-
> Kubernetes -> Container Runtime -> Container Toolkit -> NVDriver
64+
```bash
65+
holodeck create -f ./examples/v1alpha1_environment.yaml
66+
```
8667

87-
If Kubernetes is requested, and no container runtime is requested, a default
88-
container runtime will be added to the environment..
68+
### Example: List environments
8969

90-
If Container Toolkit is requested, and no container runtime is requested, a
91-
default container runtime will be added to the environment.
70+
```bash
71+
holodeck list
72+
```
9273

93-
### Create an environment
74+
### Example: Delete an environment
9475

9576
```bash
96-
$ holodeck create -f ./examples/v1alpha1_environment.yaml
97-
...
77+
holodeck delete <instance-id>
9878
```
9979

100-
### Delete an environment
80+
### Example: Check status
10181

10282
```bash
103-
$ holodeck delete -f ./examples/v1alpha1_environment.yaml
104-
...
83+
holodeck status <instance-id>
10584
```
10685

107-
### Dry Run
86+
### Example: Dry Run
10887

10988
```bash
110-
$ holodeck dryrun -f ./examples/v1alpha1_environment.yaml
111-
Dryrun environment holodeck 🔍
112-
✔ Checking if instance type g4dn.xlarge is supported in region eu-north-1
113-
✔ Checking if image ami-0fe8bec493a81c7da is supported in region eu-north-1
114-
✔ Resolving dependencies 📦
115-
Dryrun succeeded 🎉
89+
holodeck dryrun -f ./examples/v1alpha1_environment.yaml
11690
```
11791

118-
## Supported Cuda-Drivers
92+
---
11993

120-
Supported Nvidia drivers are:
94+
## 📦 Supported Cuda-Drivers
12195

122-
```yaml
123-
nvidiaDriver:
124-
install: true
125-
version: <version>
126-
```
127-
Where `<version>` can be a prefix of any package version. The following are example package versions:
128-
129-
- 570.86.15-0ubuntu1
130-
- 570.86.10-0ubuntu1
131-
- 565.57.01-0ubuntu1
132-
- 560.35.05-0ubuntu1
133-
- 560.35.03-1
134-
- 560.28.03-1
135-
- 555.42.06-1
136-
- 555.42.02-1
137-
- 550.144.03-0ubuntu1
138-
- 550.127.08-0ubuntu1
139-
- 550.127.05-0ubuntu1
140-
- 550.90.12-0ubuntu1
141-
- 550.90.07-1
142-
- 550.54.15-1
143-
- 550.54.14-1
144-
- 545.23.08-1
145-
- 545.23.06-1
146-
- 535.230.02-0ubuntu1
147-
- 535.216.03-0ubuntu1
148-
- 535.216.01-0ubuntu1
149-
- 535.183.06-1
150-
- 535.183.01-1
151-
- 535.161.08-1
152-
- 535.161.07-1
153-
- 535.154.05-1
154-
- 535.129.03-1
155-
- 535.104.12-1
156-
- 535.104.05-1
157-
- 535.86.10-1
158-
- 535.54.03-1
159-
- 530.30.02-1
160-
- 525.147.05-1
161-
- 525.125.06-1
162-
- 525.105.17-1
163-
- 525.85.12-1
164-
- 525.60.13-1
165-
- 520.61.05-1
166-
- 515.105.01-1
167-
- 515.86.01-1
168-
- 515.65.07-1
169-
- 515.65.01-1
170-
- 515.48.07-1
171-
- 515.43.04-1
96+
See [docs/prerequisites.md](docs/prerequisites.md#supported-cuda-drivers) for the full list and usage.
97+
98+
---
99+
100+
## 📂 More
101+
102+
- [Examples](docs/examples/)
103+
- [Guides](docs/guides/)
104+
105+
---
106+
107+
For more information, see the [docs/](docs/) directory.

docs/commands/README.md

Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
# Command Reference
2+
3+
This document provides detailed information about all available Holodeck
4+
commands.
5+
6+
## Basic Commands
7+
8+
- [create](create.md) - Create a new environment
9+
- [delete](delete.md) - Delete an existing environment
10+
- [list](list.md) - List all environments
11+
- [status](status.md) - Check the status of an environment
12+
- [dryrun](dryrun.md) - Perform a dry run of environment creation
13+
14+
## Command Usage
15+
16+
All commands follow this general pattern:
17+
18+
```bash
19+
holodeck [command] [flags]
20+
```
21+
22+
For detailed help on any command:
23+
24+
```bash
25+
holodeck [command] --help
26+
```
27+
28+
## Global Options
29+
30+
- `--log-level string` - Log level (debug, info, warn, error) (default: "info")
31+
- `--no-color` - Disable color output
32+
33+
## Examples
34+
35+
### Create an Environment
36+
37+
```bash
38+
holodeck create -f environment.yaml
39+
```
40+
41+
### List Environments
42+
43+
```bash
44+
holodeck list
45+
```
46+
47+
### Check Environment Status
48+
49+
```bash
50+
holodeck status <instance-id>
51+
```
52+
53+
### Delete an Environment
54+
55+
```bash
56+
holodeck delete <instance-id>
57+
```
58+
59+
### Dry Run
60+
61+
```bash
62+
holodeck dryrun -f environment.yaml
63+
```
64+
65+
For detailed information about each command, click on the command name above.

0 commit comments

Comments
 (0)