Docker Community Forums

Share and learn in the Docker community.

File not found error (resolved)

(Kalinichenko) #1

I’m trying to run our project inside linux containers emulated on Windows 10 Pro (hardware virtualization) with Docker. I need to run some script of the project, but it cannot be run because of error:

c:\plasticine>docker-compose run backend yarn generate
Starting plasticine_postgres_1 ... done
Starting plasticine_redis_1    ... done
yarn run v1.7.0
$ ./scripts/
/bin/sh: 1: ./scripts/ not found
error Command failed with exit code 127.
info Visit for documentation about this command.

I’ve checked the path:

c:\plasticine>docker-compose run backend ls scripts
Starting plasticine_postgres_1 ...
Starting plasticine_postgres_1 ... done
Starting plasticine_minio_1    ... done  db  engine

c:\plasticine>docker-compose run backend cat /src/plasticine/backend/scripts/
Starting plasticine_redis_1 ... done
Starting plasticine_minio_1 ... done
Starting plasticine_postgres_1 ... done

CURRENT_DIR=$(cd `dirname $0` && pwd)


printf "// Autogenerated file - DO NOT EDIT!!!\n\n" > index.js
printf "const plugins = {};\n\n" >> index.js

for dir in $PLUGINS_DIR*/; do
  if [[ -d $dir ]]; then

    printf "import $dir from './$dir';\n" >> index.js
    printf "plugins[$] = $dir.plugin;\n\n" >> index.js

What’s wrong?

I’ve found the solution. The reason was crlf, i’m using *nix container, so repository clone on windows should have the same new line characters as under linux.

git config --global core.autocrlf false