Commit Graph
163 Commits
Author SHA1 Message Date
Johan Brandhorst-SatzkornandMichael Li 6198fe279e Target pagination e2e test (#4010)
* testing/e2e: Use a separate config file for database init

The other config file contains templated parameters, which was causing
errors when loading the config file, even though the values were never
used.

* testing/e2e: add target pagination test

Exercises target pagination both over the CLI and the API. These tests
run in <10s on my machine, though they each involve creating 1000
targets (with current defaults).

---------

Co-authored-by: Michael Li <michael.li@hashicorp.com>
2024-01-05 07:43:20 -08:00
Michael Li 0adfe2d5a3 test(e2e): Fix syntax (#4164) 2023-12-15 15:15:03 -05:00
Michael Li b696f1653d test(e2e): Add worker ip to aws tests (#4153) 2023-12-14 13:48:29 -05:00
Michael Li 600a2dff24 test(e2e): Add rate limit test (#4135) (#4143)
* test(e2e): Add rate limit test (#4135)

(cherry picked from commit 9bf350d622a14ea39feaca29861c738a5deff9bb)

* test(e2e): Modify rate limit test due to timing issues (#4145)

The rate limit test was running into failures due to some hard-coded assumptions (waiting for a command to last longer than 3 seconds to determine if the CLI auto-retried). This change makes it more resilient.

(cherry picked from commit 3535f15922c37fda5457f02cf8ae894203359042)
2023-12-13 10:17:04 -05:00
Johan Brandhorst-Satzkorn fa7813d800 testing: clarify tracing requirements (#4063)
I missed that you need to explicitly create a server
using http.DefaultServeMux.
2023-12-05 11:36:25 -08:00
Michael Li 3cae4933c0 test(e2e): Update migration test with additional resources (#4069)
* test(e2e): Add descriptions to resources

* test(e2e): Add more resources to migration test
2023-11-30 09:38:07 -05:00
Michael Li 093f889333 test(e2e): Add test for LDAP (#4061)
* test(e2e): Add test for LDAP

This adds the infrastructure and a test for an LDAP workflow

* test(e2e): Refactor test packages

This reduces the number of scenarios needed

* CR

* fixup! test(e2e): Add test for LDAP
2023-11-28 16:25:26 -05:00
Johan Brandhorst-Satzkorn a89573b35f subtypes,handlers: add runtime trace regions (#4060)
* subtypes,handlers: add runtime trace regions

The subtype.Filterable and handlers.ProtoToStruct functions
are costly and worth measuring whenever runtime tracing
is in use. This has almost no cost when tracing is not in use,
so there's little harm in having them in place.

* testing: Add TRACING.md

TRACING.md contains information about how to perform
Go runtime tracing of the Boundary application.
2023-11-27 13:37:04 -08:00
Michael Li 6ef015e1d1 test(e2e): Use docker mirror when pulling image (#4045) 2023-11-15 14:58:40 -05:00
Michael Li 36d0e5ede0 test(e2e): Add test that connects to target using go ssh library (#4040)
* test(e2e): Add test that connects to target using golang ssh library

* fixup! test(e2e): Add test that connects to target using golang ssh library
2023-11-14 14:54:48 -05:00
Michael Li 8e83cc87d3 test(e2e): Add some other commands to execute over localhost (#4016) 2023-11-07 16:59:52 -05:00
Michael Li 466b5e20ea test(e2e): Add support for -additional-valid-principals test (#3966)
* test(e2e): Remove unnecessary error checks

* test(e2e): Install docker cli in test runner
2023-10-31 17:06:14 -04:00
Michael Li 7d581abac7 test(e2e): Add check for vault worker filters (#3859) 2023-10-19 09:08:10 -04:00
Michael Li 609357c483 test(e2e): Add test for creating an auth method (#3846)
* test(e2e): Add test for creating an auth method

* CR: Add an additional check for user auto-creation
2023-10-17 09:41:42 -04:00
Michael Li 578d87081a test(e2e): Add test with scp operations (#3812)
* chore(e2e): Allow ssh to targets to assist with debugging

* test(e2e): Add test with scp operations

* CR: Use io.CopyN to optimize memory allocation

This mitigates the need to allocate a 256K string
2023-10-10 14:55:51 -04:00
Michael Li dc912e2a86 test: Update tests to account for deprecated features in 0.14.0 (#3776)
* chore: Fix comment typo

* test(e2e): Update to use new credential library type

* test(e2e): Update to use new field name

* test(bats): Remove tests that use deprecated subcommand

* chore: Update to 0.14.0

* test(credentiallibraries): Update to use new credential library type

* doc: Add deprecation notices for 0.14.0

* fixup! doc: Add deprecation notices for 0.14.0
2023-09-26 10:33:53 -04:00
Michael Li 98f8383a2b test: Add option for logging in test controller (#3738) 2023-09-15 14:14:12 -04:00
Michael Li 94dd9e84fe test(e2e): Refactor vault setup method (#3724)
* refact(e2e): Pass in boundary-controller-policy to method

This allows any boundary-enterprise specific test packages to point to their own testdata directory

* test(e2e): Fix assertion statement

* refact(e2e): Move method call for clarity
2023-09-14 14:12:09 -04:00
Michael Li ff34cb629e test(e2e): Add a test for a single-hop worker (#3690)
* refact(e2e): Add env for workers

* test(e2e): Add test for single-hop worker

* fixup! refact(e2e): Add env for workers

* fixup! test(e2e): Add test for single-hop worker

* fixup! test(e2e): Add test for single-hop worker

* fixup! test(e2e): Add test for single-hop worker

* fixup! test(e2e): Add test for single-hop worker
2023-09-11 14:25:32 -04:00
Michael Li 9a6b0d26cb test(e2e): Add test for boundary connect postgres (#3671)
* refact(e2e): Rename env

* test(e2e): Add test for `connect postgres`

* fixup! test(e2e): Add test for `connect postgres`
2023-09-06 17:29:35 -04:00
Michael Li 2774fbb8d4 test(e2e): Add test for connect ssh -remote-command (#3642)
* test(e2e): Add test for`connect ssh -remote-command`

* test: Fix comments
2023-08-30 09:23:12 -04:00
Michael Li 1c8c11c551 test(e2e): Add license env (#3583) 2023-08-15 10:15:00 -04:00
Michael Li 55d85f90b9 test(e2e): Refactor migration test docker repo definition (#3578)
This commit refactors docker repo definitions in the migration test to make it simpler to modify which version of boundary is being used. Additionally, this also refactors where "pull image" is performed to reduce another spot where the docker repository needs to be passed in.
2023-08-14 16:03:30 -04:00
hashicorp-copywrite[bot]andJohan Brandhorst-Satzkorn 29da0bcb92 [COMPLIANCE] License changes (#3567)
* Adding explicit MPL license for sub-package.

This directory and its subdirectories (packages) contain files licensed with the MPLv2 `LICENSE` file in this directory and are intentionally licensed separately from the BSL `LICENSE` file at the root of this repository.

* Adding explicit MPL license for sub-package

This directory and its subdirectories (packages) contain files licensed with the MPLv2 `LICENSE` file in this directory and are intentionally licensed separately from the BSL `LICENSE` file at the root of this repository.

* Updating the license from MPL to Business Source License

Going forward, this project will be licensed under the Business Source License v1.1. Please see our blog post for more details at https://hashi.co/bsl-blog, FAQ at www.hashicorp.com/licensing-faq, and details of the license at www.hashicorp.com/bsl.

* Update copyright file headers to BUS-1.1

* Rerun make gen

This will pick up the last of the license changes

* Revert "Rerun make gen"

This reverts commit dbe0968bffd92745d8663c6940debae098395a6b.

* Remove copywrite from generation script

The current version of copywrite is not sophisticated enough
to only apply the copywrite changes to certain subdirectories,
so to avoid accidentally relicensing our api and sdk modules,
we will stop running the copywrite script until such time
that it can do the right thing.

* License protobuf API as MPL

The protobuf API files are used to generate the SDK,
since we want the SDK to be MPL, the protobuf files
must also be MPL. This extends to all protobuf files
whose sources end up in the SDK directory, including:

- internal/proto/controller/api
- internal/proto/controller/custom_options
- internal/proto/plugin

It also includes the generated service directory in
internal/gen/controller/api/services, since they are
generated from the protobuf sources used for the SDK.

* Change website license file name

This makes the naming scheme consistent with the rest
of the repository.

* Add note on licensing to README

* Set copywrite license to BUSL

* Revert "Add note on licensing to README"

This reverts commit 4d865a91a7a4f11605f0dc4609355d7e3c3cfffe.

---------

Co-authored-by: hashicorp-copywrite[bot] <110428419+hashicorp-copywrite[bot]@users.noreply.github.com>
Co-authored-by: Johan Brandhorst-Satzkorn <johan.brandhorst@gmail.com>
2023-08-11 10:31:53 -07:00
Michael Li 6c57aa7fda test(e2e): Add pieces necessary for enterprise migration test (#3555) 2023-08-09 14:43:41 -04:00
Michael Li f88d3892cb test(e2e): Add infra for ssh certificate injection test (#3532) 2023-08-04 12:56:24 -04:00
Michael Li cce722c773 test(e2e): Add "update host set filter" check (#3482) 2023-07-20 10:50:18 -04:00
Michael Li e821781c94 test(e2e): Update grants to use new ids field (#3475) 2023-07-19 08:33:37 -04:00
Michael Li 0d4ef933c3 test(e2e): Build UI when running docker scenarios locally (#3463)
* test(e2e): Add session id to logs for debug purposes

* test(e2e): Build UI when building docker resources
2023-07-19 08:32:02 -04:00
Michael Li 1cb6743f69 test(e2e): Use vault-generic credential library type (#3462)
The vault credential library type will be deprecated at some point in favor of the vault-generic credential library type.
2023-07-18 09:20:32 -04:00
Stan Ryzhov 732973c7b8 test(e2e): Add test to connect to target via its name and scope (#3387) 2023-07-06 16:41:39 -04:00
Michael Li eed17d63b5 test(e2e): Update to use fmt.Sprintf (#3388) 2023-07-06 11:52:52 -04:00
Stan Ryzhov 1f16293f65 test(e2e): Add helper method for boundary connect (#3379) 2023-07-05 10:48:16 -04:00
Michael Li 0af862ba5d test(e2e): Update test names (#3362) 2023-06-27 14:03:48 -04:00
Michael Li 42ab20b37b refact(e2e): Rename some test files and methods (#3360)
* refact: Rename method for clarity

* refact: Rename test files for clarity

* test(e2e): Add method for removing brokered credential
2023-06-26 13:21:45 -04:00
Stan Ryzhov dbad3eee56 test(e2e): Update env variables and target creation (#3339) 2023-06-21 15:45:22 -04:00
Michael Li 401493d225 test(e2e): Rename test packages (#3334) 2023-06-15 11:51:14 -04:00
Jeff Mitchell 8322916fb4 Remove all deprecated Err/Wrap/E calls (#3286) 2023-06-14 21:55:24 -04:00
Michael Gaffney 41bdfb4406 fix(db): Fix time zone consistency issues in monthly billing views
The hcp monthly billing views build a range of buckets using the
`generate_series` and the `now()` functions along with relative offsets
like `+ 1 month`. The calculated start and end times for these views can
vary depending on the time zone setting of the PostgreSQL server.

This adds 3 table functions that call their respective views with the
time zone set to UTC. Calling these functions instead of their
underlying views directly prevents the returned values from varying when
the server's time zone is not set to UTC.

This also drops support for PostgreSQL 11. The included tests use the
`date_trunc(field, source [, time_zone ])` function added in PostgreSQL
12.

Fixes: 41b1b5b4b7
2023-06-05 12:48:15 -04:00
Jim d4e537c88d chore: updgrade pgx direct deps to v5 (#3258) 2023-06-01 08:59:38 -04:00
Michael Li 615fa686c4 test(e2e): Add test that checks that session ends after deleting project (#3221)
* test(e2e): Add test that checks that session ends after deleting project

* CR: Update to create target with address

* CR: Rename method for clarification
2023-05-16 13:06:11 -04:00
Josh Brand 603c3c8c9c fix(e2e): Fix path to echo in connect_test & update scenarios for local builds (#3208) 2023-05-08 15:04:26 -04:00
Michael Li 6f6f4ade0a test(e2e): Modify port to avoid conflicts (#3205) 2023-05-05 14:33:37 -04:00
Jim 667ea285be feature (boundary dev): add support for dev ldap auth method (#3192) 2023-04-28 11:35:54 -04:00
Michael Li b88050a4c4 test(e2e): Fix assertion statement (#3190) 2023-04-27 13:35:52 -04:00
Michael Li cecc959a94 test(e2e): Clean up user if test fails (#3180) 2023-04-25 09:47:08 -04:00
Michael Li 33f3a5ff9c test(e2e): Add test that uses new worker resource (#3177) 2023-04-24 16:58:39 -04:00
Jeff Mitchell 20391e3503 Add default client port to targets and use in connect command (#2767) 2023-04-21 06:50:53 -04:00
Stan Ryzhov 5e9ffd57d4 test(e2e): add test to verify user is logged out on its auth-token deletion (#3160) 2023-04-17 22:16:55 -04:00
Stan Ryzhov c675dc07ec test(e2e): Verify different credentials are brokered to target (#3149)
* test(e2e): Verify json credentials are brokered back

* test(e2e): Get expected json credentials from file

* test(e2e): Check private key credentials are brokered to target

* test(e2e): Regenerate test .pem file for every test
2023-04-05 19:42:46 -04:00