The join script is not run inside the container. It is run on the outside (because not all containers can run join scripts - not all containers are based on appbox).
You want a script that is run inside the container. In this case, setup
would be the correct one.
I used this opportunity to add a snippet to our documentation about the various scripts:
https://wiki.univention.de/index.php/Docker_Apps/Container_Scripts#setup_in_UCS_based_containers
Note that for appbox Apps, you could just download the packages on a full UCS server with unmaintained enabled (ucr set repository/online/unmaintained=yes && apt update && apt download ...
) and then upload these packages to your repository in the App Center.