I am very new to Bitbucket pipelines (Beta) and docker.No previous experience on CI integration
I followed this question , But no clear description for beginners
Your command docker run -i -v $PWD:/project -t uber/android-build-environment /bin/bash /project/ci/build.sh assumes the file /project/ci/build.sh is on the container. Are you sure you're running this docker command from the directory that contains it?
If you're not sure I would try the (from your project directory)
docker run -it -v $PWD:/project uber/android-build-environment /bin/bash
and then check the results of ls -a /project when you get logged into the container.
Another thing to make sure of is that build.sh is allowed to be executed, make sure of this by running chmod +x build.sh on it.