Commit Graph

340 Commits

Author SHA1 Message Date
Mitchell Hashimoto e73c224764 packer: Build runs the post-processors 2013-06-18 10:54:29 -07:00
Mitchell Hashimoto 75fe58d5f7 packer: Post-processors are configured 2013-06-18 10:31:52 -07:00
Mitchell Hashimoto 218692950b packer: Build can return multiple artifacts 2013-06-18 10:24:23 -07:00
Mitchell Hashimoto 9c89e33b5b packer/rpc: Get RPC compliant with Environment again 2013-06-18 10:05:45 -07:00
Mitchell Hashimoto d95f0a620a packer: builds now have post processors as part of them 2013-06-18 09:58:39 -07:00
Mitchell Hashimoto eee22b32f6 packer: Environment can look up post processors 2013-06-18 09:49:05 -07:00
Mitchell Hashimoto 57fef22429 packer: panic if Prepare called twice on build, lock 2013-06-18 09:37:49 -07:00
Mitchell Hashimoto e851ac5d26 packer: Avoid an extra allocation by using clever addressing 2013-06-18 09:30:23 -07:00
Mitchell Hashimoto 7a07802eb4 packer: Parse post-processors in templates
This includes parsing for the simple, detailed, and sequential
processors.
2013-06-18 09:27:08 -07:00
Mitchell Hashimoto 46108ce13f fmt 2013-06-17 15:19:33 -07:00
Mitchell Hashimoto dd89716ed5 packer: An initial PostProcessor interface 2013-06-17 11:56:26 -07:00
Mitchell Hashimoto f4a5adf471 packer: Output a newline when interrupted for UI 2013-06-17 11:40:57 -07:00
Mitchell Hashimoto e0b05355c3 packer: If interrupted, Ask is disabled 2013-06-15 18:25:34 -07:00
Mitchell Hashimoto dc5d261994 packer: Ui can return an error for Ask, returns one for interrupt 2013-06-15 18:24:38 -07:00
Mitchell Hashimoto a73e71c37f packer/rpc: Panic in error case 2013-06-15 11:27:09 -07:00
Mitchell Hashimoto 67eaa07cf4 packer: Get rid of "name" in template, wasn't used for anything 2013-06-15 11:14:44 -07:00
Mitchell Hashimoto 22e7345148 packer: Ui requires input for Ctrl-C 2013-06-14 17:37:38 -07:00
Mitchell Hashimoto ea01d7b2c6 fmt 2013-06-14 16:00:16 -07:00
Mitchell Hashimoto 9a69b21025 packer: Ui.Ask quits during interrupt 2013-06-14 15:59:54 -07:00
Mitchell Hashimoto 21b6d2a435 builder/common: multistep debug fn gracefully exits during an interrupt 2013-06-14 15:47:06 -07:00
Mitchell Hashimoto e0f2bcf8a2 packer: Add "Ask" method to Ui to ask for input 2013-06-14 15:17:03 -07:00
Mitchell Hashimoto cbd3f59578 builder/vmware: Enable the debug runner 2013-06-14 15:07:34 -07:00
Mitchell Hashimoto 8217e64a8d packer: Set DebugConfigKey to true if debug is on 2013-06-14 12:38:54 -07:00
Mitchell Hashimoto fd044982d9 packer: Additional comments 2013-06-14 12:32:14 -07:00
Mitchell Hashimoto 9f5a247511 packer: Builders can take multiple configs 2013-06-14 12:27:50 -07:00
Mitchell Hashimoto a45c7fb0ea packer: Add SetDebug to Build objects 2013-06-14 12:22:19 -07:00
Mitchell Hashimoto e00a30e729 packer: Comments on Build interface 2013-06-14 12:15:51 -07:00
Mitchell Hashimoto a35feebe70 packer: Build no longer takes Ui for Prepare 2013-06-13 10:08:31 -07:00
Mitchell Hashimoto 521b59a6fa Make everything support the new builder interface 2013-06-12 16:06:56 -07:00
Mitchell Hashimoto 12cc8e98aa packer/rpc: less panics, more returning errors 2013-06-12 16:02:07 -07:00
Mitchell Hashimoto d2023c69be packer/rpc: returning errors from builds works properly 2013-06-12 16:01:42 -07:00
Mitchell Hashimoto db8aeaba40 packer, packer/rpc: Build/builders can return errors now 2013-06-12 15:58:02 -07:00
Mitchell Hashimoto 0f98852d4d packer: Ui error output is red 2013-06-12 10:41:58 -07:00
Mitchell Hashimoto 417f7e7f47 fmt 2013-06-11 14:09:31 -07:00
Mitchell Hashimoto de14dffd36 packer/plugin: Set the RPC port range to the plugin port range 2013-06-11 11:14:36 -07:00
Mitchell Hashimoto 9162819daf packer/plugin: Avoid lexical scoping issues with cleaning up clients 2013-06-11 11:10:08 -07:00
Mitchell Hashimoto e904705a49 packer uses the new plugin client API 2013-06-11 11:06:23 -07:00
Mitchell Hashimoto 88d508893d packer/plugin: client to Client so it can be used outside 2013-06-11 11:03:36 -07:00
Mitchell Hashimoto 7fe98e50fe packer/plugin: Refactor to get interfaces from Client 2013-06-11 11:00:06 -07:00
Mitchell Hashimoto 250cb0106b packer/plugin: Only allow client start once, lock 2013-06-11 10:43:55 -07:00
Mitchell Hashimoto fb2ffde29e packer/plugin: Refactor the client for the API to be more uniform 2013-06-11 10:39:06 -07:00
Mitchell Hashimoto e2214106ee packer: Cache keys should be hex encoded to string 2013-06-09 23:06:47 -07:00
Mitchell Hashimoto 7b0000cd4c packer: Actually return if prepare of a build fails 2013-06-09 23:05:11 -07:00
Mitchell Hashimoto 62309cb6de Build/Builder take a Cache object now 2013-06-09 22:00:47 -07:00
Mitchell Hashimoto 5307e5391c fmt 2013-06-09 21:19:26 -07:00
Mitchell Hashimoto f2c8b994a0 packer: Default cache is just to os temporary dir 2013-06-09 21:18:06 -07:00
Mitchell Hashimoto edaf19199f packer: Environment has Cache method, RPC implements 2013-06-09 21:09:09 -07:00
Mitchell Hashimoto 2c8b198049 packer/rpc: Support Cache interface 2013-06-09 19:25:48 -07:00
Mitchell Hashimoto 7968068a3a packer: Add FileCache and Cache 2013-06-09 19:01:28 -07:00
Mitchell Hashimoto d55bf3f3ec packer: Support overrides in provisioners for each build 2013-06-07 10:35:26 -07:00
Mitchell Hashimoto 5638cecd14 packer: Use mapstructure for templates, save lots of lines 2013-06-07 10:23:15 -07:00
Mitchell Hashimoto 4a8278d49b provisioner/shell: Support setting the execute command 2013-06-06 23:14:31 -07:00
Mitchell Hashimoto 4531922ec3 packer: Return the provisioner prepare errors if they occurred 2013-06-06 17:09:51 -07:00
Mitchell Hashimoto 0a6d8ed75a packer: Add errors to Prepare 2013-06-06 17:07:42 -07:00
Mitchell Hashimoto 09f5cd5090 packer: Update doc on Provisioner 2013-06-06 17:02:02 -07:00
Mitchell Hashimoto 6b87c42ee6 packer: Change provisioner interface to take array of configs 2013-06-06 17:01:12 -07:00
Mitchell Hashimoto 34f4086963 packer/plugin: Preserve parent ENV when executing client 2013-06-05 20:39:39 -07:00
Mitchell Hashimoto dd4fb1d62a packer/plugin: Explicitly set GOMAXPROCS to # of cpus 2013-06-05 17:39:27 -07:00
Mitchell Hashimoto 9bb24e6d90 packer/rpc: Return proper nil artifact if nil is returned 2013-06-05 15:36:26 -07:00
Mitchell Hashimoto 334fd4e154 packer/rpc: Register []interface{} so arrays can be sent over wire 2013-06-05 15:16:41 -07:00
Mitchell Hashimoto 5c39a2f7ca fmt 2013-06-03 22:32:04 -07:00
Mitchell Hashimoto 12a9362f0a packer/plugin: Swallow interrupts in plugins 2013-06-03 22:31:54 -07:00
Mitchell Hashimoto 94cfe39a76 packer: coreBuild.Cancel calls the builder Cancel method 2013-06-03 16:06:04 -07:00
Mitchell Hashimoto 30a061a855 packer: Build.Cancel 2013-06-03 16:03:08 -07:00
Mitchell Hashimoto 0ba80c88e8 packer/plugin: Implement Builder.Cancel 2013-06-03 15:31:28 -07:00
Mitchell Hashimoto e06c26c55c packer/rpc: Implement Builder.Cancel 2013-06-03 15:30:09 -07:00
Mitchell Hashimoto 1b557d7710 packer/rpc: Builder.Run() no longer blocks RPC connection 2013-06-03 15:00:35 -07:00
Mitchell Hashimoto 079d6f4d43 packer: Introduce Cancel() method to Builder 2013-06-03 14:44:34 -07:00
Mitchell Hashimoto e21d389fd2 packer: Fixin bugs in PrefixUi calling the wrong method 2013-06-03 13:54:28 -07:00
Mitchell Hashimoto 3e1b10c09e packer: ColoredUi bolds, but doesn't bold messages 2013-06-03 13:49:59 -07:00
Mitchell Hashimoto f041ebb2fd packer: ColoredUi 2013-06-03 13:35:43 -07:00
Mitchell Hashimoto edab952a68 packer: Add Message method to Ui 2013-06-03 11:30:38 -07:00
Mitchell Hashimoto bbc5f305e2 packer: RemoteCmd.Wait 2013-06-03 10:49:23 -07:00
Mitchell Hashimoto 75074ca92d go fmt 2013-06-02 23:27:18 -07:00
Mitchell Hashimoto a21fe8c484 packer/rpc: Exited fields now work over RPC 2013-06-02 23:21:55 -07:00
Mitchell Hashimoto ea4171f163 packer/rpc: Hook up the new communicator interface 2013-06-02 23:08:40 -07:00
Mitchell Hashimoto 532faec457 packer: New Communicator interface is much simplified 2013-06-02 21:20:27 -07:00
Mitchell Hashimoto 74d812a766 packer: Much smarter CLI 2013-06-02 15:03:02 -07:00
Mitchell Hashimoto fcd866731b packer: Remove extra newline on version 2013-06-02 11:52:49 -07:00
Mitchell Hashimoto aa1304f860 packer: Print command help if "--help" is given 2013-06-02 11:49:01 -07:00
Mitchell Hashimoto bbafcfa938 packer, etc: added Help method to Command interface
This will be used for long-form help when "packer help foo"
or "packer foo --help" is called.
2013-06-02 11:41:12 -07:00
Mitchell Hashimoto e629eef97a packer/plugin: Start testing the client 2013-06-01 19:35:19 -07:00
Mitchell Hashimoto 45c590f413 packer: Fix help output for packer, excessive newlines 2013-06-01 19:15:32 -07:00
Mitchell Hashimoto ade3795123 packer: RemoteCommand.StderrChan 2013-06-01 18:49:49 -07:00
Mitchell Hashimoto e753ffe5d9 packer: Refactor on StdoutChan so it'll work for stderr easily 2013-06-01 18:31:22 -07:00
Mitchell Hashimoto 810d17c0ef packer: RemoteCommand.StdoutChan works + tests 2013-06-01 18:21:27 -07:00
Mitchell Hashimoto ace53450b9 packer: More efficient RemoteCommand.ExitChan 2013-06-01 17:57:26 -07:00
Mitchell Hashimoto c6dd54760c Get everything compiling again 2013-06-01 17:48:19 -07:00
Mitchell Hashimoto 8034e91ca3 packer: Lock in RemoteCommand.ExitChan 2013-06-01 17:45:57 -07:00
Mitchell Hashimoto 24237da32c packer: RemoteCommand.ExitChan() and tests 2013-05-28 18:12:15 -07:00
Mitchell Hashimoto 97ba152771 packer: tests for RemoteCommand.Wait 2013-05-28 18:02:14 -07:00
Mitchell Hashimoto 7154b5c0f1 packer/rpc: Close the net conn after done sending data for Comm 2013-05-27 23:36:34 -07:00
Mitchell Hashimoto 78ab1709cd packer/rpc: Better logging in communicator 2013-05-27 22:10:44 -07:00
Mitchell Hashimoto 2788d29bd1 packer, packer/rpc: Update Ui to just take a message 2013-05-27 15:12:48 -07:00
Mitchell Hashimoto 84891701bd go fmt 2013-05-23 21:59:03 -07:00
Mitchell Hashimoto 37372bac93 packer/plugin: Support provisioners 2013-05-23 21:37:16 -07:00
Mitchell Hashimoto 1b78fc88a9 packer: coreBuild runs provisioners as part of Run 2013-05-23 21:26:24 -07:00
Mitchell Hashimoto 83eab87c26 packer: TODO item 2013-05-23 21:13:40 -07:00
Mitchell Hashimoto 812722c20d packer: ProvisionHook 2013-05-23 21:13:18 -07:00
Mitchell Hashimoto 73b7d94933 packer: better commenting 2013-05-22 17:06:06 -07:00
Mitchell Hashimoto e69e74b2dc packer: Panic if provisioners and no provisioner function 2013-05-22 17:05:36 -07:00
Mitchell Hashimoto 3d0dde03e6 packer: Panic on template if no builder function 2013-05-22 17:02:34 -07:00
Mitchell Hashimoto 534f32067a packer: Test that hooks are callable from builds 2013-05-22 16:46:23 -07:00
Mitchell Hashimoto 0f57370dec packer: Prepare provisioners as part of Build prepare 2013-05-22 16:29:07 -07:00
Mitchell Hashimoto cb91ca72ac packer: Build.Prepare takes a UI 2013-05-22 16:20:40 -07:00
Mitchell Hashimoto fbcc6cb2b2 packer: Build now has provisioners, template parses and builds 2013-05-22 16:15:57 -07:00
Mitchell Hashimoto 11d46a3a2c packer: ProvisionerFunc 2013-05-22 15:39:30 -07:00
Mitchell Hashimoto 92a4f27868 packer/rpc: Support provisioners 2013-05-22 15:35:52 -07:00
Mitchell Hashimoto 638e191186 packer: Parse provisioners out of template 2013-05-22 15:12:43 -07:00
Mitchell Hashimoto 06b0cebd1e packer: Template properly calls builder type builderType 2013-05-22 14:39:32 -07:00
Mitchell Hashimoto 4bd7db0759 go fmt 2013-05-22 14:36:33 -07:00
Mitchell Hashimoto 8273565255 better comments for TODO 2013-05-22 14:36:21 -07:00
Mitchell Hashimoto c51223bab7 packer: Template parsing error if name/type is not string 2013-05-22 14:14:40 -07:00
Mitchell Hashimoto f9c59c714f packer: Better error handling for template parsing 2013-05-22 14:11:34 -07:00
Mitchell Hashimoto 615f993de2 packer: MultiError to represent multiple errors 2013-05-22 13:36:09 -07:00
Mitchell Hashimoto c4522a6265 packer: Provisioner interface 2013-05-22 13:25:03 -07:00
Mitchell Hashimoto 41a7fd45b9 packer: Return artifact from build 2013-05-21 22:38:41 -07:00
Mitchell Hashimoto e9618b0d07 packer/plugin: Properly supports Artifacts 2013-05-21 22:16:26 -07:00
Mitchell Hashimoto caa2b7711b packer/rpc: Builders return valid artifacts 2013-05-21 22:14:58 -07:00
Mitchell Hashimoto 53c3d330e4 packer/rpc: Support Artifacts 2013-05-21 22:10:21 -07:00
Mitchell Hashimoto 55d9cd2124 packer: First pass at Artifact interface 2013-05-21 21:53:16 -07:00
Mitchell Hashimoto 2c4a873a5f packer: Add PrefixedUi 2013-05-21 13:20:51 -07:00
Mitchell Hashimoto cc4970d424 packer/rpc: Allow "error" interfaces to be sent over RPC 2013-05-21 11:58:14 -07:00
Mitchell Hashimoto 8dfe78dd19 packer: Log UI output 2013-05-21 11:40:07 -07:00
Mitchell Hashimoto 4453fda2e8 go fmt 2013-05-21 00:56:27 -07:00
Mitchell Hashimoto 559777e5b7 packer: Ui automatically appends newline 2013-05-20 23:43:37 -07:00
Mitchell Hashimoto 15f215d04f go fmt 2013-05-20 16:50:35 -07:00
Mitchell Hashimoto 7475ee8377 packer: Add Communicator to Hook arguments 2013-05-12 17:30:30 -07:00
Mitchell Hashimoto 7fdb53f5d1 packer: Test to make sure DispatchHook implements Hook 2013-05-12 17:15:03 -07:00
Mitchell Hashimoto f74341a7b9 packer/rpc: Complete Upload/Download implementation 2013-05-12 17:09:14 -07:00
Mitchell Hashimoto 9262a85e6c packer/rpc: Communicator.Upload 2013-05-12 16:48:46 -07:00
Mitchell Hashimoto daa431af63 packer: Communicator Upload/Download return an error 2013-05-12 16:25:40 -07:00
Mitchell Hashimoto 496a320a82 packer/rpc: Implement full communicator interface 2013-05-12 16:19:34 -07:00
Mitchell Hashimoto 2799cccf4b packer: Waiting for a remote command and setting the exit status 2013-05-12 16:18:17 -07:00
Mitchell Hashimoto 88a018bf5d packer: Work on communicators... WIP 2013-05-12 14:47:55 -07:00
Mitchell Hashimoto a2bf964f30 packer/rpc: Properly support hooks 2013-05-11 11:11:40 -07:00
Mitchell Hashimoto cb1e0cbabf packer/plugin: Support hooks 2013-05-11 10:46:17 -07:00
Mitchell Hashimoto d926b98708 Update all packer/rpc, packer/plugin, builders for new builder API 2013-05-11 10:31:30 -07:00
Mitchell Hashimoto 441edd25d2 packer: Changes to build parameters and DispatchHook 2013-05-11 10:27:07 -07:00
Mitchell Hashimoto 25fd2fe877 packer: Template looks up hooks and adds them to the build 2013-05-11 10:00:37 -07:00
Mitchell Hashimoto 779f489894 packer: Template takes a component finder 2013-05-11 09:56:42 -07:00
Mitchell Hashimoto 30ab944437 packer/rpc: Support Hooks 2013-05-11 09:51:49 -07:00
Mitchell Hashimoto 8ed313e7b5 packer: Add concept of hooks to Environment 2013-05-10 23:15:13 -07:00
Mitchell Hashimoto 5ac06e116e packer: Parse "hooks" configuration into the Template 2013-05-10 22:47:20 -07:00
Mitchell Hashimoto 44bd56c3a8 go fmt 2013-05-10 17:01:24 -07:00
Mitchell Hashimoto 368ccab8e8 packer: Put Builder definition into its own file 2013-05-10 16:59:28 -07:00
Mitchell Hashimoto 208daf7d03 packer: Hook interface, not hooked up yet 2013-05-10 16:58:50 -07:00
Mitchell Hashimoto de03e97643 packer: More comments/docs 2013-05-10 16:41:35 -07:00
Mitchell Hashimoto 077f15bdfb packer/plugin: Docs 2013-05-09 14:27:20 -07:00
Mitchell Hashimoto c580faa1a5 packer/rpc: error interface wrapper to RPC errors around 2013-05-09 13:59:33 -07:00