acmesh-official / acme.sh

A pure Unix shell script implementing ACME client protocol
https://acme.sh
GNU General Public License v3.0
38.79k stars 4.92k forks source link

Dynamic variables names for _readaccountconf_mutable and _saveaccountconf_mutable #5186

Open woxxo opened 3 months ago

woxxo commented 3 months ago

I'd like to write my own dnsapi script for a specific cloud hoster, and have to save and load the value of a variable with dynamically generated name. This variable name will be generated at runtime.

So, I have to change this Token1="${My_Token:-$(_readaccountconf_mutable My_Token)}" _saveaccountconf_mutable My_Token "$Token1"

to somethig like this: Var_Name="My_Token" Token1="${???Var_Name???:-$(_readaccountconf_mutable ???Var_Name???)}" _saveaccountconf_mutable ???Var_Name??? "$Token1"

Any idea on how to implement this? Thank you in advance!

github-actions[bot] commented 3 months ago

Please upgrade to the latest code and try again first. Maybe it's already fixed. acme.sh --upgrade If it's still not working, please provide the log with --debug 2, otherwise, nobody can help you.