434 Commits

Author SHA1 Message Date
sophia
8bd9a778e9
Test for non merging configs 2022-04-25 12:26:34 -05:00
sophia
6daa8d52a2
Remove code for avoiding duped synced folders in config 2022-04-25 12:26:34 -05:00
sophia
34c4bac2ec
Don't merge Vagrantfile configs when merging targets to upsert to db 2022-04-25 12:26:34 -05:00
sophia
1f632d076c
go generate after rebase 2022-04-25 12:26:33 -05:00
sophia
19f3d2f0b6
Refactor named plugin bits to apply to all components 2022-04-25 12:26:33 -05:00
sophia
153d218d68
Set plugin name 2022-04-25 12:26:32 -05:00
sophia
1217189616
go generate 2022-04-25 12:26:32 -05:00
Chris Roberts
fc8b01f0ac
Generated proto updates 2022-04-25 12:26:32 -05:00
Chris Roberts
14fa44a449
Update to use command info from sdk 2022-04-25 12:26:32 -05:00
Chris Roberts
efd4df030d
Remove job command and use command info from sdk 2022-04-25 12:26:32 -05:00
Chris Roberts
bf393065fa
Update guest and synced folder plugin loading to seed machine 2022-04-25 12:26:31 -05:00
Chris Roberts
2acd0fa3b8
Generated proto updates 2022-04-25 12:26:30 -05:00
sophia
891eb27e9a
Rename plugin "target" to "addr" 2022-04-25 12:26:27 -05:00
Chris Roberts
46a9440b57
Set remaining args into proto 2022-04-25 12:26:26 -05:00
Chris Roberts
204cedcd68
Add missing set docs 2022-04-25 12:26:26 -05:00
Chris Roberts
0e385a785c
Add flag validation when parsing 2022-04-25 12:26:25 -05:00
Chris Roberts
341daf8dea
Return group after creating 2022-04-25 12:26:25 -05:00
Chris Roberts
9d9430e60b
Add flag validation tests 2022-04-25 12:26:25 -05:00
Chris Roberts
7e60a11936
Add test coverage on group 2022-04-25 12:26:25 -05:00
Chris Roberts
dfee85ea5e
Add doc notes to group 2022-04-25 12:26:25 -05:00
Chris Roberts
08f9eaa603
Adjust display rules 2022-04-25 12:26:25 -05:00
Chris Roberts
ae9cee6229
Fix types on flag vars 2022-04-25 12:26:25 -05:00
Chris Roberts
c010ae0429
Update CLI to use internal flags implementation 2022-04-25 12:26:25 -05:00
Chris Roberts
05facc0035
Add flags library 2022-04-25 12:26:25 -05:00
Chris Roberts
16931138e7
Update git submodule location
Having the modules stored in `./vendor` causes issues with `go mod`.
    Follow waypoint's convention to store in `./thirdparty` and grab
    the same Makefile modifications to alert when the submodules need
    to be initialized. Update generators to use new path.
2022-04-25 12:26:25 -05:00
sophia
5fda271283
go generate . 2022-04-25 12:26:23 -05:00
sophia
896cdea21f
Delete machine from db 2022-04-25 12:26:23 -05:00
sophia
3dbd9286be
Merge targets with upserting 2022-04-25 12:26:23 -05:00
sophia
12de22a7db
Get machine state 2022-04-25 12:26:23 -05:00
sophia
8a39ee6960
Set target state in addition to machine state 2022-04-25 12:26:22 -05:00
sophia
5ed50277bd
Find target in index by uuid or name 2022-04-25 12:26:22 -05:00
Chris Roberts
d8145cdd52
Update flag value extraction for dynamic commands 2022-04-25 12:26:22 -05:00
Chris Roberts
e00f82fdee
Update to use component flags and update parsing 2022-04-25 12:26:22 -05:00
Chris Roberts
39439cf9fb
Register commands and subcommands during setup 2022-04-25 12:26:22 -05:00
Chris Roberts
66dc2fd259
Remove loading status during startup 2022-04-25 12:26:22 -05:00
Chris Roberts
5115bc3fb3
Update to use component command flags 2022-04-25 12:26:21 -05:00
Chris Roberts
3933632216
Update flag mappers to use generic component flag struct 2022-04-25 12:26:21 -05:00
Paul Hinze
92c345b42d
Allow go push plugins to use config from Vagrantfile
* Populate push configs when parsing the vagrantfile
* Allow untyped configs to be shipped over GRPC
* In our demo plugin, walk the vagrantfile and snag the config

Example Vagrantfile that works with the demo plugin:

```ruby
Vagrant.configure("2") do |config|
  config.push.define "myplugin" do |push|
    push.coolkey = "coolvalue"
    push.alist = ["so", "many", "items"]
    push.ahash = { "hashkey" => "hashvalue" }
  end
end

```
2022-04-25 12:26:21 -05:00
Paul Hinze
0fef7cc416
Port push plugins
This uses the new Push plugin support added to the plugin SDK in https://github.com/hashicorp/vagrant-plugin-sdk/pull/106 to make the following changes:

 * The plugin manager on the Go side now registers push plugins
 * The the _remote_ plugin manager on the Ruby side now calls over to
   the go side to get push plugins
 * All the wiring is hooked up such that when a push plugin is replaced
   with its remote GRPC-client-wielding equivalent, the messages are
   ferried around.
2022-04-25 12:26:21 -05:00
sophia
deb667ecd3
Use common rpc errdetails messages 2022-04-25 12:26:20 -05:00
sophia
219473fb60
Seach for localized error message in error details 2022-04-25 12:26:20 -05:00
sophia
c4e97bb89b
Send localized message originating from plugin (if applicable) 2022-04-25 12:26:20 -05:00
sophia
45e64b9890
Add localized message proto 2022-04-25 12:26:20 -05:00
sophia
aeda0ec039
Pass error status with job completion results 2022-04-25 12:26:20 -05:00
Chris Roberts
6b4e13c615
Use environment variable for logging level 2022-04-25 12:26:19 -05:00
Chris Roberts
42a89335d4
Set environment variable to persist logging level 2022-04-25 12:26:19 -05:00
Paul Hinze
ab5a7f2b27
Remove httpfs package
You want to know something silly? There are multiple versions of
go-bindata floating around in the world, and they have different
features and flags.

This httpfs package was written with
https://github.com/go-bindata/go-bindata and uses the -fs flag. Most
everyone else (nixpkgs, homebrew) seems to have moved over to this fork
https://github.com/kevinburke/go-bindata, which does not have that
feature.

Run `go generate` with this installed and you'll get an error like `flag
provided but not defined: -fs`.

It looks like `httpfs` is the odd one out here, and it's not used
anywhere I can find either here or waypoint, so let's just remove it so
we can `go generate` cleanly with the version of go-bindata that most
people are using.
2022-04-25 12:26:19 -05:00
Chris Roberts
72b8547cce
Generated proto updates 2022-04-25 12:26:15 -05:00
Chris Roberts
acb32d33f7
Get parent count directly from plugin 2022-04-25 12:26:14 -05:00
Chris Roberts
1155e7be21
Configure plugins and use plugin local functions 2022-04-25 12:26:14 -05:00