Commit Graph
21 Commits
Author SHA1 Message Date
Lucas Bajolet 8d4a9d66ab config: rm mono-component support from config file (#12998)
The global `PACKER_CONFIG` config file was already deprecated from
Packer core, but now with 1.11.0 since we remove support for
mono-component plugins, we are also removing the capability for that
config file to declare them.

Instead of silently not using those, Packer will now error with a
message pointing to the web docs on how to manage their plugins with the
updated workflows for Packer 1.11 and above.
2024-05-30 14:25:08 +02:00
guoguangwu 7eb6a45cd4 chore: remove refs to deprecated io/ioutil
Signed-off-by: guoguangwu <[email protected]>
2023-09-26 11:13:31 -04:00
hashicorp-copywrite[bot] 19055df3ec [COMPLIANCE] License changes (#12568)
* Updating the license from MPL to Business Source License

Going forward, this project will be licensed under the Business Source License v1.1. Please see our blog post for more details at https://hashi.co/bsl-blog, FAQ at https://hashi.co/license-faq, and details of the license at www.hashicorp.com/bsl.

* Update copyright file headers to BUSL-1.1

---------

Co-authored-by: hashicorp-copywrite[bot] <110428419+hashicorp-copywrite[bot]@users.noreply.github.com>
2023-08-10 15:53:29 -07:00
Wilken Rivera eca75a6847 Run make fmt to fix checks 2023-04-27 15:17:31 -04:00
hashicorp-copywrite[bot] b7df3ca36f [COMPLIANCE] Add Copyright and License Headers (#12254)
Co-authored-by: hashicorp-copywrite[bot] <110428419+hashicorp-copywrite[bot]@users.noreply.github.com>
2023-03-02 15:37:05 -05:00
Adrien Delorme ed091163be HCL2 Parse packer.required_plugins block + packer init (#10304)
This adds the new `required_plugins` block to be nested under the packer block.

Example:
```hcl
packer {
  required_plugins {
    aws = {
      version = ">= 2.7.0"
      source = "azr/aws"
    }
    azure = ">= 2.7.0"
  }
}
```

For example on darwin_amd64 Packer will install those under :
* "${PACKER_HOME_DIR}/plugin/github.com/azr/amazon/packer-plugin-amazon_2.7.0_x5.0_darwin_amd64"
* "${PACKER_HOME_DIR}/plugin/github.com/hashicorp/azure/packer-plugin-azure_2.7.0_x5.0_darwin_amd64_x5"

+ docs
+ tests
2021-02-02 18:05:04 +01:00
Adrien Delorme 52d2d7fe5f Copy MapOf... plugin types back into Packer core (#10466)
* move maps of plugins back in core

* go mod vendor

* more fixes

* fix imports

* Update core_test.go

* fix build

* more fixes

* more fixes

* up vendors after fixing sdk

* Update post_processor_mock.hcl2spec.go

* Leave implementatino of MapOf in the sdk for plugi tests

Other wise use the interface

* go mod tidy

* add MapOfDatasource type too
2021-01-13 12:14:06 +01:00
Megan Marsh 88b7b0e14a remove sdk 2020-12-17 13:29:25 -08:00
Megan Marsh d767c69ed3 rebase and fix conflicts
fix tests
2020-12-03 10:26:48 -08:00
Megan Marsh 5576bb5caa move packer config constants next to the packer config 2020-12-03 10:17:35 -08:00
sylviamoss 2c10c21445 move plugin discover tests to plugin pkg 2020-12-03 17:07:24 +01:00
Megan Marsh 817957fe4f Merge pull request #8616 from hashicorp/packer-plugin-path
add PACKER_PLUGIN_PATH for plugin discovery
2020-01-28 12:09:55 -08:00
Megan Marsh 6eda9504c9 remove second dir 2020-01-27 16:20:59 -08:00
Megan Marsh 69e7d39fd3 add some tests for packer_plugin_path 2020-01-27 16:19:03 -08:00
nywilken 93640b0854 Update test case for Windows 2020-01-17 14:03:35 -05:00
nywilken c93a076698 config: Update loading of packerconfig to only log when a plugin is loaded
Before this change loading of a packerconfig would display `loaded
plugin ...` for any plugin defined in the packerconfig - even if it
didn't exist on disk. This change updates how plugins defined in
packerconfig are loaded to ensure that only successfully loaded plugins
get the lovely message `loaded plugin ...`. For any plugin that fails to
load Packer will log that it failed to load the plugin and continue
processing any other defined plugins.

* Add a test to ensure loadSingleComponent errors when plugin does not
exists
2020-01-17 13:33:51 -05:00
nywilken fb76323c4d config: Fix loading external plugins from a packerconfig
This change introduces a loadExternalComponent which can be used for
loading a single plugin path. The function is a combination of
the discoverSingle and discoverExternalComponents functions.
2020-01-15 13:08:30 -05:00
Mitchell Hashimoto 7edfb66293 Clean up the configuration loading mechanisms, ditch toml 2013-06-08 22:26:49 -07:00
Mitchell Hashimoto cd5cecfe89 app: support merging configs 2013-05-08 20:40:04 -07:00
Mitchell Hashimoto 085533c17f packer: Test to ensure the default config can parse 2013-05-08 18:14:40 -07:00
Mitchell Hashimoto 5f8330ecc2 Parse/load configs 2013-05-08 18:13:15 -07:00