Running a script with assets inside automator application
You can get the path to Your executable from ps command. You need to know Your app name. Here's my code with EchoPath.app made in Automator:

DIR=`ps x | grep EchoPath | grep -v grep | cut -c 28- `


Sample output:

/Users/slozo/Desktop/EchoPath.app/Contents/MacOS/Application Stub


Application Stub is the default name of the executable created in Automator. Knowing this path You can get the path to Contents dir with dirname command.