Replies: 1 comment 3 replies
-
@pschisa Is there a way to restrict access to Vault based on which |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hashicorp Vault is a secure secrets manager that offers a CLI tool for interacting with the Vault application. Here is how you can continue to utilize the Vault CLI tool when Vault is secured behind Teleport Application Access (on-prem or cloud).
Before you begin: Make sure you have already deployed/unsealed the Vault application, you have credentials to access Vault, and have downloaded the Vault CLI tool to your local machine
Configure Vault as a Teleport application and verify that it is accessible via the Teleport Web UI. Please follow the Application Access installation instructions provided on our website: https://goteleport.com/docs/application-access/guides/connecting-apps/.
Log in to the Teleport proxy using
tsh login --proxy=<proxy-URL>
. After a successful login, you should now be able to view your configured Vault application using the commandtsh apps ls
.Log in to the application with
tsh apps login <vault-app-name>
. If successful, you should see output indicating you logged in successfully and an example curl command. The example curl command shows the CA cert, Cert, and Key file locations along with the Vault application public URL through Teleport. We will use the full URL (including https://), cert file path, and key file path (not the cacert) in the next step. Once logged in to an application, you can always review this information with the commandtsh apps config
.Export the following necessary Vault CLI environmental variables on your local machine using the information obtained during login
export VAULT_ADDR=https://<Teleport-Vault-App-URL>
export VAULT_CLIENT_CERT=<Cert-File-Path-From-App-Config>
export VAULT_CLIENT_KEY=<Key-File-Path-From-App-Config>
After exporting the variables, you should now be able to issue
vault login
successfully to begin Vault authentication and then execute Vault commands.Example work flow:
Beta Was this translation helpful? Give feedback.
All reactions