To run multiple services in a single container there are multiple ways
With a script:
Example of script:
#!/bin/bash
set -m # to make job control work
/app/server &
/app/server -bar &
fg %1
Docker file with the ENTRYPOINT instruction
ADD multiple.sh /app/
ENTRYPOINT /app/multiple.sh
A process manager can start more than one process.
Example with overmind
web: bundle exec rails server -p $PORT
foo: /app/foo
ADD Procfile /app/
CMD overmind start