Update CONTRIBUTING.md: Update 'docker run' example (#2005)

Signed-off-by: Tom Noonan II <tom@tjnii.com>
This commit is contained in:
Tom Noonan II 2024-09-23 07:23:32 -04:00 committed by GitHub
parent 48abc52e46
commit bc166ce498
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -112,8 +112,12 @@ If you have Docker or a compatible alternative installed, you can run the entire
docker run \
--rm \
-v "$PWD":/usr/src/opentofu\
-w /usr/src/opentofu golang:1.21.3\
GOOS=linux GOARCH=amd64 CGO_ENABLED=0 go build -o tofu -v -buildvcs=false ./cmd/tofu
-w /usr/src/opentofu\
-e GOOS=linux\
-e GOARCH=amd64\
-e CGO_ENABLED=0\
golang:1.21.3\
go build -o tofu -v -buildvcs=false ./cmd/tofu
```
This will create the `tofu` binary in the current working directory, which you can test by running `./tofu --version`.