As luck would have it I just spent a very frustrating couple of weeks banging my head against a wall chasing something just like this down and have finally got shell commands. Previously I could not seem to run any shell commands at all. They would appear to run but nothing was achieved.
I think you need to specify a path to the backup_config.sh file you created.
backup_config: /home/hass/.homeassistant/script_folder_location/backup_config.sh
You might need to make sure this file is executable.
$ chmod 755 your/path/to/backup_config.sh
These are probably not your problem but may help someone else searching like I was…
I had a few problems, one was trying to use directories - ie/ shell_command: !include_dir_named shell_commands. I had no errors but once I changed from directories to shell_command: !include shell_commands.yaml my shell commands started actually firing rather than just pretending to fire.
Next - line endings! I was using a windows computer with atom to create my sh files. Apparently if you do this you need to specify Unix line endings or you will get Dos line endings and the script will not work. I am a beginner and was blissfully unaware of this. Copying the script commands and pasting it into putty will work fine but running the .sh file files fails because of these line endings.
In Atom, in the bottom right hand corner there are a couple of file descriptors which will typically say CRLF UTF-8 Shell Script you need to set CRLF to LF by clicking on it and then save file. Notepad++ will say Dos/Windows - change to UNIX format and resave. This will not be a problem if you are using $ sudo nano backupconfig.sh to create your .sh files in the first place.
And for some commands I need to include bash at the start.
backup_config: bash /home/hass/.homeassistant/script_folder_location/backup_config.sh
I can’t explain this to you as I am trying to understand it myself - I just know that it worked.