• Resolved cybermercenario

    (@cybermercenario)


    I am running a wordpress installation on a self hosted ubuntu server. Principally all is working OK. I can update plugins and modify pages, but when I try to change some theme variables, WordPress shows me an error that the css folder and file is not writeable although permissions are set.

    This is what I have done:

    I have created a group in Ubuntu with:
    sudo addgroup group1

    I have created 2 users in this group:
    sudo adduser myself group1
    sudo adduser www-data group1

    I have set the owner for the web folder
    chown -R myself:group1 /var/www/webfolder/

    Permissions are set
    chmod -R ugo+rwx /var/www/webfolder/
    chmod -R g+s /var/www/webfolder/

    Checking permissions with ls -l show as result:
    drwxrwsrwx+ 5 myself group1 4096 Sep 17 15:16 webfolder

    Is there something wrong in my configuration?

    Any help would be appreciated.

Viewing 4 replies - 1 through 4 (of 4 total)
  • Moderator Steven Stern (sterndata)

    (@sterndata)

    Volunteer Forum Moderator

    The directories should be OWNED by the same user id that PHP is using. You can put yourself into the group so you can write into the directories, but the owner must be the same as the PHP process.

    Thread Starter cybermercenario

    (@cybermercenario)

    Thank you for a quick reply.

    One never stop learning. ??
    I thought it is enough to add www-data to that group.

    As www-data is the user that web server on Ubuntu (Apache) use by default, what I have to do is change the owner to www-data with
    chown -R www-data:group1 /var/www/webfolder/

    right?

    Moderator Steven Stern (sterndata)

    (@sterndata)

    Volunteer Forum Moderator

    sudo chown -R www-data:group1 /var/www/webfolder/

    If you’re running more that one site on your server, you should not use www-data. Each site should run under a different user ID so hacking one does not allow access to the others. (Also, each site should use a different database user id.)

    Thread Starter cybermercenario

    (@cybermercenario)

    Thank you for the warning but this server is only for development purposes. In my case the easiest way is to operate with www-data.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘CSS theme folder and file not writeable from wordpress’ is closed to new replies.