Those are all valid
manual ways but I want to have my node do do this automatically. I should have been more precise in communicating my final goal:
I want to set-up the node in such a way that - once it has a power failure and power comes back - everything auto-starts without me setting groups, links or permissions.
- power comes back, Pi OS starts
- systemctl starts bitcoind which creates the .cookie file
- once bitcoind is up, systemctl starts the indexer
So I could write a script which looks for the .cookie file and once it is created by bitcoind changes group and permissions. systemctl would have to wait for this script to finish before bringing the indexer back up since its user needs the permissions to work properly. I just though there is an easier way provided by bitcoind itself, as I thought that's the whole point of the .cookie file.