shinsenter/php

container stop with s6-rc failed error

Closed this issue ยท 11 comments

Hi, I'm using the shinsenter/phpfpm-apache:php8.1 image and this night after an update with watchtower I found my containers down with this error

Server version: Apache/2.4.61 (Debian)
Server built:   2024-07-07T12:08:26
AH00534: apache2: Configuration error: No MPM loaded.
cont-init: warning: some scripts exited nonzero
s6-rc: warning: unable to start service legacy-cont-init: command exited 1
/run/s6/basedir/scripts/rc.init: warning: s6-rc failed to properly bring all the services up! Check your logs (in /run/uncaught-logs/current if you have in-container logging) for more information.
/run/s6/basedir/scripts/rc.init: fatal: stopping the container.

The image I'm using has digest a188c7c192f7f462336827fcc49e3fe679bb174ec082e6149b1810b7daa6bae3

Is there anything I can do to fix or help fixing this error?

Thanks

Tas

Hi @Tassleh0ff

I will review the recent builds. Please be patient or use one of the previous builds here.
https://hub.docker.com/r/shinsenter/php-archives/tags?page=&page_size=&ordering=&name=8.1-fpm-apache

Thank you very much I didn't know the existence of the archive, it helped so much!
Take your time, as I always repeat at work to my colleagues, it's not an hospital ER :)
Please, let me know if I can do anything to help you.

Tas

Hi @Tassleh0ff
I have updated the docker images, please pull and test to see if it works.

I made a test right now and for me it works perfectly, thank you!

Ah, I've started getting this today with the shinsenter/statamic:php8.3-alpine image, but doesn't happen on localhost for some reason. Any ideas?

