2

I'm having problems with starting my containers via docker-compose up.

I guess this is an Windows problem, because my colleague owns a macbook and has now problems when he runs docker-compose up.

ERROR: for oracle-apex Cannot start service oracle-apex: oci runtime error: container_linux.go:265: starting container process caused "exec: \"/temp/entrypoint.sh\": stat /temp/entrypoint.sh: no such file or directory"

The directory docker/apex/scripts does exists on my machine, isn't empty and contains the file entrypoint.sh. I've found some similar problems when I've googled for this error, which told me to create a env file with COMPOSE_CONVERT_WINDOWS_PATHS=1, what I've done.

Versions:

Docker version 1.13.1, build 092cba3   
docker-compose version 1.8.0,build unknown  
Windows 10

docker-compose.yml

version: '2'
services:
  proxy:
    build: ./docker/proxy/
    container_name: searchkit_proxy
    ports:
      - "8000:80"
    volumes:
      - ./docker/searchkit-v2/dist:/public/static
  oracle-apex:
    image: araczkowski/oracle-apex-ords
    container_name: vanditmar-apex
    volumes:
      - ./docker/apex/scripts/:/temp/
    ports:
      - "49160:22"
      - "8080:8080"
      - "1521:1521"
    entrypoint: ["/temp/entrypoint.sh"]
volumes:
  esdata1:
    driver: local
  oracle-data:
    driver: local
networks:
  esnet:

Dockerfile in folder docker/apex/

FROM araczkowski/oracle-apex-ords
ADD ./scripts/ /temp/
RUN /temp/install.sh

entrypoint.sh

#!/bin/bash

exec >> >(tee -ai /docker_log.txt)
exec 2>&1

# # Update hostname
sed -i -E "s/HOST = [^)]+/HOST = $HOSTNAME/g" /u01/app/oracle/product/11.2.0/xe/network/admin/listener.ora
sed -i -E "s/HOST = [^)]+/HOST = $HOSTNAME/g" /u01/app/oracle/product/11.2.0/xe/network/admin/tnsnames.ora
sed -i -E "s/PORT = [^)]+/PORT = 1521/g" /u01/app/oracle/product/11.2.0/xe/network/admin/listener.ora
#
/etc/init.d/oracle-xe start
/etc/init.d/tomcat start
/etc/init.d/ssh start
/temp/install.sh

##
## Workaround for graceful shutdown. ....ing oracle... ‿( ́ ̵ _-`)‿
##
while [ "$END" == '' ]; do
    sleep 1
    trap "/etc/init.d/oracle-xe stop && END=1" INT TERM
done
;;

I'm new to docker, but I would like to know how to fix this problem. We think the problem is that the paths to the files are different on windows.

I use Bash on Ubuntu on Windows as command line. If there is any information missing please tell me, so I can add it :)

Elvira
  • 1,410
  • 5
  • 23
  • 50
  • What are the contents of the /temp/entrypoint.sh, does the command/shell listed in the first line exist inside your container, and do you have windows or linux line endings inside the file? – BMitch Dec 06 '17 at 13:56
  • I added the /temp/entrypoint.sh. – Elvira Dec 06 '17 at 14:08
  • That entrypoint has multiple issues, the first of which is confusing a container for a VM. You also seem to have missed the other questions being asked. – BMitch Dec 06 '17 at 14:18
  • I’m sorry for not fully answering your questions. What do you mean with first line? The bin/bash? And how can I see the difference between linux and windows endings? – Elvira Dec 06 '17 at 15:25

0 Answers0