Skip to content

Commit b48ebd1

Browse files
committed
Fix git submodule in docker
1 parent c043d71 commit b48ebd1

File tree

3 files changed

+6
-10
lines changed

3 files changed

+6
-10
lines changed

paddle/scripts/docker/Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,6 @@ RUN apt-get update && \
3434

3535
# git credential to skip password typing
3636
RUN git config --global credential.helper store
37-
# fetch PaddlePaddle book
38-
RUN git submodule update --init --recursive
3937

4038
# Fix locales to en_US.UTF-8
4139
RUN localedef -i en_US -f UTF-8 en_US.UTF-8
@@ -52,7 +50,9 @@ RUN curl -sSL https://cmake.org/files/v3.4/cmake-3.4.1.tar.gz | tar -xz && \
5250
cd .. && rm -rf cmake-3.4.1
5351

5452
COPY . /paddle/
53+
RUN cd /paddle/ && git submodule update --init --recursive
5554
RUN /paddle/paddle/scripts/docker/build.sh
55+
5656
VOLUME ["/usr/share/nginx/html/data", "/usr/share/nginx/html/paddle"]
5757

5858
# Configure OpenSSH server. c.f. https://docs.docker.com/engine/examples/running_ssh_service

paddle/scripts/docker/Dockerfile.gpu

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,6 @@ RUN apt-get update && \
3434

3535
# git credential to skip password typing
3636
RUN git config --global credential.helper store
37-
# fetch PaddlePaddle book
38-
RUN git submodule update --init --recursive
3937

4038
# Fix locales to en_US.UTF-8
4139
RUN localedef -i en_US -f UTF-8 en_US.UTF-8
@@ -52,7 +50,9 @@ RUN curl -sSL https://cmake.org/files/v3.4/cmake-3.4.1.tar.gz | tar -xz && \
5250
cd .. && rm -rf cmake-3.4.1
5351

5452
COPY . /paddle/
53+
RUN cd /paddle/ && git submodule update --init --recursive
5554
RUN /paddle/paddle/scripts/docker/build.sh
55+
5656
VOLUME ["/usr/share/nginx/html/data", "/usr/share/nginx/html/paddle"]
5757

5858
# Configure OpenSSH server. c.f. https://docs.docker.com/engine/examples/running_ssh_service

paddle/scripts/docker/entrypoint

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,4 @@
11
#!/bin/bash
2-
LOG=/var/log/all
32

4-
touch $LOG
5-
6-
/usr/sbin/sshd -D >> $LOG &
7-
jupyter notebook --ip=0.0.0.0 /paddle/book/ >> $LOG &
8-
tail -f $LOG
3+
/usr/sbin/sshd -D &
4+
jupyter notebook --ip=0.0.0.0 /paddle/book/

0 commit comments

Comments
 (0)