-
Notifications
You must be signed in to change notification settings - Fork 3
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
Update index.md #27
base: main
Are you sure you want to change the base?
Update index.md #27
Conversation
Addresses the issue: bacalhau-project#23
@@ -1,63 +1,32 @@ | |||
--- | |||
description: How to use the Bacalhau Docker image | |||
description: How to use the Bacalhau CLI in Docker |
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.
I'm not sure this adds clarity?
--- | ||
|
||
# Bacalhau Docker Image | ||
# Bacalhau CLI from Docker |
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.
It's not "from Docker" - it's a docker image?
|
||
This documentation explains how to use the Bacalhau Docker image to run tasks and manage them using the Bacalhau client. | ||
This documentation explains how to use Bacalhau CLI from docker. |
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.
The former i think is clearer.
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.
rewrote for making it more clear.
|
||
## Prerequisites | ||
|
||
To get started, you need to install the Bacalhau client (see more information [here](../../../getting-started/installation.md)) and Docker. | ||
Install the [Bacalhau CLI in Docker](../../..//getting-started/installation#step-1.1-install-the-bacalhau-cli). |
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.
Why do we need to install the bacalhau client at all? aren't we using the pre-built image?
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.
I had to install bacalhau client else I kept getting the error: rkodhand@blr-mpe5j ~ % docker run -t ghcr.io/bacalhau-project/bacalhau:latest \ docker run \ --id-only \ --wait \ ubuntu:latest \ -- sh -c 'uname -a && echo "Hello from Docker Bacalhau!"' 12:02:36.828 | INF pkg/repo/fs.go:93 > Initializing repo at '/root/.bacalhau' for environment 'production' publicapi: after posting request: "This endpoint is deprecated. See the migration guide at https://docs.bacalhau.org/references/cli-reference/command-migration for more information"
You can also pull a specific version of the image, e.g.: | ||
|
||
```bash | ||
docker pull ghcr.io/bacalhau-project/bacalhau:v0.3.16 |
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.
why are we pinning to such an old version?
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.
Exactly that is why these instructions were removed from the guide and only the latest version is retained.
|
||
```bash | ||
docker run -t ghcr.io/bacalhau-project/bacalhau:latest version | ||
``` | ||
|
||
Expected Output: | ||
The output is similar to: |
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 "Expected Output" - the change is too wordy. If there are variables that will change, then just mention them.
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.
I just followed the standard documentation guidelines https://developers.google.com/style/code-in-text
|
||
```bash | ||
docker run -t ghcr.io/bacalhau-project/bacalhau:latest version | ||
``` | ||
|
||
Expected Output: | ||
The output is similar to: | ||
|
||
```shell | ||
13:38:54.518 | INF pkg/repo/fs.go:81 > Initializing repo at '/root/.bacalhau' for environment 'production' |
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.
|
||
In the example below, an Ubuntu-based job runs to print the message 'Hello from Docker Bacalhau': | ||
For example to run an Ubuntu-based job that prints the message 'Hello from Docker Bacalhau': |
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.
I like the former language better.
@@ -77,7 +46,7 @@ docker run -t ghcr.io/bacalhau-project/bacalhau:latest \ | |||
5. `--`: Separate Bacalhau parameters from the command to be executed inside the container | |||
6. `sh -c 'uname -a && echo "Hello from Docker Bacalhau!"'`: The command executed inside the container | |||
|
|||
Let's have a look at the command execution in the terminal: | |||
The command execution in the terminal is similar to: |
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.
The former feels friendlier.
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.
Followed the word standard writing guidelines. https://developers.google.com/style/accessibility
|
||
``` | ||
docker run -t ghcr.io/bacalhau-project/bacalhau:latest \ | ||
describe ab95a5cc-e6b7-40f1-957d-596b02251a66 \ | ||
| grep -A 2 "stdout: |" | ||
``` | ||
|
||
Expected Output: | ||
The output is similar to: |
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.
Not "is similar to"
Thank you for the suggestions @aronchick ! I will incorporate the changes as soon as possible. |
bacalhau docker run \ | ||
--id-only \ | ||
--wait \ | ||
--gpu 1 \ | ||
ghcr.io/bacalhau-project/examples/stable-diffusion-gpu:0.0.1 -- \ | ||
python main.py --o ./outputs --p "A Docker whale and a cod having a conversation about the state of the ocean" | ||
``` |
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 job was not successful for me and I kept getting the error: Error: not enough nodes to run job. requested: 1, available: 3, suitable: 0. • Node QmPLPUUj: node busy with available capacity {CPU: 0.3500000000000001, Memory: 3.7 GB, Disk: 1.7 TB, GPU: 0} and queue capacity {CPU: 1.5, Memory: 5.0 GB, Disk: 16 GB, GPU: 0} • Node QmbxGSsM: node busy with available capacity {CPU: 0.10000000000000009, Memory: 1.7 GB, Disk: 1.7 TB, GPU: 0} and queue capacity {CPU: 1, Memory: 2.0 GB, Disk: 2.8 kB, GPU: 0} • Node n-e002001e: node busy with available capacity {CPU: 0.6000000000000001, Memory: 2.7 GB, Disk: 1.7 TB, GPU: 0}
I am not sure if it was because of the hardware resource requirements at my end. If yes, then may be best to add the hardware requirements in the Prereq section.
Hi @aronchick I tried the instructions and updated the guide. |
Addresses the issue: #23