Skip to content

Commit

Permalink
doc: add debug info (#196)
Browse files Browse the repository at this point in the history
* doc: add debug info

* move md file to .github

* gen doc
  • Loading branch information
Codelax authored Sep 17, 2024
1 parent 0a3432d commit aa8a03a
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 6 deletions.
16 changes: 16 additions & 0 deletions .github/DEBUG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Debug

The recommended way to debug a packer plugin is adding prints and running with logs enabled.
As written in [packer debug documentation](https://developer.hashicorp.com/packer/docs/debugging), you can use `PACKER_LOG=1` to enable verbose logging.

## Testing local build

To test a local build, you need to have the plugin in the same folder where you will run packer:


```
> ls
packer-plugin-scaleway build_scaleway.pkr.hcl
> PACKER_LOG=DEBUG SCW_DEBUG=1 packer build build_scaleway.pkr.hcl
...
```
6 changes: 3 additions & 3 deletions .web-docs/components/builder/scaleway/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -111,20 +111,20 @@ can also be supplied to override the typical auto-generated key:
It can also be specified via environment variable SCALEWAY_API_TOKEN. You
can see and generate tokens in the "Credentials"
section of the control panel.
Deprecated, use SecretKey instead
Deprecated: use SecretKey instead

- `organization_id` (string) - The organization id to use to identify your
organization. It can also be specified via environment variable
SCALEWAY_ORGANIZATION. Your organization id is available in the
"Account" section of the
control panel.
Previously named: api_access_key with environment variable: SCALEWAY_API_ACCESS_KEY
Deprecated, use ProjectID instead
Deprecated: use ProjectID instead

- `region` (string) - The name of the region to launch the server in (par1
or ams1). Consequently, this is the region where the snapshot will be
available.
Deprecated, use Zone instead
Deprecated: use Zone instead

<!-- End of code generated from the comments of the Config struct in builder/scaleway/config.go; -->

Expand Down
6 changes: 3 additions & 3 deletions docs-partials/builder/scaleway/Config-not-required.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -44,19 +44,19 @@
It can also be specified via environment variable SCALEWAY_API_TOKEN. You
can see and generate tokens in the "Credentials"
section of the control panel.
Deprecated, use SecretKey instead
Deprecated: use SecretKey instead

- `organization_id` (string) - The organization id to use to identify your
organization. It can also be specified via environment variable
SCALEWAY_ORGANIZATION. Your organization id is available in the
"Account" section of the
control panel.
Previously named: api_access_key with environment variable: SCALEWAY_API_ACCESS_KEY
Deprecated, use ProjectID instead
Deprecated: use ProjectID instead

- `region` (string) - The name of the region to launch the server in (par1
or ams1). Consequently, this is the region where the snapshot will be
available.
Deprecated, use Zone instead
Deprecated: use Zone instead

<!-- End of code generated from the comments of the Config struct in builder/scaleway/config.go; -->

0 comments on commit aa8a03a

Please sign in to comment.