From a95586c54facc60447ac8cb95fb8a0b58049675a Mon Sep 17 00:00:00 2001 From: Christophe Jauffret Date: Thu, 28 Jul 2022 08:20:35 +0200 Subject: [PATCH] fix doc and remove scaffold --- README.md | 16 ++++- docs/README.md | 78 --------------------- docs/builders/builder-name.mdx | 63 ----------------- docs/datasources/datasource-name.mdx | 78 --------------------- docs/post-processors/postprocessor-name.mdx | 59 ---------------- docs/provisioners/provisioner-name.mdx | 62 ---------------- 6 files changed, 15 insertions(+), 341 deletions(-) delete mode 100644 docs/README.md delete mode 100644 docs/builders/builder-name.mdx delete mode 100644 docs/datasources/datasource-name.mdx delete mode 100644 docs/post-processors/postprocessor-name.mdx delete mode 100644 docs/provisioners/provisioner-name.mdx diff --git a/README.md b/README.md index 3598bd2..9412e65 100644 --- a/README.md +++ b/README.md @@ -32,13 +32,27 @@ Then, run [`packer init`](https://www.packer.io/docs/commands/init). packer { required_plugins { nutanix = { - version = ">= 0.1.0" + version = ">= 0.1.3" source = "github.com/nutanix-cloud-native/nutanix" } } } ``` +#### Manual installation + +You can find pre-built binary releases of the plugin [here](https://github.com/nutanix-cloud-native/packer-plugin-nutanix/releases). +Once you have downloaded the latest archive corresponding to your target OS, +uncompress it to retrieve the plugin binary file corresponding to your platform. +To install the plugin, please follow the official Packer documentation on [installing a plugin](https://www.packer.io/docs/extending/plugins/#installing-plugins). + + +#### From Source + +If you prefer to build the plugin from its source code, clone the GitHub repository locally and run the command `make build` from the root directory. +Upon successful compilation, a `packer-plugin-nutanix` plugin binary file can be found in the root directory. +To install the compiled plugin, please follow the official Packer documentation on [installing a plugin](https://www.packer.io/docs/extending/plugins/#installing-plugins). + ### Configuration For more information on how to configure the plugin, please find some examples in the [`example/`](example) directory. diff --git a/docs/README.md b/docs/README.md deleted file mode 100644 index 869c335..0000000 --- a/docs/README.md +++ /dev/null @@ -1,78 +0,0 @@ -# Scaffolding Plugins - - - -## Installation - -### Using pre-built releases - -#### Using the `packer init` command - -Starting from version 1.7, Packer supports a new `packer init` command allowing -automatic installation of Packer plugins. Read the -[Packer documentation](https://www.packer.io/docs/commands/init) for more information. - -To install this plugin, copy and paste this code into your Packer configuration . -Then, run [`packer init`](https://www.packer.io/docs/commands/init). - -```hcl -packer { - required_plugins { - name = { - version = ">= 0.0.1" - source = "github.com/hashicorp/name" - } - } -} -``` - -#### Manual installation - -You can find pre-built binary releases of the plugin [here](https://github.com/hashicorp/packer-plugin-name/releases). -Once you have downloaded the latest archive corresponding to your target OS, -uncompress it to retrieve the plugin binary file corresponding to your platform. -To install the plugin, please follow the Packer documentation on -[installing a plugin](https://www.packer.io/docs/extending/plugins/#installing-plugins). - - -#### From Source - -If you prefer to build the plugin from its source code, clone the GitHub -repository locally and run the command `go build` from the root -directory. Upon successful compilation, a `packer-plugin-name` plugin -binary file can be found in the root directory. -To install the compiled plugin, please follow the official Packer documentation -on [installing a plugin](https://www.packer.io/docs/extending/plugins/#installing-plugins). - - -## Plugin Contents - -The Scaffolding plugin is intended as a starting point for creating Packer plugins, containing: - -### Builders - -- [builder](/docs/builders/builder-name.mdx) - The scaffolding builder is used to create endless Packer - plugins using a consistent plugin structure. - -### Provisioners - -- [provisioner](/docs/provisioners/provisioner-name.mdx) - The scaffolding provisioner is used to provisioner - Packer builds. - -### Post-processors - -- [post-processor](/docs/post-processors/postprocessor-name.mdx) - The scaffolding post-processor is used to - export scaffolding builds. - -### Data Sources - -- [data source](/docs/datasources/datasource-name.mdx) - The scaffolding data source is used to - export scaffolding data. - diff --git a/docs/builders/builder-name.mdx b/docs/builders/builder-name.mdx deleted file mode 100644 index 73f33f9..0000000 --- a/docs/builders/builder-name.mdx +++ /dev/null @@ -1,63 +0,0 @@ ---- -description: > - The scaffolding builder is used to create endless Packer plugins using - a consistent plugin structure. -page_title: Scaffolding - Builders -nav_title: Scaffolding ---- - -# Scaffolding - -Type: `scaffolding` - - - -The scaffolding builder is used to create endless Packer plugins using -a consistent plugin structure. - - - - -### Required - -- `mock` (string) - The name of the mock to use for the Scaffolding API. - - - - -### Optional - -- `mock_api_url` (string) - The Scaffolding API endpoint to connect to. - Defaults to https://example.com - - - - -### Example Usage - - -```hcl - source "scaffolding" "example" { - mock = "bird" - } - - build { - sources = ["source.scaffolding.example"] - } -``` - - diff --git a/docs/datasources/datasource-name.mdx b/docs/datasources/datasource-name.mdx deleted file mode 100644 index 66dcb2f..0000000 --- a/docs/datasources/datasource-name.mdx +++ /dev/null @@ -1,78 +0,0 @@ ---- -description: > - The scaffolding data source is used to create endless Packer plugins using - a consistent plugin structure. -page_title: Scaffolding - Data Sources -nav_title: Scaffolding ---- - -# Scaffolding - -Type: `scaffolding` - - - -The scaffolding data source is used to create endless Packer plugins using -a consistent plugin structure. - - - - -### Required - -- `mock` (string) - The name of the mock to use for the Scaffolding API. - - - - -### Optional - -- `mock_api_url` (string) - The Scaffolding API endpoint to connect to. - Defaults to https://example.com - - - - - -### OutPut - -- `foo` (string) - The Scaffolding output foo value. -- `bar` (string) - The Scaffolding output bar value. - - - -### Example Usage - - -```hcl -data "scaffolding" "example" { - mock = "bird" - } - source "scaffolding" "example" { - mock = data.scaffolding.example.foo - } - - build { - sources = ["source.scaffolding.example"] - } -``` - - diff --git a/docs/post-processors/postprocessor-name.mdx b/docs/post-processors/postprocessor-name.mdx deleted file mode 100644 index df6c03b..0000000 --- a/docs/post-processors/postprocessor-name.mdx +++ /dev/null @@ -1,59 +0,0 @@ ---- -description: > - The scaffolding post-processor is used to export Packer Scaffolding builds. -page_title: Scaffolding - Post-Processors -nav_title: Scaffolding ---- - -# Scaffolding - -Type: `scaffolding` - - - -The scaffolding post-processor is used to export Packer Scaffolding builds. - - - - -### Required - -- `mock` (string) - The output path where to save exported build to. - - - -### Optional - - - -### Example Usage - - -```hcl - source "scaffolding" "example" { - mock = "jay" - } - - build { - sources = ["source.scaffolding.example"] - - post-processor "scaffolding" { - mock = "builds/scaffolding.box" - } - } -``` - diff --git a/docs/provisioners/provisioner-name.mdx b/docs/provisioners/provisioner-name.mdx deleted file mode 100644 index 34930df..0000000 --- a/docs/provisioners/provisioner-name.mdx +++ /dev/null @@ -1,62 +0,0 @@ ---- -description: > - The scaffolding provisioner is used to provisioner Packer builds. -page_title: Scaffolding - Provisioners -nav_title: Scaffolding ---- - -# Scaffolding - -Type: `scaffolding` - - - -The scaffolding provisioner is used to provisioner Packer builds. - - - - -### Required - -- `mock` (string) - The name of the mock string to display. - - - - -### Optional - - - -### Example Usage - - -```hcl - source "null" "example" { - communicator = "none" - } - - build { - source "null.example" { - name = "jay" - } - - provisioner "scaffolding" { - mock = "mocking ${source.name}" - } - } -``` -