diff --git a/cmd/struct-markdown/main.go b/cmd/struct-markdown/main.go index 545ed576f..d2514d3d2 100644 --- a/cmd/struct-markdown/main.go +++ b/cmd/struct-markdown/main.go @@ -105,10 +105,12 @@ func main() { } else { docs = strings.Join(camelcase.Split(field.Names[0].Name), " ") } + fieldType := string(b[field.Type.Pos()-1 : field.Type.End()-1]) + fieldType = strings.ReplaceAll(fieldType, "*", `\*`) field := Field{ Name: name, - Type: fmt.Sprintf("%s", b[field.Type.Pos()-1:field.Type.End()-1]), + Type: fieldType, Docs: docs, } if req, err := tags.Get("required"); err == nil && req.Value() == "true" { diff --git a/website/source/partials/builder/alicloud/ecs/_AlicloudDiskDevice-not-required.html.md b/website/source/partials/builder/alicloud/ecs/_AlicloudDiskDevice-not-required.html.md index eebbf129d..0dc63c5f2 100644 --- a/website/source/partials/builder/alicloud/ecs/_AlicloudDiskDevice-not-required.html.md +++ b/website/source/partials/builder/alicloud/ecs/_AlicloudDiskDevice-not-required.html.md @@ -30,7 +30,7 @@ - `disk_device` (string) - Device information of the related instance: such as /dev/xvdb It is null unless the Status is In_use. -- `disk_encrypted` (*bool) - Whether or not to encrypt the data disk. +- `disk_encrypted` (\*bool) - Whether or not to encrypt the data disk. If this option is set to true, the data disk will be encryped and corresponding snapshot in the target image will also be encrypted. By default, if this is an extra data disk, Packer will not encrypt the data disk. Otherwise, Packer will keep the encryption setting to what diff --git a/website/source/partials/builder/alicloud/ecs/_AlicloudImageConfig-not-required.html.md b/website/source/partials/builder/alicloud/ecs/_AlicloudImageConfig-not-required.html.md index b260446ac..68c7551e4 100644 --- a/website/source/partials/builder/alicloud/ecs/_AlicloudImageConfig-not-required.html.md +++ b/website/source/partials/builder/alicloud/ecs/_AlicloudImageConfig-not-required.html.md @@ -19,7 +19,7 @@ uppercase/lowercase letter or a Chinese character, and may contain numbers, _ or -. It cannot begin with http:// or https://. -- `image_encrypted` (*bool) - Whether or not to encrypt the target images, including those copied if image_copy_regions is specified. If this option +- `image_encrypted` (\*bool) - Whether or not to encrypt the target images, including those copied if image_copy_regions is specified. If this option is set to true, a temporary image will be created from the provisioned instance in the main region and an encrypted copy will be generated in the same region. By default, Packer will keep the encryption setting to what diff --git a/website/source/partials/builder/alicloud/ecs/_RunConfig-not-required.html.md b/website/source/partials/builder/alicloud/ecs/_RunConfig-not-required.html.md index e56e44e54..5c7b11d11 100644 --- a/website/source/partials/builder/alicloud/ecs/_RunConfig-not-required.html.md +++ b/website/source/partials/builder/alicloud/ecs/_RunConfig-not-required.html.md @@ -3,7 +3,7 @@ - `associate_public_ip_address` (bool) - Associate Public Ip Address - `zone_id` (string) - ID of the zone to which the disk belongs. -- `io_optimized` (*bool) - Whether an ECS instance is I/O optimized or not. If this option is not +- `io_optimized` (\*bool) - Whether an ECS instance is I/O optimized or not. If this option is not provided, the value will be determined by product API according to what `instance_type` is used. diff --git a/website/source/partials/builder/amazon/common/_AMIConfig-not-required.html.md b/website/source/partials/builder/amazon/common/_AMIConfig-not-required.html.md index 8031a650c..b6069f195 100644 --- a/website/source/partials/builder/amazon/common/_AMIConfig-not-required.html.md +++ b/website/source/partials/builder/amazon/common/_AMIConfig-not-required.html.md @@ -33,7 +33,7 @@ [template engine](/docs/templates/engine.html), see [Build template data](#build-template-data) for more information. -- `ena_support` (*bool) - Enable enhanced networking (ENA but not +- `ena_support` (\*bool) - Enable enhanced networking (ENA but not SriovNetSupport) on HVM-compatible AMIs. If set, add ec2:ModifyInstanceAttribute to your AWS IAM policy. If false, this will disable enhanced networking in the final AMI as opposed to passing the @@ -56,7 +56,7 @@ associated with AMIs, which have been deregistered by force_deregister. Default false. -- `encrypt_boot` (*bool) - Whether or not to encrypt the resulting AMI when +- `encrypt_boot` (\*bool) - Whether or not to encrypt the resulting AMI when copying a provisioned instance to an AMI. By default, Packer will keep the encryption setting to what it was in the source image. Setting false will result in an unencrypted image, and true will result in an encrypted one. diff --git a/website/source/partials/builder/amazon/common/_BlockDevice-not-required.html.md b/website/source/partials/builder/amazon/common/_BlockDevice-not-required.html.md index 617916a91..07fc63cac 100644 --- a/website/source/partials/builder/amazon/common/_BlockDevice-not-required.html.md +++ b/website/source/partials/builder/amazon/common/_BlockDevice-not-required.html.md @@ -8,7 +8,7 @@ - `device_name` (string) - The device name exposed to the instance (for example, /dev/sdh or xvdh). Required for every device in the block device mapping. -- `encrypted` (*bool) - Indicates whether or not to encrypt the volume. By default, Packer will +- `encrypted` (\*bool) - Indicates whether or not to encrypt the volume. By default, Packer will keep the encryption setting to what it was in the source image. Setting false will result in an unencrypted device, and true will result in an encrypted one. diff --git a/website/source/partials/builder/amazon/ebsvolume/_Config-not-required.html.md b/website/source/partials/builder/amazon/ebsvolume/_Config-not-required.html.md index 42e20bf6d..b008375aa 100644 --- a/website/source/partials/builder/amazon/ebsvolume/_Config-not-required.html.md +++ b/website/source/partials/builder/amazon/ebsvolume/_Config-not-required.html.md @@ -10,7 +10,7 @@ source instance. See the [BlockDevices](#block-devices-configuration) documentation for fields. -- `ena_support` (*bool) - Enable enhanced networking (ENA but not SriovNetSupport) on +- `ena_support` (\*bool) - Enable enhanced networking (ENA but not SriovNetSupport) on HVM-compatible AMIs. If set, add ec2:ModifyInstanceAttribute to your AWS IAM policy. If false, this will disable enhanced networking in the final AMI as opposed to passing the setting through unchanged from the source. diff --git a/website/source/partials/builder/azure/arm/_Config-not-required.html.md b/website/source/partials/builder/azure/arm/_Config-not-required.html.md index cdbab599a..af8816b87 100644 --- a/website/source/partials/builder/azure/arm/_Config-not-required.html.md +++ b/website/source/partials/builder/azure/arm/_Config-not-required.html.md @@ -104,7 +104,7 @@ region that supports [availability zones](https://docs.microsoft.com/en-us/azure/availability-zones/az-overview). -- `azure_tags` (map[string]*string) - the user can define up to 15 +- `azure_tags` (map[string]\*string) - the user can define up to 15 tags. Tag names cannot exceed 512 characters, and tag values cannot exceed 256 characters. Tags are applied to every resource deployed by a Packer build, i.e. Resource Group, VM, NIC, VNET, Public IP, KeyVault, etc. diff --git a/website/source/partials/builder/googlecompute/_Config-not-required.html.md b/website/source/partials/builder/googlecompute/_Config-not-required.html.md index 13aecab71..308cedd32 100644 --- a/website/source/partials/builder/googlecompute/_Config-not-required.html.md +++ b/website/source/partials/builder/googlecompute/_Config-not-required.html.md @@ -30,7 +30,7 @@ - `image_description` (string) - The description of the resulting image. -- `image_encryption_key` (*compute.CustomerEncryptionKey) - Image encryption key to apply to the created image. Possible values: +- `image_encryption_key` (\*compute.CustomerEncryptionKey) - Image encryption key to apply to the created image. Possible values: * kmsKeyName - The name of the encryption key that is stored in Google Cloud KMS. * RawKey: - A 256-bit customer-supplied encryption key, encodes in RFC 4648 base64. diff --git a/website/source/partials/builder/virtualbox/common/_VBoxVersionConfig-not-required.html.md b/website/source/partials/builder/virtualbox/common/_VBoxVersionConfig-not-required.html.md index e7f297bf3..46475fa29 100644 --- a/website/source/partials/builder/virtualbox/common/_VBoxVersionConfig-not-required.html.md +++ b/website/source/partials/builder/virtualbox/common/_VBoxVersionConfig-not-required.html.md @@ -1,7 +1,7 @@ - `communicator` (string) - Communicator -- `virtualbox_version_file` (*string) - The path within the virtual machine to +- `virtualbox_version_file` (\*string) - The path within the virtual machine to upload a file that contains the VirtualBox version that was used to create the machine. This information can be useful for provisioning. By default this is .vbox_version, which will generally be upload it into the