openach / docker-openach

Docker with OpenACH, running Apache, mod_php, and SQLite
GNU General Public License v3.0
16 stars 25 forks source link

Action '-D FOREGROUND' failed. #1

Closed Juni4567 closed 4 years ago

Juni4567 commented 6 years ago

Having this issue when I try to run docker-openach on my local computer. docker-compose up gives the following output

web_1  | Action '-D FOREGROUND' failed.
web_1  | The Apache error log may have more information.
dockeropenach_web_1 exited with code 1

docker-compose --verbose up gives the following output

compose.config.config.find: Using configuration files: .\docker-compose.yml
docker.utils.config.find_config_file: Trying paths: ['C:\\Users\\juni\\.docker\\config.json', 'C:\\Users\\juni\\.dockercfg']
docker.utils.config.find_config_file: No config file found
docker.utils.config.find_config_file: Trying paths: ['C:\\Users\\juni\\.docker\\config.json', 'C:\\Users\\juni\\.dockercfg']
docker.utils.config.find_config_file: No config file found
urllib3.connectionpool._new_conn: Starting new HTTPS connection (1): 192.168.99.100
urllib3.connectionpool._make_request: https://192.168.99.100:2376 "GET /v1.22/version HTTP/1.1" 200 545
compose.cli.command.get_client: docker-compose version 1.20.1, build 5d8c71b2
docker-py version: 3.1.4
CPython version: 3.6.4
OpenSSL version: OpenSSL 1.0.2k  26 Jan 2017
compose.cli.command.get_client: Docker base_url: https://192.168.99.100:2376
compose.cli.command.get_client: Docker version: Platform={'Name': ''}, Components=[{'Name': 'Engine', 'Version': '18.06.1-ce', 'Details': {'ApiVersion': '1.38', 'Arch': 'amd64', 'BuildTime': '2018-08-21T17:28:38.000000000+00:00', 'Experimental': 'false', 'GitCommit': 'e68fc7a', 'GoVersion': 'go1.10.3', 'KernelVersion': '4.9.93-boot2docker', 'MinAPIVersion':'1.12', 'Os': 'linux'}}], Version=18.06.1-ce, ApiVersion=1.38, MinAPIVersion=1.12, GitCommit=e68fc7a, GoVersion=go1.10.3, Os=linux, Arch=amd64, KernelVersion=4.9.93-boot2docker, BuildTime=2018-08-21T17:28:38.000000000+00:00
compose.cli.verbose_proxy.proxy_callable: docker info <- ()
urllib3.connectionpool._make_request: https://192.168.99.100:2376 "GET /v1.22/info HTTP/1.1" 200 None
compose.cli.verbose_proxy.proxy_callable: docker info -> {'Architecture': 'x86_64',
 'BridgeNfIp6tables': True,
 'BridgeNfIptables': True,
 'CPUSet': True,
 'CPUShares': True,
 'CgroupDriver': 'cgroupfs',
 'ClusterAdvertise': '',
 'ClusterStore': '',
 'ContainerdCommit': {'Expected': '468a545b9edcd5932818eb9de8e72413e616e86e',
                      'ID': '468a545b9edcd5932818eb9de8e72413e616e86e'},
...
compose.cli.verbose_proxy.proxy_callable: docker inspect_network <- ('dockeropenach_default')
urllib3.connectionpool._make_request: https://192.168.99.100:2376 "GET /v1.22/networks/dockeropenach_default HTTP/1.1" 200 445
compose.cli.verbose_proxy.proxy_callable: docker inspect_network -> {'Attachable': False,
 'ConfigFrom': {'Network': ''},
 'ConfigOnly': False,
 'Containers': {},
 'Created': '2018-11-02T15:05:54.187390491Z',
 'Driver': 'bridge',
 'EnableIPv6': False,
 'IPAM': {'Config': [{'Gateway': '172.18.0.1', 'Subnet': '172.18.0.0/16'}],
          'Driver': 'default',
          'Options': None},
...
compose.cli.verbose_proxy.proxy_callable: docker containers <- (all=False, filters={'label': ['com.docker.compose.project=dockeropenach', 'com.docker.compose.oneoff=False']})
urllib3.connectionpool._make_request: https://192.168.99.100:2376 "GET /v1.22/containers/json?limit=-1&all=0&size=0&trunc_cmd=0&filters=%7B%22label%22%3A+%5B%22com.docker.compose.project%3Ddockeropenach%22%2C+%22com.docker.compose.oneoff%3DFalse%22%5D%7D HTTP/1.1" 200 3
compose.cli.verbose_proxy.proxy_callable: docker containers -> (list with 0 items)
compose.cli.verbose_proxy.proxy_callable: docker containers <- (all=True, filters={'label': ['com.docker.compose.project=dockeropenach', 'com.docker.compose.service=web', 'com.docker.compose.oneoff=False']})
urllib3.connectionpool._make_request: https://192.168.99.100:2376 "GET /v1.22/containers/json?limit=-1&all=1&size=0&trunc_cmd=0&filters=%7B%22label%22%3A+%5B%22com.docker.compose.project%3Ddockeropenach%22%2C+%22com.docker.compose.service%3Dweb%22%2C+%22com.docker.compose.oneoff%3DFalse%22%5D%7D HTTP/1.1" 200 1545
compose.cli.verbose_proxy.proxy_callable: docker containers -> (list with 1 items)
compose.cli.verbose_proxy.proxy_callable: docker inspect_container <- ('edc148aa1f00dbd38577646690fcb7baf3b9c0f3f7ca6c4d03841a624eac6960')
urllib3.connectionpool._make_request: https://192.168.99.100:2376 "GET /v1.22/containers/edc148aa1f00dbd38577646690fcb7baf3b9c0f3f7ca6c4d03841a624eac6960/json HTTP/1.1" 200 None
compose.cli.verbose_proxy.proxy_callable: docker inspect_container -> {'AppArmorProfile': '',
 'Args': ['/openach-start'],
 'Config': {'ArgsEscaped': True,
            'AttachStderr': False,
            'AttachStdin': False,
            'AttachStdout': False,
            'Cmd': ['bash', '/openach-start'],
            'Domainname': '',
            'Entrypoint': None,
            'Env': ['PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin',
...
compose.cli.verbose_proxy.proxy_callable: docker inspect_image <- ('openach/openach')
urllib3.connectionpool._make_request: https://192.168.99.100:2376 "GET /v1.22/images/openach/openach/json HTTP/1.1" 200 None
compose.cli.verbose_proxy.proxy_callable: docker inspect_image -> {'Architecture': 'amd64',
 'Author': 'Steven Brendtro <info@openach.com>',
 'Comment': '',
 'Config': {'ArgsEscaped': True,
            'AttachStderr': False,
            'AttachStdin': False,
            'AttachStdout': False,
            'Cmd': ['bash', '/openach-start'],
            'Domainname': '',
            'Entrypoint': None,
...
compose.cli.verbose_proxy.proxy_callable: docker containers <- (all=True, filters={'label': ['com.docker.compose.project=dockeropenach', 'com.docker.compose.service=web', 'com.docker.compose.oneoff=False']})
urllib3.connectionpool._make_request: https://192.168.99.100:2376 "GET /v1.22/containers/json?limit=-1&all=1&size=0&trunc_cmd=0&filters=%7B%22label%22%3A+%5B%22com.docker.compose.project%3Ddockeropenach%22%2C+%22com.docker.compose.service%3Dweb%22%2C+%22com.docker.compose.oneoff%3DFalse%22%5D%7D HTTP/1.1" 200 1545
compose.cli.verbose_proxy.proxy_callable: docker containers -> (list with 1 items)
compose.cli.verbose_proxy.proxy_callable: docker inspect_image <- ('openach/openach')
urllib3.connectionpool._make_request: https://192.168.99.100:2376 "GET /v1.22/images/openach/openach/json HTTP/1.1" 200 None
compose.cli.verbose_proxy.proxy_callable: docker inspect_image -> {'Architecture': 'amd64',
 'Author': 'Steven Brendtro <info@openach.com>',
 'Comment': '',
 'Config': {'ArgsEscaped': True,
            'AttachStderr': False,
            'AttachStdin': False,
            'AttachStdout': False,
            'Cmd': ['bash', '/openach-start'],
            'Domainname': '',
            'Entrypoint': None,
...
compose.cli.verbose_proxy.proxy_callable: docker inspect_container <- ('edc148aa1f00dbd38577646690fcb7baf3b9c0f3f7ca6c4d03841a624eac6960')
urllib3.connectionpool._make_request: https://192.168.99.100:2376 "GET /v1.22/containers/edc148aa1f00dbd38577646690fcb7baf3b9c0f3f7ca6c4d03841a624eac6960/json HTTP/1.1" 200 None
compose.cli.verbose_proxy.proxy_callable: docker inspect_container -> {'AppArmorProfile': '',
 'Args': ['/openach-start'],
 'Config': {'ArgsEscaped': True,
            'AttachStderr': False,
            'AttachStdin': False,
            'AttachStdout': False,
            'Cmd': ['bash', '/openach-start'],
            'Domainname': '',
            'Entrypoint': None,
            'Env': ['PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin',
...
compose.parallel.feed_queue: Pending: {<Service: web>}
compose.parallel.feed_queue: Starting producer thread for <Service: web>
Starting dockeropenach_web_1 ...
compose.parallel.feed_queue: Pending: {<Container: dockeropenach_web_1 (edc148)>}
compose.parallel.feed_queue: Starting producer thread for <Container: dockeropenach_web_1 (edc148)>
compose.cli.verbose_proxy.proxy_callable: docker attach <- ('edc148aa1f00dbd38577646690fcb7baf3b9c0f3f7ca6c4d03841a624eac6960', stdout=True, stderr=True, stream=True)
urllib3.connectionpool._make_request: https://192.168.99.100:2376 "POST /v1.22/containers/edc148aa1f00dbd38577646690fcb7baf3b9c0f3f7ca6c4d03841a624eac6960/attach?logs=0&stdout=1&stderr=1&stream=1 HTTP/1.1" 101 0
urllib3.connectionpool._new_conn: Starting new HTTPS connection (2): 192.168.99.100
urllib3.connectionpool._make_request: https://192.168.99.100:2376 "GET /v1.22/containers/edc148aa1f00dbd38577646690fcb7baf3b9c0f3f7ca6c4d03841a624eac6960/json HTTP/1.1" 200 None
compose.cli.verbose_proxy.proxy_callable: docker attach -> <generator object frames_iter at 0x00000000037E9E08>
compose.cli.verbose_proxy.proxy_callable: docker start <- ('edc148aa1f00dbd38577646690fcb7baf3b9c0f3f7ca6c4d03841a624eac6960')
compose.parallel.feed_queue: Pending: set()
compose.parallel.feed_queue: Pending: set()
compose.parallel.feed_queue: Pending: set()
compose.parallel.feed_queue: Pending: set()
compose.parallel.feed_queue: Pending: set()
compose.parallel.feed_queue: Pending: set()
urllib3.connectionpool._make_request: https://192.168.99.100:2376 "POST /v1.22/containers/edc148aa1f00dbd38577646690fcb7baf3b9c0f3f7ca6c4d03841a624eac6960/start HTTP/1.1" 204 0
compose.cli.verbose_proxy.proxy_callable: docker start -> None
Starting dockeropenach_web_1 ... done
compose.parallel.feed_queue: Pending: set()
compose.parallel.parallel_execute_iter: Finished processing: <Service: web>
compose.parallel.feed_queue: Pending: set()
compose.cli.verbose_proxy.proxy_callable: docker events <- (filters={'label': ['com.docker.compose.project=dockeropenach', 'com.docker.compose.oneoff=False']}, decode=True)
urllib3.connectionpool._make_request: https://192.168.99.100:2376 "GET /v1.22/events?filters=%7B%22label%22%3A+%5B%22com.docker.compose.project%3Ddockeropenach%22%2C+%22com.docker.compose.oneoff%3DFalse%22%5D%7D HTTP/1.1" 200 None
compose.cli.verbose_proxy.proxy_callable: docker events -> <generator object APIClient._stream_helper at 0x00000000037E9E60>
Attaching to dockeropenach_web_1
web_1  |        Skipped creating a new security.php file, as one already exists.
web_1  |        Skipped initializing SQLite DB, as a file already exists at /home/www/openach/protected/runtime/db/openach.db
web_1  | Action '-D FOREGROUND' failed.
web_1  | The Apache error log may have more information.
compose.cli.verbose_proxy.proxy_callable: docker wait <- ('edc148aa1f00dbd38577646690fcb7baf3b9c0f3f7ca6c4d03841a624eac6960')
compose.cli.verbose_proxy.proxy_callable: docker inspect_container <- ('edc148aa1f00dbd38577646690fcb7baf3b9c0f3f7ca6c4d03841a624eac6960')
urllib3.connectionpool._new_conn: Starting new HTTPS connection (3): 192.168.99.100
urllib3.connectionpool._new_conn: Starting new HTTPS connection (4): 192.168.99.100
urllib3.connectionpool._make_request: https://192.168.99.100:2376 "GET /v1.22/containers/edc148aa1f00dbd38577646690fcb7baf3b9c0f3f7ca6c4d03841a624eac6960/json HTTP/1.1" 200 None
urllib3.connectionpool._make_request: https://192.168.99.100:2376 "POST /v1.22/containers/edc148aa1f00dbd38577646690fcb7baf3b9c0f3f7ca6c4d03841a624eac6960/wait HTTP/1.1" 200 30
compose.cli.verbose_proxy.proxy_callable: docker wait -> {'Error': None, 'StatusCode': 1}
dockeropenach_web_1 exited with code 1
compose.cli.verbose_proxy.proxy_callable: docker inspect_container -> {'AppArmorProfile': '',
 'Args': ['/openach-start'],
 'Config': {'ArgsEscaped': True,
            'AttachStderr': False,
            'AttachStdin': False,
            'AttachStdout': False,
            'Cmd': ['bash', '/openach-start'],
            'Domainname': '',
            'Entrypoint': None,
            'Env': ['PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin',
...
sbrendtro commented 6 years ago

If you could, please add version info from these two commands:

docker -v docker-compose -v

Thanks

popeyebot commented 4 years ago

docker -v Docker version 19.03.8, build afacb8b docker-compose -v docker-compose version 1.25.4, build 8d51620a

I have exactly the same problem

popeyebot commented 4 years ago

@sbrendtro @Juni4567 @popeyebot

ankit-rungta-altiemtrik commented 4 years ago

Hi,

I am facing exact same issue. Need assistance.

ankit-rungta-altiemtrik commented 4 years ago

docker -v Docker version 19.03.8, build afacb8b docker-compose -v docker-compose version 1.25.5, build 8a1c60f6

popeyebot commented 4 years ago

@sbrendtro

ramesh8830 commented 4 years ago

Hi

I am having issues with below.

AH00526: Syntax error on line 22 of /etc/apache2/sites-enabled/default-ssl.conf:
SSLCertificateFile: file '/etc/ssl/openach/openach.crt' does not exist or is empty
Action '-D FOREGROUND' failed.
The Apache error log may have more information.

I tried ssh into docker container with below to check the ssl certficate and it didn't empty.

docker run -it --rm --name openACH openach/openach:latest bash

Please help me

sbrendtro commented 4 years ago

Hi

I am having issues with below.

AH00526: Syntax error on line 22 of /etc/apache2/sites-enabled/default-ssl.conf:
SSLCertificateFile: file '/etc/ssl/openach/openach.crt' does not exist or is empty
Action '-D FOREGROUND' failed.
The Apache error log may have more information.

I tried ssh into docker container with below to check the ssl certficate and it didn't empty.

docker run -it --rm --name openACH openach/openach:latest bash

Please help me

You're using docker run without mounting volumes, so it makes sense that your container has no certificate.

Per the instructions, you need to use:

    docker-compose up -d
    docker exec -it dockeropenach_web_1 /bin/bash

This does two things:

Hope that helps, Steve

sbrendtro commented 4 years ago

Having this issue when I try to run docker-openach on my local computer. docker-compose up gives the following output

web_1  | Action '-D FOREGROUND' failed.
web_1  | The Apache error log may have more information.
dockeropenach_web_1 exited with code 1

This particular issue only seems to happen on Windows Docker hosts, and has to do with Docker on Windows subsystems. We recommend using Linux Docker hosts.

ramesh8830 commented 4 years ago

Hi I am having issues with below.

AH00526: Syntax error on line 22 of /etc/apache2/sites-enabled/default-ssl.conf:
SSLCertificateFile: file '/etc/ssl/openach/openach.crt' does not exist or is empty
Action '-D FOREGROUND' failed.
The Apache error log may have more information.

I tried ssh into docker container with below to check the ssl certficate and it didn't empty. docker run -it --rm --name openACH openach/openach:latest bash Please help me

You're using docker run without mounting volumes, so it makes sense that your container has no certificate.

Per the instructions, you need to use:

    docker-compose up -d
    docker exec -it dockeropenach_web_1 /bin/bash

This does two things:

  • The first time the container starts, it initializes config/db.php and config/security.php, and sets up the default database in runtime/db/openach.db
  • The correct volumes are attached to the image per the definition in docker-compose.yml

Hope that helps, Steve

I followed the instructions and run this command docker-compose up -d but the container status is Exited. When I checked the docker logs, then I got below errors.

AH00526: Syntax error on line 22 of /etc/apache2/sites-enabled/default-ssl.conf:
SSLCertificateFile: file '/etc/ssl/openach/openach.crt' does not exist or is empty
Action '-D FOREGROUND' failed.
The Apache error log may have more information.

Then I run the this command to check whether ssl certificate and key are there or not.

docker run -it --rm --name openACH openach/openach:latest bash

I found that certificates are not empty. I don't understand why container not start and remains in exited status and also don't why apache can't read ssl certificates.

I am using unbuntu server.

Please help me.

sbrendtro commented 4 years ago

@ramesh8830 - I created a new issue for your problem. This one will remain closed.