# Howto install a package/binary in vault-agent container?

**URL:** <https://discuss.hashicorp.com/t/howto-install-a-package-binary-in-vault-agent-container/21595>\
**Category:** Vault\
**Tags:** k8s\
**Created:** [March 2, 2021, 5:18pm UTC](https://discuss.hashicorp.com/t/howto-install-a-package-binary-in-vault-agent-container/21595 "2021-03-02T17:18:19Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![mouglou](https://sea2.discourse-cdn.com/hashicorp/user_avatar/discuss.hashicorp.com/mouglou/32/7594_2.png) [@mouglou](https://discuss.hashicorp.com/u/mouglou)\
**Post date:** [March 2, 2021, 5:18pm UTC](https://discuss.hashicorp.com/t/howto-install-a-package-binary-in-vault-agent-container/21595/1 "2021-03-02T17:18:20Z")

</div>

Hello !

Question about the Vault injector.

We use the vaut-injector to insert databases and others engines credentials inside our pods.  
We have a Vault kubernetes role with max\_ttl to 1h. So when 2/3 of this time is reach, so 40m, it generate new credentials. Its working great. But the application can’t hot reload with these new credentials.

The goal is when this 2/3 of the max\_ttl is reach, we want to generate new pods, with their own new credentials, and let the older one revoke his credentials and die…

So we add this annotations:

> [vault.hashicorp.com/agent-inject-command-app:](http://vault.hashicorp.com/agent-inject-command-app:) kubectl rollout restart deployment application

I found that the define command is running on the vault-injector container. Not our application container.

But the kubectl binary have been installed on our container. And it seems that we can’t add package or binary to the vault-injector container.

So how do we do that with a non-system command ? With consul-template on standard vm, no problem, we can execute whatever we want.

Hope there is a solution to that !  
FYI: I set the rbac permission and try to run the kubectl command on our application and its working great.

Thanks !

---

<div class="post-metadata">

**Author:** ![mouglou](https://sea2.discourse-cdn.com/hashicorp/user_avatar/discuss.hashicorp.com/mouglou/32/7594_2.png) [@mouglou](https://discuss.hashicorp.com/u/mouglou)\
**Post date:** [March 4, 2021, 8:37pm UTC](https://discuss.hashicorp.com/t/howto-install-a-package-binary-in-vault-agent-container/21595/2 "2021-03-04T20:37:38Z")

</div>

Hello !

Nobody try to run the kubectl command in the agent-inject-ommand ?  
Are we the first ?! I can’t believe that !

Or maybe is that another solution from Vault to rollout restart the pods when 2/3 is reached exist ?  
If yes, I am open to learn and test !

See you !
