Skip to content

Commit

Permalink
docs: reorg plugins installation tabs
Browse files Browse the repository at this point in the history
In order to better document packer plugins installation methods, and
since `packer plugins install' is not really manual, we split in two
sections the "manual installation".
  • Loading branch information
lbajolet-hashicorp committed Nov 27, 2023
1 parent 17ff508 commit e40ec9c
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions website/content/docs/plugins/install-plugins.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ Choose the tab that corresponds to the type of plugin you want to install. If yo
- Single-component plugin names have a prefix containing the component type, like `packer-provisioner-` or `packer-builder`.

<Tabs>
<Tab heading="Packer init (recommended from Packer v1.7.0)">
<Tab heading="Packer init (recommended with HCL2 templates)">

-> **Note:** Only _multi-component plugin binaries_ -- plugins named
packer-plugin-\*, like the `packer-plugin-amazon` -- are expected to work with
Expand Down Expand Up @@ -198,28 +198,29 @@ Packer will error if you set the `packer-plugin-` prefix in a `source`. This
will avoid conflicting with other plugins for other tools, like Terraform.

</Tab>
<Tab heading="manually (multi-component plugin)">
<Tab heading="Packer plugins install (recommended with legacy JSON templates)">

-> The [`packer plugins`](/packer/docs/commands/plugins), available from Packer v1.8.0, command allows
you to install plugins without going through `init`.
-> The [`packer plugins`](/packer/docs/commands/plugins), available from Packer v1.8.0, command allows
you to install plugins without going through `init`.

```shell
packer plugins install github.com/hashicorp/vagrant
```

## Plugin Installation Workflow

Plugin installation via `packer plugins install` works similar to that of the `packer init` command, with the following
exceptions no `required_plugins` block required and can be used with both legacy JSON and HCL2 templates.

* [`packer plugins install`](/packer/docs/commands/plugins) will install plugins in the **last** directory
in the following numbered list.

1. `PACKER_PLUGINS_PATH` if set will be the sole location for installing plugins. All other
plugin directories will be ignored.
1. `PACKER_PLUGINS_PATH` if set will be the sole location for installing plugins. All other
plugin directories will be ignored.
1. `PACKER_CONFIG_DIR`\plugins on Windows systems, or `PACKER_CONFIG_DIR`/plugins on all other systems.


For manual installation of plugin binaries, without the `packer plugins` command, please continue reading.
</Tab>
<Tab heading="manually (multi-component plugin)">

The easiest way to manually install a plugin is to name it correctly, then place
it in the proper directory. To name a plugin correctly, make sure the binary is
Expand All @@ -241,7 +242,6 @@ The valid types for plugins are:
- `provisioner` - A provisioner to install software on images created by a
builder.


</Tab>
<Tab heading="manually (single-component plugin)">

Expand Down

0 comments on commit e40ec9c

Please sign in to comment.