2024-07-22T23:47:49.111818940Z Plugins have been disabled automatically as you are running as root, this may be the cause of the following exception. See also https://getcomposer.org/root
2024-07-22T23:47:49.112127604Z 
2024-07-22T23:47:49.116912973Z In ConfigCommand.php line 218:
2024-07-22T23:47:49.116963376Z                                                                    
2024-07-22T23:47:49.116967594Z   File "./composer.json" cannot be found in the current directory  
2024-07-22T23:47:49.116971031Z                                                                    
2024-07-22T23:47:49.116974347Z 
2024-07-22T23:47:49.116977463Z config [-g|--global] [-e|--editor] [-a|--auth] [--unset] [-l|--list] [-f|--file FILE] [--absolute] [-j|--json] [-m|--merge] [--append] [--source] [--] [<setting-key> [<setting-value>...]]
2024-07-22T23:47:49.116982011Z 
2024-07-22T23:47:49.390463891Z 
2024-07-22T23:47:49.390532027Z      _     _                      _              __    _
2024-07-22T23:47:49.390536836Z     | |   (_)                    | |            / /   | |
2024-07-22T23:47:49.390540373Z  ___| |__  _ _ __  ___  ___ _ __ | |_ ___ _ __ / / __ | |__  _ __
2024-07-22T23:47:49.390544010Z / __| '_ \| | '_ \/ __|/ _ \ '_ \| __/ _ \ '__/ / '_ \| '_ \| '_ \
2024-07-22T23:47:49.390547927Z \__ \ | | | | | | \__ \  __/ | | | ||  __/ | / /| |_) | | | | |_) |
2024-07-22T23:47:49.390566983Z |___/_| |_|_|_| |_|___/\___|_| |_|\__\___|_|/_/ | .__/|_| |_| .__/
2024-07-22T23:47:49.390571391Z                                                 | |         | |
2024-07-22T23:47:49.390592501Z                                                 |_|         |_|
2024-07-22T23:47:49.390596208Z Github:    https://code.shin.company/php
2024-07-22T23:47:49.390599313Z DockerHub: https://docker.shin.company/php
2024-07-22T23:47:49.390602469Z 
2024-07-22T23:47:49.390605806Z (To edit this welcome message, add your text to /etc/welcome.txt)
2024-07-22T23:47:49.390609152Z 
2024-07-22T23:47:49.390612287Z ----------------------------------------
2024-07-22T23:47:49.390615553Z Container     : shinsenter/statamic
2024-07-22T23:47:49.390618869Z Distro        : Alpine Linux v3.20
2024-07-22T23:47:49.390622205Z Timezone      : UTC (GMT+0000)
2024-07-22T23:47:49.390625552Z UID / GID     : www-data:www-data (82:82)
2024-07-22T23:47:49.390628848Z App Root      : /var/www/html
2024-07-22T23:47:49.390649046Z Document Root : /var/www/html/public
2024-07-22T23:47:49.390652612Z ----------------------------------------
2024-07-22T23:47:49.390655889Z 
2024-07-22T23:47:49.390659095Z PHP Docker Images (https://hub.docker.com/r/shinsenter/php)
2024-07-22T23:47:49.390662251Z Copyright (C) 2024  SHIN Company <shin@shin.company>
2024-07-22T23:47:49.390666068Z 
2024-07-22T23:47:49.390669244Z This is free software under the GNU GPL.
2024-07-22T23:47:49.390672620Z You can redistribute and/or modify it under the terms of the GNU GPL.
2024-07-22T23:47:49.390676086Z This program is distributed in the hope it will be useful,
2024-07-22T23:47:49.390679363Z but WITHOUT ANY WARRANTY. See the GNU GPL for more details.
2024-07-22T23:47:49.390682719Z 
2024-07-22T23:47:49.390685865Z To get support, please contact: SHIN Company <shin@shin.company>
2024-07-22T23:47:49.390689371Z 
2024-07-22T23:47:49.390692627Z PHP 8.3.9 (fpm-fcgi) (built: Jul  6 2024 01:11:04)
2024-07-22T23:47:49.390695973Z Copyright (c) The PHP Group
2024-07-22T23:47:49.390699179Z Zend Engine v4.3.9, Copyright (c) Zend Technologies
2024-07-22T23:47:49.390702305Z     with Zend OPcache v8.3.9, Copyright (c), by Zend Technologies
2024-07-22T23:47:49.390705641Z Composer version 2.7.7 2024-06-10 22:11:12
2024-07-22T23:47:49.390724977Z 
2024-07-22T23:47:49.682076869Z nginx version: nginx/1.26.1
2024-07-22T23:47:49.692492651Z nginx: the configuration file /etc/nginx/nginx.conf syntax is ok
2024-07-22T23:47:49.692711088Z nginx: configuration file /etc/nginx/nginx.conf test is successful
2024-07-22T23:47:49.698926421Z cont-init: warning: some scripts exited nonzero
2024-07-22T23:47:49.699237350Z s6-rc: warning: unable to start service legacy-cont-init: command exited 1
2024-07-22T23:47:49.705384837Z /run/s6/basedir/scripts/rc.init: warning: s6-rc failed to properly bring all the services up! Check your logs (in /run/uncaught-logs/current if you have in-container logging) for more information.
2024-07-22T23:47:49.705412619Z /run/s6/basedir/scripts/rc.init: fatal: stopping the container.

Hi, I will check the image.

              "org.opencontainers.image.authors": "SHIN Company <shin@shin.company>",
                "org.opencontainers.image.created": "2024-07-22T12:48:45+0000",
                "org.opencontainers.image.description": "๐Ÿ”‹ (PHP / Statamic) Production-ready container with automatic Statamic installer.",
                "org.opencontainers.image.documentation": "https://hub.docker.com/r/shinsenter/statamic",
                "org.opencontainers.image.licenses": "GPL-3.0",
                "org.opencontainers.image.revision": "f259c0859a75f050c565fef5c92cb0f834766799",
                "org.opencontainers.image.source": "https://code.shin.company/php/blob/main/src/",
                "org.opencontainers.image.title": "shinsenter/statamic",
                "org.opencontainers.image.url": "https://hub.docker.com/r/shinsenter/statamic/tags",
                "org.opencontainers.image.vendor": "Docker Hub",

From docker inspect on the container (I think is best way to identify revision?). I looked up on https://hub.docker.com/r/shinsenter/statamic/tags?page=&page_size=&ordering=&name=alpine but it does not match digest so I'm guessing revision != digest

It is the git commit ID. And f259c0859a75f050c565fef5c92cb0f834766799 is the latest version.

@replete

After thoroughly analyzing the startup process and reviewing the s6-overlay logs, I believe I have identified the cause of the issue. I will try updating the containers (this will take a few hours), so please be patient.

@replete The Docker images have been updated, can you help me check them again?

It's working! That was a head-scratcher. Thank you so much for the quick fix.