Hello I am trying to execute a sh script via cronjob.
My script:
#!/bin/bash
#!/usr/bin/expect -f
IP=$(hostname -I | awk '{print $2}')
echo $IP
echo "Verbindung zum Server aufbauen"
So what I am trying to do is, I need the IP of my Raspberry Pi and start a server via ssh. When I execute the script via terminal it works fine.