myENA / consul-backinator

Command line Consul backup and restore utility supporting KVs, ACLs and Queries
Mozilla Public License 2.0
226 stars 22 forks source link

rpc error permission denied while restoring keys to consul #38

Closed nani-ar closed 6 years ago

nani-ar commented 6 years ago

i am trying to restore keys to consul using

docker run myena/consul-backinator restore -addr=:8500 -file=s3://access key id:secret id@consul-bakup/stage-consul/2017-12-13_09:00_consul.bak?region=us-west-2

and i am getting error: rpc error permission denied

aaronhurt commented 6 years ago

That error would be coming from the destination consul cluster. Can you look at a consul monitor -log-level=debug while attempting the restore?

aaronhurt commented 6 years ago

Do you have ACLs enabled on the destination?

nani-ar commented 6 years ago

yes, we do have ACL's enabled on the destination

aaronhurt commented 6 years ago

You will need to pass an access token:

    -token           Optional consul access token
nani-ar commented 6 years ago

okie got it thanks alot!

aaronhurt commented 6 years ago

Np, you can also set it in an environment variable using CONSUL_HTTP_TOKEN