Closed ghost closed 7 years ago
I suppose that could be added. One my goals with acl create
and acl update
was to avoid having to write a json or hcl policy files.
We'd like to keep the same syntax as the official doc. Whether in a policy file or pipe in a script. It'll keep our code base cleaner.
This sure would be a nice feature to have. :-D
The ACL create and update should be able to accept ACLs in HCL and JSON as specified here: https://www.consul.io/docs/internals/acl.html.
Preferably this would be via file or '-' for stdin.
Work around: curl -X PUT -d "{\"Name\":\"agent\",\"Rules\":\"$(cat __ | tr -d '\n\t' | sed s/\"/\\"/g)\"}" http://localhost:8500/v1/acl/create