dockerhub build fails requirements.txt not found

  docker, dockerhub

I am building a Docker image for some python packages, for which I using requirements.txt to install all python packages by pip.

I have all Dockerfile, requirements.txt, and related python scripts in the subfolder of my GitHub repo.

-> Main repo
---> folder
    --> some python scripts
    --> docker_folder
       --> Dockerfile
       --> requirements.txt
---> some files
---> some files

I have built the image locally which works fine but while configuring autobuild in Docker Hub it throws an error by stating that requirements.txt not found but it found Dockerfile. I have changed the Dockerfile location in the build setting on Docker Hub by:folder/docker_folder/Dockerfile.

I think the main problem lies in the Build configuration setting. Any help? Thanks.

logfile from Dockerhub built:

Cloning into '.'...
Warning: Permanently added the RSA host key for IP address '' to the list of known hosts.
Reset branch 'master'
Your branch is up-to-date with 'origin/master'.
KernelVersion: 4.4.0-1060-aws
Components: [{u'Version': u'19.03.8', u'Name': u'Engine', u'Details': {u'KernelVersion': u'4.4.0-1060-aws', u'Os': u'linux', u'BuildTime': u'2020-03-11T01:24:30.000000000+00:00', u'ApiVersion': u'1.40', u'MinAPIVersion': u'1.12', u'GitCommit': u'afacb8b7f0', u'Arch': u'amd64', u'Experimental': u'false', u'GoVersion': u'go1.12.17'}}, {u'Version': u'1.2.13', u'Name': u'containerd', u'Details': {u'GitCommit': u'7ad184331fa3e55e52b890ea95e65ba581ae3429'}}, {u'Version': u'1.0.0-rc10', u'Name': u'runc', u'Details': {u'GitCommit': u'dc9208a3303feef5b3839f4323d9beb36df0a9dd'}}, {u'Version': u'0.18.0', u'Name': u'docker-init', u'Details': {u'GitCommit': u'fec3683'}}]
Arch: amd64
BuildTime: 2020-03-11T01:24:30.000000000+00:00
ApiVersion: 1.40
Platform: {u'Name': u'Docker Engine - Community'}
Version: 19.03.8
MinAPIVersion: 1.12
GitCommit: afacb8b7f0
Os: linux
GoVersion: go1.12.17
Starting build of
Step 1/5 : FROM python:3.8
---> 8f6adb7689b5
Step 2/5 : WORKDIR ${PWD}/..
---> Running in 516d190b493f
Removing intermediate container 516d190b493f
---> e948c6e6f641
Step 3/5 : COPY requirements.txt ./
COPY failed: stat /var/lib/docker/tmp/docker-builder968608568/requirements.txt: no such file or directory

Source: Docker Questions