-
Notifications
You must be signed in to change notification settings - Fork 760
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
./scripts/init_submodules.sh: not found #819
Comments
That's ..... strange. This usually points to some sort of version mismatch (i.e. you are docker-pull'ing from one version but using the |
It might help if, instead of doing |
Thanks @stanley-cheung but No luck still the same error. PS C:\Users\deryy> cd .\grpc-web\
PS C:\Users\deryy\grpc-web> docker build common prereqs node-server envoy commonjs-client
"docker build" requires exactly 1 argument.
See 'docker build --help'.
Usage: docker build [OPTIONS] PATH | URL | -
Build an image from a Dockerfile
PS C:\Users\deryy\grpc-web> docker-compose build common prereqs node-server envoy commonjs-client
Building common
Step 1/8 : FROM node:10-stretch
10-stretch: Pulling from library/node
1c6172af85ee: Pull complete
b194b0e3c928: Pull complete
1f5ec00f35d5: Pull complete
93b1353672b6: Pull complete
3d7f38db3cca: Pull complete
21e102f9fe89: Pull complete
1f9c0020f4f4: Pull complete
5ab83c758454: Pull complete
654868f0dc71: Pull complete
Digest: sha256:0e2671bc0702132989b2b5142617d47c421bd304acd924fbff812370f6107db2
Status: Downloaded newer image for node:10-stretch
---> c5f1efe092a0
Step 2/8 : RUN apt-get -qq update && apt-get -qq install -y unzip
---> Running in 203ca36ca73f
Removing intermediate container 203ca36ca73f
---> 6ab79bfd41f9
Step 3/8 : WORKDIR /tmp
---> Running in 42b75e237dc1
Removing intermediate container 42b75e237dc1
---> 2579793e2736
Step 4/8 : RUN curl -sSL https://github.com/protocolbuffers/protobuf/releases/download/v3.11.4/protoc-3.11.4-linux-x86_64.zip -o protoc.zip && unzip -qq protoc.zip && cp ./bin/protoc /usr/local/bin/protoc
---> Running in 9ccb831881f8
Removing intermediate container 9ccb831881f8
---> 692c8ffac08a
Step 5/8 : RUN curl -sSL https://github.com/grpc/grpc-web/releases/download/1.0.7/protoc-gen-grpc-web-1.0.7-linux-x86_64 -o /usr/local/bin/protoc-gen-grpc-web && chmod +x /usr/local/bin/protoc-gen-grpc-web
---> Running in 5287045dee9a
Removing intermediate container 5287045dee9a
---> 6de8de2871a4
Step 6/8 : WORKDIR /var/www/html/dist
---> Running in cf1b311bc305
Removing intermediate container cf1b311bc305
---> 8ba6094a8116
Step 7/8 : WORKDIR /github/grpc-web
---> Running in c21589c6196d
Removing intermediate container c21589c6196d
---> 1e5bbd3222c1
Step 8/8 : RUN git clone https://github.com/grpc/grpc-web .
---> Running in 639060a9cf22
Cloning into '.'...
Removing intermediate container 639060a9cf22
---> 1cf64ec8b52d
Successfully built 1cf64ec8b52d
Successfully tagged grpcweb/common:latest
Building prereqs
Step 1/18 : FROM grpcweb/common
---> 1cf64ec8b52d
Step 2/18 : ARG MAKEFLAGS=-j8
---> Running in e7bdd7922d1e
Removing intermediate container e7bdd7922d1e
---> 5f64de76fefe
Step 3/18 : ARG BUILDIFIER_VERSION=1.0.0
---> Running in d41805916cd5
Removing intermediate container d41805916cd5
---> 93f81a2a25b1
Step 4/18 : ARG BAZEL_VERSION=2.2.0
---> Running in b7e49894fe01
Removing intermediate container b7e49894fe01
---> 22a204ef4fd7
Step 5/18 : RUN echo "\nloglevel=error\n" >> $HOME/.npmrc
---> Running in a5d6376862ba
Removing intermediate container a5d6376862ba
---> 3ba973e5ddb5
Step 6/18 : WORKDIR /github/grpc-web
---> Running in 4ac72d8c1a08
Removing intermediate container 4ac72d8c1a08
---> 643e67349a5c
Step 7/18 : COPY ./Makefile ./Makefile
---> a96a7278bee4
Step 8/18 : COPY ./bazel ./bazel
---> 8e8753ae4469
Step 9/18 : COPY ./javascript ./javascript
---> 30de9a4b504f
Step 10/18 : COPY ./net ./net
---> 034d981f2332
Step 11/18 : COPY ./packages ./packages
---> 61134e227ce5
Step 12/18 : COPY ./scripts ./scripts
---> 1f18f76e61e2
Step 13/18 : COPY ./test ./test
---> d0fa541d8fdf
Step 14/18 : RUN ./scripts/init_submodules.sh
---> Running in cea0d62781db
/bin/sh: 1: ./scripts/init_submodules.sh: not found
ERROR: Service 'prereqs' failed to build: The command '/bin/sh -c ./scripts/init_submodules.sh' returned a non-zero code: 127
|
I really have no idea. Can you double check if you really have that file |
have same problem here |
same issue for me Windows 10 Pro |
@stanley-cheung |
@EmileMaras Sorry, typo, should be |
Thanks @stanley-cheung |
@EmileMaras Can you check whether the file |
yes it is executable |
Anybody have any idea here? I am really at a loss here. |
Maybe it is that bug? https://stackoverflow.com/questions/29045140/env-bash-r-no-such-file-or-directory In dockerfile add sed COPY ./test ./test |
Hi @YuriyKrasilnikov : You are right! I changed the \scripts\init_submodules.sh file format from CRLF to LF and the error mentioned above is gone!👍 However, Now new error encountered: Updated \net\grpc\gateway\docker\prereqs\Dockerfile args BUILDIFIER_VERSION & BAZEL_VERSION to latest 3.3.0 still see the same error. |
The buildifier error could be caused by this change. |
Thank you so much @daserge ! |
This doesn't help: |
@TimorTartakovsky , you have to do either of the following (note, I had to do 2 to get fully working, see comments afterwards). 1: open up the init_submodules.sh and change line encoding to unix: above example is in sublime text.
The error is misleading because it apparently has to do with line endings. I should state that I had issues with just doing 1. and hit a different error afterwards. I ended up changing my git config autocrlf to false, rechecked out the repo to a fresh copy and then I was able to get things fully to work though. |
Window 10: Try to follow this and failed on last step.
$ git clone https://github.com/grpc/grpc-web
$ cd grpc-web
$ docker-compose pull
$ docker-compose up -d node-server envoy commonjs-client
Here is the console output:
PS C:\github> git clone https://github.com/grpc/grpc-web
Cloning into 'grpc-web'...
remote: Enumerating objects: 95, done.
remote: Counting objects: 100% (95/95), done.
remote: Compressing objects: 100% (59/59), done.
remote: Total 4706 (delta 19), reused 58 (delta 14), pack-reused 4611
Receiving objects: 100% (4706/4706), 911.77 KiB | 5.21 MiB/s, done.
Resolving deltas: 100% (2337/2337), done.
PS C:\github> cd grpc-web
PS C:\github\grpc-web> docker-compose pull
Pulling common ... done
Pulling prereqs ... done
Pulling grpc-base ... done
Pulling echo-server ... done
Pulling node-server ... done
Pulling node-interop-server ... done
Pulling envoy ... done
Pulling nginx ... done
Pulling grpcwebproxy ... done
Pulling commonjs-client ... done
Pulling closure-client ... done
Pulling ts-client ... done
Pulling binary-client ... done
Pulling interop-client ... done
WARNING: Some service image(s) must be built from source by running:
docker-compose build interop-client closure-client node-interop-server prereqs grpcwebproxy grpc-base binary-client echo-server nginx ts-client
PS C:\github\grpc-web> docker-compose up -d node-server envoy commonjs-client
Building prereqs
Step 1/18 : FROM grpcweb/common
---> c8ec1e686813
Step 2/18 : ARG MAKEFLAGS=-j8
---> Using cache
---> 5193700fd512
Step 3/18 : ARG BUILDIFIER_VERSION=1.0.0
---> Using cache
---> 805a4392af84
Step 4/18 : ARG BAZEL_VERSION=2.2.0
---> Using cache
---> 60213041609a
Step 5/18 : RUN echo "\nloglevel=error\n" >> $HOME/.npmrc
---> Using cache
---> 24ce4ae224ec
Step 6/18 : WORKDIR /github/grpc-web
---> Using cache
---> 824b0de4e01e
Step 7/18 : COPY ./Makefile ./Makefile
---> Using cache
---> f876f09b9683
Step 8/18 : COPY ./bazel ./bazel
---> Using cache
---> da18e70f7fe7
Step 9/18 : COPY ./javascript ./javascript
---> Using cache
---> 495bcd2cac24
Step 10/18 : COPY ./net ./net
---> Using cache
---> 439bc1048909
Step 11/18 : COPY ./packages ./packages
---> Using cache
---> 46ddafa3bf85
Step 12/18 : COPY ./scripts ./scripts
---> Using cache
---> 7e0e1cdfdeb5
Step 13/18 : COPY ./test ./test
---> Using cache
---> 1116ae0a37c5
Step 14/18 : RUN ./scripts/init_submodules.sh
---> Running in c6bc4a894ead
/bin/sh: 1: ./scripts/init_submodules.sh: not found
ERROR: Service 'prereqs' failed to build: The command '/bin/sh -c ./scripts/init_submodules.sh' returned a non-zero code: 127
PS C:\github\grpc-web> ls -l ./scripts/init_submodules.sh
Mode LastWriteTime Length Name
-a---- 2020-05-23 11:25 PM 936 init_submodules.sh
The text was updated successfully, but these errors were encountered: