mirror of
https://github.com/opentofu/opentofu.git
synced 2025-02-25 18:45:20 -06:00
Add page about official OpenTofu Docker image (#1271)
Signed-off-by: Nikita Barskov <nbarskov@gmail.com> Signed-off-by: Janos <86970079+janosdebugs@users.noreply.github.com> Co-authored-by: Janos <86970079+janosdebugs@users.noreply.github.com>
This commit is contained in:
parent
ee72400176
commit
851391f2e6
1
website/docs/intro/install/docker-pull.sh
Normal file
1
website/docs/intro/install/docker-pull.sh
Normal file
@ -0,0 +1 @@
|
||||
docker pull ghcr.io/opentofu/opentofu:latest
|
5
website/docs/intro/install/docker-run.sh
Normal file
5
website/docs/intro/install/docker-run.sh
Normal file
@ -0,0 +1,5 @@
|
||||
docker run \
|
||||
--workdir=/srv/workspace \
|
||||
--mount type=bind,source=.,target=/srv/workspace \
|
||||
ghcr.io/opentofu/opentofu:latest \
|
||||
init
|
50
website/docs/intro/install/docker.mdx
Normal file
50
website/docs/intro/install/docker.mdx
Normal file
@ -0,0 +1,50 @@
|
||||
---
|
||||
sidebar_position: 99
|
||||
sidebar_label: OCI container image
|
||||
description: |-
|
||||
Use official OCI container image available on GitHub Container Registry.
|
||||
---
|
||||
|
||||
import CodeBlock from '@theme/CodeBlock';
|
||||
import DockerPullScript from '!!raw-loader!./docker-pull.sh'
|
||||
import DockerRunScript from '!!raw-loader!./docker-run.sh'
|
||||
|
||||
# Use OpenTofu as Docker Image
|
||||
|
||||
OpenTofu is available as [OCI container images](https://github.com/opentofu/opentofu/pkgs/container/opentofu),
|
||||
and distributed via public GitHub Packages registry.
|
||||
|
||||
## Versions
|
||||
|
||||
Images are hosted as packages in opentofy GitHub organization. See the list
|
||||
of available versions [here](https://github.com/opentofu/opentofu/pkgs/container/opentofu/versions?filters%5Bversion_type%5D=tagged).
|
||||
|
||||
The multi platform images are available using the following tags:
|
||||
|
||||
- `latest`: latest overall version of OpenTofu,
|
||||
- `Major`: a specific major version of OpenTofu,
|
||||
- `Major`.`Minor`: a specific minor version of OpenTofu,
|
||||
- `Major`.`Minor`.`Patch`: a specific patch version of OpenTofu.
|
||||
|
||||
To pull platform-specific images (`amd64`, `arm`, `arm64`, `386`) use:
|
||||
|
||||
- `<Version>`-`<Platform>`: a platform specific version of OpenTofu.
|
||||
|
||||
## Usage
|
||||
|
||||
To pull the image from GitHub Packages registry:
|
||||
|
||||
<CodeBlock language="bash">{DockerPullScript}</CodeBlock>
|
||||
|
||||
To run OpenTofu as a Docker container:
|
||||
|
||||
<CodeBlock language="bash">{DockerRunScript}</CodeBlock>
|
||||
|
||||
:::tip
|
||||
|
||||
If you run into rate limiting issues with GitHub, create a
|
||||
[Personal Access Token](https://github.com/settings/tokens) and
|
||||
[log in](https://docs.github.com/en/packages/working-with-a-github-packages-registry/working-with-the-container-registry#authenticating-to-the-container-registry)
|
||||
to the registry.
|
||||
|
||||
:::
|
@ -59,5 +59,12 @@ You can install OpenTofu via a wide range of methods. Please select your operati
|
||||
description:
|
||||
"Use OpenTofu without installation on Linux, MacOS, Windows or FreeBSD.",
|
||||
},
|
||||
{
|
||||
type: "link",
|
||||
href: "/docs/intro/install/docker",
|
||||
label: "OCI container image",
|
||||
description:
|
||||
"Use official OCI container image available on GitHub Container Registry.",
|
||||
},
|
||||
]}
|
||||
/>
|
||||
|
Loading…
Reference in New Issue
Block a user