Skip to content

Missing socks dir in image #1444

Closed
@owngr

Description

@owngr

Hello there,

Image impacted: 8.1-apache-bookworm

We run your docker images as non root and recently noticed that it isn't possible to run apache2ctl anymore. I get the following error when trying to run any apache2ctl command:

apache2ctl -k graceful
chown: changing ownership of '/var/run/apache2/socks.6lWmhC0DVq': Operation not permitted

apache2ctl has this line of code in it

[ ! -d ${APACHE_RUN_DIR:-/var/run/apache2}/socks ] && mkdir_chown ${APACHE_RUN_USER:-www-data} ${APACHE_RUN_DIR:-/var/run/apache2}/socks

The problem seems to be that the /var/run/socks folder doesn't exist in your image and then apache2ctl needs root access to create it.

The problem seems to be only in the bookworm version, the bullseye version works as expected.

I think creating the folder here would solve the problem

# setup directories and permissions

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions