Commit Graph

722 Commits (8ce3aae2f7f16c85a5465f922dcafe54090ed3e2)

Author SHA1 Message Date
Megan Marsh 88b7b0e14a remove sdk
5 years ago
Wilken Rivera 4e58987026
command/fmt: Ensure all variable files ending in `.pkrvars.hcl` get formatted (#10377)
5 years ago
Megan Marsh 39ab646236
move plugin and rpc code into sdk; other minor tweaks (#10359)
5 years ago
Megan Marsh 5576bb5caa move packer config constants next to the packer config
5 years ago
Megan Marsh b69d69095e move postprocessor to sdk, fix generation code
5 years ago
Megan Marsh be5763ec41 move provisioner interface into sdk
5 years ago
Megan Marsh ada91b24e9 extract builder interface to sdk
5 years ago
Megan Marsh d5971ca25e fix tests by moving mock hooks and communicators, and BasicUi definition, into SDK
5 years ago
Megan Marsh 56a45b04ab Move hook and communicator definitions to packer-plugin-sdk
5 years ago
Megan Marsh 14bdb9516c move Artifact and artifact mock to the sdk
5 years ago
Megan Marsh 001886670d move Ui definition into the packer plugin sdk.
5 years ago
Adrien Delorme 73b7499811
HCL2: version block: test validation & document version/availability (#10298)
5 years ago
Megan Marsh 6a1a22151c move the various flag packages from helper to command, since command is the only package that uses them.
5 years ago
Megan Marsh efe11da4a3
Merge pull request #10254 from hashicorp/plugin-sdk-2
5 years ago
Megan Marsh 3e54e9ea80
Merge pull request #10235 from hashicorp/refactor_version_code
5 years ago
Megan Marsh 6402362018 create packer-plugin-sdk directory and begin moving the relevant folders into it.
5 years ago
Adrien Delorme f44e912072
Update hcl2upgrade command to update env calls + tests (#10244)
5 years ago
Wilken Rivera acabc1c1aa
Add packer fmt command (#10225)
5 years ago
Adrien Delorme deba1484ff
HCL2: allow calling env as input var default value (#10240)
5 years ago
Adrien Delorme 17ec88246f
hcl2_upgrade update (#10221)
5 years ago
Megan Marsh bc85854a53 refactor packer version out of hcltemplate code.
5 years ago
Adrien Delorme 6dd06fad14 add command/ tests
6 years ago
Adrien Delorme 4bc16455b4
HCL2: add a packer block with a required_version input setting (#10149)
6 years ago
Megan Marsh fc619dc977
Merge pull request #9626 from featheredtoast/add-proxmox-vm-clone
6 years ago
Megan Marsh 66b81d9bee
add build.name to hcl code (#10114)
6 years ago
Megan Marsh 2cdc052d7c
Merge pull request #10097 from hashicorp/more_hcl_docs
6 years ago
Megan Marsh 00cc425b84 docs tweaks
6 years ago
Peter Willis f1b57b1e66
Fix typos
6 years ago
Peter Willis a81811663a
Fix typos
6 years ago
Jeff Wong 0f12414126
Merge branch 'master' into add-proxmox-vm-clone
6 years ago
James Cradock 153d4111fa
Fix typo in build argument description (#10066)
6 years ago
Jeff Wong a140c13943
[proxmox] add proxmox builder alias
6 years ago
Adrien Delorme 3e0633fc20 scripts/generate-plugins.go: ignore "common" packages
6 years ago
Adrien Delorme b2be255057 Merge remote-tracking branch 'origin/master' into pr/featheredtoast/9626-1
6 years ago
Adrien Delorme fcf16315a3 add tests
6 years ago
Adrien Delorme 3d7ab9ea43 add an hcl2-json test
6 years ago
Calle Pettersson 905869308d Split proxmox builder into a common part and iso/clone builders
6 years ago
Adrien Delorme efd69aea2a
console: allow to use console when there are untyped vars (#9864)
6 years ago
Adrien Delorme a70164f489
HCL2: when the type of a variable is not known evaluate setting as a litteral. (#9863)
6 years ago
Adrien Delorme a25f057984 add tests for unknown values
6 years ago
Adrien Delorme 161879b98a test unknown variables and locals
6 years ago
Adrien Delorme 652878059c inspect command: ignore init errors as some value can be unset
6 years ago
Adrien Delorme 91c5a4613c HCL2 inspect remove debug values
6 years ago
Wilken Rivera 67cd123d1c
Merge pull request #9834 from hashicorp/azr-fix-hcl2_upgrade_random_generate
6 years ago
Wilken Rivera 0e2a3e1058 command/hcl2_upgrade: Update description text for command
6 years ago
Adrien Delorme 0f00709fb6 hcl2_upgrade: fix a case where the generated type is wrong
6 years ago
Adrien Delorme 5ba134ac5b
JSON to HCL2 (minimal best-effort) transpiler (#9659)
6 years ago
sylviamoss 39a8dee4ea add tests and update override example
6 years ago
Chris Gilmer 6e918c4bd3
Update test for builder output
6 years ago
Chris Gilmer 04f952a2f4
Pretty print build durations
6 years ago
Adrien Delorme c7b35dd6bc
HCL2: add post-processors block to run multiple post-processor after a build (#9638)
6 years ago
Adrien Delorme 44616d3bff
refactor initialization out from packer configs + tests (#9627)
6 years ago
Adrien Delorme 125178d943
core: Decode: when in HCL2 decoding mode; reset the whole struct before preparing it. (#9622)
6 years ago
Gennady Lipenkov 553d203e68 Add yandex-import post-processor
6 years ago
Adrien Delorme b0238e6f4a Update build_windows_test.go
6 years ago
Adrien Delorme d84d956e36 add language coment !
6 years ago
Adrien Delorme a15ad19411 test builds can be 'excepted'
6 years ago
Adrien Delorme c1c8b8d22a complete -> recipes
6 years ago
Adrien Delorme 10e5d952ac unquote 'cooking...'
6 years ago
Adrien Delorme 0475b0529d tests: fix line endings in windows
6 years ago
Adrien Delorme 0deaa5d2a5 add a complete tests for builder variables + only/except
6 years ago
Adrien Delorme 7969b690de Revert "Share build info with Provisioner and Post-Processor via HCL2 variables (#9444)"
6 years ago
Adrien Delorme 3d371a2d5d
Add complete HCL2 examples + allow to name a singular build.source blocks (#9490)
6 years ago
Sylvia Moss 99046c9178
Share build info with Provisioner and Post-Processor via HCL2 variables (#9444)
6 years ago
Adrien Delorme 6f4d79799b add thorough test
6 years ago
Adrien Delorme dabcc866e5 add another inspect test
6 years ago
Adrien Delorme f98576b19e add a basic test for the inspect command
6 years ago
Adrien Delorme 51d02f8c2d hcl2: inspect command
6 years ago
Adrien Delorme fb337f8867
hcl work on only/except (#9454)
6 years ago
Megan Marsh 42e98f15ae make sure the no-op progress bar gets used for machine readable uis
6 years ago
Moss 4f26534072 add on-error flag option to run cleanup provisioner
6 years ago
Moss daaeccd8b0 Skip consecutives post-processors
6 years ago
Moss bfb9df0039 fix except flag for JSON and HCL2
6 years ago
Wilken Rivera f672f5bd9b command/validate: Add support for HCL2 configuration files
6 years ago
Adrien Delorme bac9c74447
packer console for HCL2 (#9359)
6 years ago
Megan Marsh 3dc4ba2d68
Json vs HCL2 parity refactor (#9301)
6 years ago
Megan Marsh ee5635722b enable force, debug, and on-error for hcl2 builds
6 years ago
Megan Marsh 533fbc1381
Merge pull request #9139 from hashicorp/hcl2_commands_refactor
6 years ago
Adrien Delorme 2f26168adc ConsoleCommand.ParseArgs: don't fail if no buildfile was passed
6 years ago
Adrien Delorme 52b2151b21 go generate ./packer
6 years ago
Adrien Delorme 466358a13e Delete command.go
6 years ago
Adrien Delorme 7ca0a80a86 remove Ui from command.MetaArgs
6 years ago
Adrien Delorme 77297e49e9 Update cli.go
6 years ago
Adrien Delorme 49c2a8cb17 update fix command with new synthax
6 years ago
Adrien Delorme 14f18f4236 dont catch signals in console, as it seems unecessary for now
6 years ago
Adrien Delorme 22a36ef97a Move vars from Meta to cla args; this forces us to use it in GetConfigFromJSON which in turn forces us into updating console and validate
6 years ago
Adrien Delorme 534e98c4ef pass Meta command line arguments around
6 years ago
Adrien Delorme b35ec44d06 Update build.go
6 years ago
Adrien Delorme e6aac8cd6f Update build_test.go
6 years ago
Adrien Delorme efcc6af06c fix tests
6 years ago
Adrien Delorme a93a45e4d3 more fixes to refactor
6 years ago
Adrien Delorme 42a05e1e80 more refactoring
6 years ago
Adrien Delorme 2ef758763f Update build_cancellation_test.go
6 years ago
Adrien Delorme 2f63e4e79d refactor term interrupts & have RunContext take a conf struct now
6 years ago
Adrien Delorme 532a69c968 Update command.go
6 years ago
Adrien Delorme 5290beb23e Update cli.go
6 years ago
Adrien Delorme a5ab87ca44 add scaffolding for the new packer command layout
6 years ago
Megan Marsh 6a682aca2e
Merge pull request #9124 from GennadySpb/yandex-export-post-processor
6 years ago
nqb be08eddd8d
remove useless comment
6 years ago
Adrien Delorme 4047113746 Update build.go
6 years ago
Adrien Delorme 2c556ed8c0 remove clarified comment
6 years ago
Adrien Delorme c71a792186 simplify/refactor core for build & validate
6 years ago
Adrien Delorme 7aaee62970 command/build: don't reset error code in case an error hapened
6 years ago
Adrien Delorme 5c2b8da63b get builds from PackerConfig instead of parser
6 years ago
Tom Dyas c0a6623ea2
teach HCL mode builds to honor -only and -except options (#8947)
6 years ago
Gennady Lipenkov d5a6781fb7 Add new 'yandex-export' post-processor
6 years ago
Megan Marsh 217dcbb97f golang 1.14 doesn't like calling NewFile on existing files. Port solution over from Terraform
6 years ago
Adrien Delorme 2af40c762b
HCL2: pass on builder type and name (#8956)
6 years ago
Jeff Escalante 9165be87da
packer.io prefix removal, html extension remove for in-code errors
6 years ago
Vaijanath Angadihiremath fd21b669db Fixing the linting errors now required for merging
6 years ago
Vaijanath Angadihiremath c815a5df67 Fixing the Make Ci errors
6 years ago
Vaijanath Angadihiremath 645cdf1a59 Updating the modules to include update to autorest 12.4
6 years ago
Megan Marsh f5c98a7601
make sure cli vars supercede var files (#8964)
6 years ago
Adrien Delorme d068430abf
make sure locals are evaluated only once variables are + test this (#8918)
6 years ago
Adrien Delorme ad8dafa3bd
HCL: add tests and fixes around var-file and var args (#8914)
6 years ago
Adrien Delorme 88297c796d Merge branch 'master' into hcl2_singular_blocks
6 years ago
Adrien Delorme 94a1f0bcb6 go fmt
6 years ago
Adrien Delorme 0a46bb9525 more precise docs
6 years ago
Adrien Delorme b5e8750f5f Change key/value to name/value to remain consistent with Terraform
6 years ago
Adrien Delorme c8300b620a allow to use hcl files as var files in HCL mode
6 years ago
Adrien Delorme d2964d59e9 document that the `-var-file` option still expects JSON files for now
6 years ago
Wilken Rivera 9ec8b67392
Add golangci-lint to project (#8686)
6 years ago
Sylvia Moss 23fa3107a3
Render variables one time on prepare method (#8727)
6 years ago
Adrien Delorme 193dad46e6
Hcl2 input variables, local variables and functions (#8588)
6 years ago
Megan Marsh 073eda76aa remove extraneous files from when vsphere builder was a plugin, and move README into packer website as separated docs for vsphere-clone and vsphere-iso. Move option descriptions into struct code, and generate documentation directly from those structs as we do inside of the other builders
6 years ago
Megan Marsh 5bacd37014 fix pps
6 years ago
Megan Marsh dca2c03cdb
Merge pull request #7866 from hashicorp/sharing_info
6 years ago
nywilken 3d56f8ac80 command/build: Fix URL to HCL2 syntax guide
6 years ago
Adrien Delorme 4b7132c87c Merge remote-tracking branch 'origin/master' into sharing_info
6 years ago
Adrien Delorme 0785c2f6fc
build using HCL2 (#8423)
6 years ago
Megan Marsh 0f6d1beccf add an extra string array to the Prepare() return values in the builder interfaces; this sets up the ability for builders to give the provisioners custom user-accessible build-time variables.
6 years ago
Moss a0329ef196 Simplify testing template
6 years ago
Moss 7466c4fdca Return exit code 1 when builder type is not found
6 years ago
mingsheng.su 2c513fce64 update ucloud packer
7 years ago
mingsheng.su 61f9d3a9fe add ucloud import
7 years ago
Paul Meyer 7297d74c98 Add azure-chroot builder plugin
7 years ago
Megan Marsh 59efa0faee rename option to error-cleanup-privisoner, which I think is clearer
7 years ago
Megan Marsh 0683bc409b add test for error-cleanup provisioner, and fix tests by fixing null builder to use an actual none communicator instead of skipping communicator generation altogether
7 years ago
Megan Marsh 6688f436dd
Merge pull request #7960 from guidodobboletta/master
7 years ago
xiaohan.liang f4fc9dd09a Rewrite all files, remove sensitive information
7 years ago
Guido Dobboletta e79d62d006 Fix text
7 years ago
Thomas Meckel d3202497ae First working version of virtualbox/vm builder
7 years ago
Thomas Meckel 2a531f8ad6 Merged changes from local branch
7 years ago
Brendan Devenney 2b16b5cae4
Move fixer test to fix package
7 years ago
Brendan Devenney 6520814a6c
Ensure help output is consistently formatted
7 years ago
Brendan Devenney 75d8d7fce5
Update and futureproof fix command usage
7 years ago
Brendan Devenney 91b7d8c572
Add test to ensure all fixers are enabled
7 years ago
Brendan Devenney 9f0bc29db5
Test that Fixers and FixerOrder are equal length
7 years ago
Marin Salinas 80dadaf3f1 feature: add bsuvolume builder and acceptance test
7 years ago
Marin Salinas 0c47ee55e6 feature: add chroot builder structure
7 years ago
Marin Salinas c4e69d3169 wip: add bsu plugin acc testing
7 years ago
Marin Salinas 1281f28f6d add prevalidate step
7 years ago
Marc Falzon 00c2df24df Add Exoscale Import post-processor
7 years ago
mingsheng.su 6109ad79a3
Merge branch 'master' into feature/ucloud_builder
7 years ago
Adrien Delorme 5efab58ed8 allow to have timestamped colorless ui messages
7 years ago
mingsheng.su d1b9ad90c8 Merge remote-tracking branch 'origin' into feature/ucloud_builder
7 years ago
mingsheng.su c8bab9b382 add ucloud packer
7 years ago
Megan Marsh f7bf80724c document what a REPL is
7 years ago
Megan Marsh 53a5e90d78
Update command/console.go
7 years ago
Megan Marsh 7cce3157a8
Update command/console.go
7 years ago
Megan Marsh 668e92f2ca add docs and the option to list variables from inside the console
7 years ago
Megan Marsh df916e805e borrow wrappedreadline workarounds from terraform and implement a similar check for piped commands; this makes the cli experience much cleaner
7 years ago
Megan Marsh b8ac1a800d implement a packer console analogous to the terraform console
7 years ago
Adrien Delorme cb2d89af6f simplify path parsing by making at string instead of an array + add tests
7 years ago
Adrien Delorme a4b8570991 refactor arg parsing into it's own cfg maker & test it
7 years ago
Adrien Delorme 7e8c42d243 BuildCommand: put config in a local struct
7 years ago
Adrien Delorme cdbb742496 add more cancellation tests
7 years ago
Adrien Delorme 73a55631c4 fix testfile call
7 years ago
Adrien Delorme 2890687b2b fix race condition in BuildCommand
7 years ago
Adrien Delorme af15ed3583 nil signals are probably just a cancellation in disguise
7 years ago
Adrien Delorme 583d93790f add tests for cancellation while building
7 years ago
Adrien Delorme dd2785ff08 BuildCommand.Run: avoid triggering a cancellation on termination
7 years ago
Adrien Delorme 0094d2878c Build: move BuildCommand.Run into a RunContext command to allow testing for cancellation, put cancellation in `Run`
7 years ago
Adrien Delorme a2cc2532ea add TestBuildParallel_Timeout to test errors on parallel builds
7 years ago
Adrien Delorme d40d3eca88 swap semaquire and wg.Add to avoid a deadlock
7 years ago
Adrien Delorme 263f318e82 be true to docs
7 years ago
Adrien Delorme 1dca416f87 move the semacquire to the main build loop so that the build order is kept
7 years ago
Adrien Delorme 852af993e6 BuildParallel: test with 3 parallel builds
7 years ago
Adrien Delorme 9281fada2d prevent a breaking change so that we can merge the `-parallel-builds` option first.
7 years ago
Adrien Delorme 14486003a1 fix test to be race free
7 years ago
Adrien Delorme c1527d9b47 fix text
7 years ago
Adrien Delorme ae71a81c1e Merge remote-tracking branch 'origin/master' into pr/7501
7 years ago
Brett Wandel aaf56ffd26 added: testing
7 years ago
Brett Wandel 76b5c1995f fixed: small changes to cancellation on ctrl-c
7 years ago
Marques Johansson 99987c2d56 Add Linode Images builder
7 years ago
Adrien Delorme 97f2914c6a
Merge pull request #7484 from yandex-cloud/yandex-cloud-builder
7 years ago
Brett Wandel 92e75f838a added the ability to limit number of builds running in parallel
7 years ago
Adrien Delorme d2f036ec44 Revert "Revert "Merge pull request #7391 from carlpett/proxmox-builder""
7 years ago
Gennady Lipenkov 8f53ca5e5e Add 'yandex' plugin as Builder
7 years ago
Adrien Delorme 032527ecfe Revert "Merge pull request #7391 from carlpett/proxmox-builder"
7 years ago
Adrien Delorme 0b4ada9690 make sleep provisioner available to packer
7 years ago
Adrien Delorme d7b1b597a7 test provisionning timeout
7 years ago
Adrien Delorme a81abd297b Merge remote-tracking branch 'origin/master' into context_provisioner
7 years ago
Calle Pettersson 9f8fc37fde Implement Proxmox builder
7 years ago
Megan Marsh 217a93fc30 fix build_test.go on windows. This code needs to not be run in parallel, or else there can be race conditions with the post-processors all trying to access the same file at once. Additionally, I changed the test template itself so that it is valid code on either bash or cmd. Finally, I found and fixed a small bug in naming the file extensions in shell local inline scripts.
7 years ago
Adrien Delorme a4bf94dd3c change Builder to be passed a context for cancellation
7 years ago
Adrien Delorme 045f2f41bd display received signal in debug mode
7 years ago
Adrien Delorme 9f82b75e57 Use the hashicorp/go-getter to download files
7 years ago
Andrew Widdersheim a5b753820c
Fix build commands -except help message
7 years ago
Megan Marsh b8510f35fc
Merge pull request #7330 from hashicorp/except_post_processor_tests
7 years ago
Miłosz Smółka 94a7a07c87 Merge branch 'master' into hyperone
7 years ago
Adrien Delorme 7e2d86731e tests: add a post-processor that creates an unnamed.txt file
7 years ago
Adrien Delorme de336ef15e TestBuildOnlyFileMultipleFlags: check that tomato.txt is not created
7 years ago
Adrien Delorme b04b8b3857 test building with `-except=""`
7 years ago
Megan Marsh 75f574bd4b
Merge pull request #7221 from hashicorp/vagrant_builder
7 years ago
Megan Marsh be21850e32
Merge pull request #7060 from andrewsomething/do-post-processor
7 years ago
xinau c207451f7e Merge branch 'master' of https://github.com/hashicorp/packer into packer-provisioner-inspec
7 years ago
Miłosz Smółka 228829139b Merge branch 'master' into hyperone
7 years ago
Megan Marsh ad21367b21 vagrant builder
7 years ago
Adrien Delorme 8621949e01 make generate
7 years ago
Adrien Delorme dd3e2c255c respect a 'only' defined in a post-processor
7 years ago
Adrien Delorme 074a74ec38 make sure 'only' completely ignores post-processor
7 years ago
Miłosz Smółka be30415395 Add HyperOne builder
7 years ago
xinau f5b13e3cb5 added inspec.io provisioner
7 years ago
Adrien Delorme 58245f2557 break a chain of post-processors when one is skipped & make `-only`
7 years ago
Adrien Delorme 61ade0e127 allow to use --only with post-processors
7 years ago
Adrien Delorme 4bf3cd44fc allow to skip a post processor
7 years ago
Adrien Delorme 905db043c4 command.TestBuildOnlyFileCommaFlags: create some files using post processors
7 years ago
Adrien Delorme 7655d2efb2
Add tencent cloud builder (#7135 & #6839)
7 years ago
Megan Marsh 98e933ca54 make packer inspect not print sensitive variables.
7 years ago
Andrew Starr-Bochicchio c0c5c6afac Add DigitalOcean post-processor.
7 years ago
Megan Marsh ba25e68fe0 add a new breakpoint provisioner
7 years ago
Megan Marsh c5b6eff691
Merge pull request #6871 from LKaemmerling/master
8 years ago
Lukas Kämmerling 270110767c
Add hcloud Builder
8 years ago
Josh Soref 66738ccaf4 Try to make help more consistent
8 years ago
Adrien Delorme 626a3cc2a4 have -timestamp-ui match what's in doc
8 years ago
Ashley Lowde 2884f6fab6 improve formatting and documentation for PR#6784
8 years ago
Ashley Lowde 12496e3702 add optional timestamps to build log
8 years ago
Matthew Hooker 8a7d43dd44
bug fix and add test
8 years ago
Megan Marsh cb35829f80
Merge pull request #6411 from jmartin-r7/esxi_compact
8 years ago
Oleg Butuzov 079b317b62 Misaligned help entries
8 years ago
Jeffrey Martin e8f04c34a3
add vmware-compaction fixer help
8 years ago
Megan Marsh c5b346b07b
Merge pull request #6393 from DanHam/fix-hyperv-export
8 years ago
Matthew Hooker ddf23a2c46
Complete Atlas deprecation.
8 years ago
Matthew Hooker 9bb0681586
Merge pull request #6423 from hashicorp/fix5513
8 years ago
DanHam c8f54d5291
Fixer and tests to convert 'clone_from_vmxc_path' -> 'clone_from_vmcx_path'
8 years ago
DanHam 3c5d7aec74
Ensure new fixer appears in 'packer fix' usage message
8 years ago
DanHam 1347f07618
Update 'packer fix' command usage output to include all fixers
8 years ago
Matthew Hooker dde6805ee8
ignore empty top-level config keys when vetting fix
8 years ago
Sean Malloy 3622a669dc Add new post processor googlecompute-import
8 years ago
Matthew Hooker a5e29e68da
cmd/validate: notify user if config is "fixable"
8 years ago
M. Marsh eb557af8bf
Merge branch 'master' into f-autocomplete
8 years ago
Matthew Hooker 3c37aaf4e6
update atlas deprecation language
8 years ago
Josh Soref e7a30b4ba2 spelling: attempt
8 years ago
Edouard BONLIEU 7e36cfcff1
Add Scaleway builder
8 years ago
Matthew Hooker 6205c71f98
Merge pull request #5791 from YuSungDuk/master
8 years ago
Matthew Hooker c03ce222b2
add atlas deprecation warnings.
8 years ago
SwampDragons 997f8e4a2a
Merge pull request #5318 from hashicorp/sigtermcleanup
8 years ago
유성덕 5714108ef9 Merge branch 'master' into support_ncloud
8 years ago
Megan Marsh 7d85b31b29
make fmt
8 years ago