How to set my own root token in HashiCorp Vault Docker Compose file
With my current Vault docker compose file, I'm not able to login with my token which I've set as part of my docker compose file. When Vault container starts up - it provides his own root token to authenticate in vault server. And this keep on change whenever we bring up new container and developer has to note it down from the console every-time and use that token to login in Vault.
Instead of that I want to set as part of docker compose file - How can I do that.
Please find my docker compose file below:
version: '3' services: myvault: image: vault container_name: myvault ports: - "192.168.99.100:8200:8200" environment: VAULT_SERVER: "http://192.168.99.100:8200" TOKEN: mysuper-secret-vault-token volumes: - ./file:/vault/file:rw - ./config:/vault/config:rw cap_add: - IPC_LOCK
This title and content for this question was made by "Learn Java" at this link: https://stackoverflow.com/questions/50010728/how-to-set-my-own-root-token-in-hashicorp-vault-docker-compose-file. Contributions on stackoverflow.com are made under this license.