• Halloween is coming! To celebrate the occasion, we dusted off a couple of old skins, and even created a brand new one (Pixel).
    To get into the festive spirit, install the Skins extension.
  • The new Python extension is now available. It allows customers to deploy and manage WSGI-based Python applications on their websites directly from Plesk.
  • The Plesk Mobile apps for iOS and Android and the Plesk Mobile Center extension have been deprecated, and are no longer available for new installations. In Plesk Obsidian 18.0.84, the Plesk Mobile Center extension will be removed from servers during the upgrade, and the Plesk Mobile apps will lose their server management features.
  • The Social Login extension has been deprecated and will be removed in Plesk Obsidian 18.0.84. After that, it will no longer be possible to log in to Plesk with a Google, Facebook, GitHub account, or with a passkey. Plesk usernames and passwords, as well as logging in with a WebPros Account, are not affected.

Issue Apache user changes with directive. - Why?

Sebastian

New Pleskian
When I run a simple php web page that echos out the apache user with
PHP:
echo exec('whoami');
it gives me the expected system user, e.g.
Code:
bob

When I run the same but with an alias directive in apache settings:
Code:
AliasMatch /appname(/.*)? /var/www/vhosts/domain.dev/httpdocs/apps/appname/$1
Alias /appname /var/www/vhosts/domain.dev/httpdocs/apps/appname
<Directory "/var/www/vhosts/domain.dev/httpdocs/apps/appname">
    <IfModule sapi_apache2.c>
        php_admin_flag engine on
    </IfModule>
    <IfModule mod_php7.c>
        php_admin_flag engine on
    </IfModule>
</Directory>
the user changes to
Code:
www-data
Question: Why? And how can I avoid this?
 
Last edited:
I think that explanation in this thread could be interesting for you Resolved - apache run whit customer user not whit www-data
I read this before, but it does not help here.
What UFHH01 points out there is a warning not to mess around with config files to force apache to use another user. And I can second that.
E.g. I have played around with /etc/apache2/envvars and changed the APACHE_RUN_USER and APACHE_RUN_GROUP, but that (at least) broke the Plesk log file viewer, so I had to reverse it.
 
Back
Top