How to generate and renew vault token inside docker container

You should’t hardcode any secrets. If you run in kubernetes you could use a workload identity for authentication with Vault, e.g. native K8s auth method, or JWT.