consul/command
Nathan Coleman b438a07326
Export peering cli (#15654)
* Sujata's peering-cli branch

* Added error message for connecting to cluster

* We can export service to peer

* export handling multiple peers

* export handles multiple peers

* export now can handle multiple services

* Export after 1st cleanup

* Successful export

* Added the namespace option

* Add .changelog entry

* go mod tidy

* Stub unit tests for peering export command

* added export in peering.go

* Adding export_test

* Moved the code to services from peers and cleaned the serviceNamespace

* Added support for exporting to partitions

* Fixed partition bug

* Added unit tests for export command

* Add multi-tenancy flags

* gofmt

* Add some helpful comments

* Exclude namespace + partition flags when running OSS

* cleaned up partition stuff

* Validate required flags differently for OSS vs. ENT

* Update success output to include only the requested consumers

* cleaned up

* fixed broken test

* gofmt

* Include all flags in OSS build

* Remove example previously added to peering command

* Move stray import into correct block

* Update changelog entry to include support for exporting to a partition

* Add required-ness label to consumer-peers flag description

* Update command/services/export/export.go

Co-authored-by: Dan Stough <dan.stough@hashicorp.com>

* Add docs placeholder for new services export command

* Moved piece of code to OSS

* Break config entry init + update into separate functions

* fixed

* Vary existing service export comparison for OSS vs. ENT

* Move OSS-specific test to export_oss_test.go

* Set config entry name based on partition being exported from

* Set namespace on added services

* Adding namespace

* Remove export documentation

We will include documentation in a followup PR

* Consolidate code from export_oss into export.go

* Consolidated export_oss_test.go and export_test.go

* Add example of partition export to command synopsis

* Allow empty peers flag if partitions flag provided

* Add test coverage for -consumer-partitions flag

* Update command/services/export/export.go

Co-authored-by: Jared Kirschner <85913323+jkirschner-hashicorp@users.noreply.github.com>

* Update command/services/export/export.go

Co-authored-by: Jared Kirschner <85913323+jkirschner-hashicorp@users.noreply.github.com>

* Update changelog entry

* Use "cluster peers" to clear up any possible confusion

* Update test assertions

---------

Co-authored-by: 20sr20 <sujata@hashicorp.com>
Co-authored-by: Dan Stough <dan.stough@hashicorp.com>
Co-authored-by: Jared Kirschner <85913323+jkirschner-hashicorp@users.noreply.github.com>
2023-05-31 14:27:35 -04:00
..
acl Remove artificial ACLTokenMaxTTL limit for configuring acl token expiry (#17066) 2023-04-28 10:57:30 -05:00
agent HCP Telemetry Feature (#17460) 2023-05-29 16:11:08 -04:00
catalog Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
cli Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
config Permissive mTLS: Config entry filtering and CLI warnings (#17183) 2023-04-28 12:51:36 -05:00
connect Accept ap, datacenter, and namespace query params (#17525) 2023-05-31 11:50:24 -04:00
debug Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
event Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
exec Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
flags Export peering cli (#15654) 2023-05-31 14:27:35 -04:00
forceleave Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
helpers Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
info Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
intention Raft storage backend (#16619) 2023-04-04 17:30:06 +01:00
join Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
keygen Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
keyring Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
kv Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
leave Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
lock Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
login Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
logout Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
maint Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
members Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
monitor Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
operator Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
peering Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
reload Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
rtt Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
services Export peering cli (#15654) 2023-05-31 14:27:35 -04:00
snapshot Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
tls Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
troubleshoot Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
validate Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
version fips oss version changes (#17500) 2023-05-29 13:02:06 -05:00
watch Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00
registry.go Export peering cli (#15654) 2023-05-31 14:27:35 -04:00
registry_oss.go Copyright headers for command folder (#16705) 2023-03-28 15:12:30 -04:00