20 Commits

Author SHA1 Message Date
Chris Roberts
e958c6183a Adds initial HCP config support
Adds initial basic support for HCP based configuration in vagrant-go.
The initalization process has been updated to remove Vagrantfile parsing
from the client, moving it to the runner using init jobs for the basis
and the project (if there is one). Detection is done on the file based
on extension for Ruby based parsing or HCP based parsing.

Current HCP parsing is extremely simple and currently just a base to
build off. Config components will be able to implement an `Init`
function to handle receiving configuration data from a non-native source
file. This will be extended to include a default approach for injecting
defined data in the future.

Some cleanup was done in the state around validations. Some logging
adjustments were applied on the Ruby side for better behavior
consistency.

VirtualBox provider now caches locale detection to prevent multiple
checks every time the driver is initialized.
2023-09-07 17:26:10 -07:00
hashicorp-copywrite[bot]
36a312ee26
add missing license headers and update copyright file headers to BUS-1.1 2023-08-10 21:53:25 +01:00
Chris Roberts
f9b3d67f6c Set target source when cloning 2023-06-05 14:18:06 -07:00
Chris Roberts
5445c2195e Include project when looking up target 2023-06-05 14:18:06 -07:00
sophia
49280286ad Strip new lines from error details
The error details message should just be one string without spacing
so the terminal can set a output length. This will allow messages
from Ruby and Go errors to have similar formating.
2022-09-19 15:14:42 -04:00
sophia
b9fb6c5f5f Refactor to use localizer to create error with status 2022-09-19 15:14:42 -04:00
sophia
bd801af984 Add details to errors 2022-09-19 15:14:42 -04:00
sophia
9a276d7818 Get additional message into error 2022-09-19 15:14:42 -04:00
sophia
6d4f769c87 Validate provider 2022-09-19 15:14:42 -04:00
sophia
f26ff28ad4 Set provider if available 2022-09-19 15:14:42 -04:00
Paul Hinze
da77316f9a
Fix virtualbox lifecycle acctests
Two fixes:

 1. Allow us to make it through Vagrant::Environment initialization when
    there's no project yet, fixing box add and init commands.
 2. Don't prune UNKNOWN targets from state... as VBox looks like it
    leaves things in that state when it runs suspend.
2022-07-13 18:36:11 -05:00
Chris Roberts
2c35229013 Perform target lookup to validate exist and name 2022-07-08 16:38:02 -07:00
Chris Roberts
b82d55cc37 Update vagrantfile to load machines via factory 2022-07-08 16:38:02 -07:00
Chris Roberts
e9353ac566 Remove some extraneous logger output 2022-06-28 09:49:28 -07:00
Chris Roberts
f0a7d87f31 Only load target with vagrantfile if config exists 2022-06-27 18:10:40 -07:00
Chris Roberts
fd963c39d4 Reuse cache and init after cloning 2022-06-21 14:43:14 -07:00
Chris Roberts
2890fb57c5 Finalize the entire Vagrantfile so all config is properly available 2022-06-20 16:04:01 -07:00
Chris Roberts
97c51a56cd Reorganize vagrantfile implementation, support provider overrides 2022-06-20 13:02:01 -07:00
Chris Roberts
a262686f08 Fix up string format types 2022-06-15 11:14:07 -07:00
Chris Roberts
95b25bfa1c Add vagrantfile implementation 2022-06-15 11:08:08 -07:00