Skip to content

Commit

Permalink
Reorganised testing files (#1859)
Browse files Browse the repository at this point in the history
* refactor: moved update-codegen script to scripts

* refactor: renamed dir hack->test

* refactor: moved deploy dir to test

* chore: small fix to trigger CI
  • Loading branch information
akijakya authored Apr 13, 2023
1 parent cd45a16 commit 1911eff
Show file tree
Hide file tree
Showing 65 changed files with 59 additions and 61 deletions.
2 changes: 1 addition & 1 deletion .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,6 @@ bin/
docs/
operator/build/
vendor/
hack/
test/
*.yaml
*.yml
6 changes: 3 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,7 @@ jobs:
- name: Start kind cluster
run: |
kind version
kind create cluster --config hack/kind.yaml --wait 1m
kind create cluster --config test/kind.yaml --wait 1m
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
Expand All @@ -242,7 +242,7 @@ jobs:
- name: Operator acceptance test
run: |
hack/acceptance-test-operator.sh
test/acceptance-test-operator.sh
acceptance-test-webhook:
name: Webhook acceptance test
Expand Down Expand Up @@ -293,7 +293,7 @@ jobs:
- name: Webhook acceptance test
run: |
hack/acceptance-test-webhook.sh
test/acceptance-test-webhook.sh
multi-cluster-acceptance-test:
name: Operator multi-cluster acceptance test
Expand Down
2 changes: 0 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@

</p>


*Bank Vaults is a thick, tricky, shifty right with a fast and intense tube for experienced surfers only, located on Mentawai. Think heavy steel doors, secret unlocking combinations and burly guards with smack-down attitude. Watch out for clean-up sets.*

*Bank-Vaults is an umbrella project which provides various tools for Vault to make using and operating Hashicorp Vault easier. It's a wrapper for the official Vault client with automatic token renewal and built-in Kubernetes support, dynamic database credential provider for Golang `database/sql` based clients. It has a CLI tool to automatically initialize, unseal, and configure Vault. It also provides a Kubernetes operator for provisioning, and a mutating webhook for injecting secrets.*
Expand Down Expand Up @@ -61,7 +60,6 @@ We use Vault across our large Kubernetes deployments and all the projects were `
Bank-Vaults is a core part of [Banzai Cloud Pipeline](https://github.com/banzaicloud/pipeline), a Cloud Native application and devops platform that natively supports multi- and hybrid-cloud deployments.


## Installing

You usually don't need to use the CLI directly, rather you should install the charts and create Vault instances with the operator and use the webhook inside Kubernetes to mutate Kubernetes resources.
Expand Down
2 changes: 1 addition & 1 deletion examples/istio/cr-istio.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion main-targets.mk
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ varexport-%: ; @echo $*=$($*)

.PHONY: generate-code
generate-code: ## Regenerate clientset, deepcopy funcs, listers and informers
./hack/update-codegen.sh v${CODE_GENERATOR_VERSION}
./scripts/update-codegen.sh v${CODE_GENERATOR_VERSION}

bin/controller-gen-${CONTROLLER_GEN_VERSION}:
set -ex ;\
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-alibaba.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-audit.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-aws.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-awskms.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ spec:
# region: us-east-1

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-azure.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-cert-manager.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-containers.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
audit:
- type: file
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-credentialFromSecret.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-customports.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-disabled-root-token-storage.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-file.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-gcpkms.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-gcs-ha-autounseal.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-gcs-ha.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-hsm-nitrokey.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ spec:
statsdDisabled: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-hsm-softhsm.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ spec:
statsdDisabled: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-init-containers.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-k8s-startup-secret.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-kvv2.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
4 changes: 2 additions & 2 deletions operator/deploy/cr-mysql-ha.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ spec:
# NOTE: you will need a MySQL instance, grab one with:
# helm upgrade --install mysql stable/mysql --set mysqlRootPassword=your-root-password --set mysqlDatabase=vault --set mysqlUser=vault --set mysqlPassword=secret --set 'initializationFiles.app-db\.sql=CREATE DATABASE IF NOT EXISTS app;'

# This example is best used together with deploy/test-dynamic-env-vars.yaml to demonstrate the usage of dynamic credential renewal in vault-env daemon mode.
# This example is best used together with test/deploy/test-dynamic-env-vars.yaml to demonstrate the usage of dynamic credential renewal in vault-env daemon mode.

# A YAML representation of a final vault config file, this config represents
# a HA config with MySQL.
Expand All @@ -37,7 +37,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_database
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-nodeAffinity.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-oidc.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-podAntiAffinity.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-policy-with-accessor.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ spec:
tls_key_file: /vault/tls/server.key

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-priority.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-prometheus.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ spec:
serviceRegistrationEnabled: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: prometheus-operator
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-raft-1.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ spec:
cpu: "100m"

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-raft-ha-storage.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-raft.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ spec:
cpu: "100m"

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-resource.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-statsd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr-vault-kv-unseal.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/cr.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/multi-dc/aws/cr-primary.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
2 changes: 1 addition & 1 deletion operator/deploy/multi-dc/aws/cr-secondary.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ spec:
ui: true

# See: https://banzaicloud.com/docs/bank-vaults/cli-tool/#example-external-vault-configuration
# The repository also contains a lot examples in the deploy/ and operator/deploy directories.
# The repository also contains a lot examples in the test/deploy and operator/deploy directories.
externalConfig:
policies:
- name: allow_secrets
Expand Down
Loading

0 comments on commit 1911eff

Please sign in to comment.