action when "power down" by pressing a button

I want to shutdown the BB by pressing a button. There are 3 onboard (reset, power, boot).
Reset is hard wired to really reboot the board immediately . But what I need is to do some action. I hope that “power button” does this. Therefore in one of the systemd contols I have an action:

ExecStopPost=-+/bin/cp -rap /var/lib/openhab/persistence /media/backup/

I thought that this is executed when pressing the power button, but it doesn’t seem like that. What is my fault? Why it doesn’t work? How can I figure out what’s really going on?