I have NextCloud installed on CentOS but I have a problem with the firewall configuration. please guide me.
Dear Alex, well done to install Nextcloud successfully. To be able to set up the firewall, you should make a few configurations for SELINUX to reach your target. Use the following commands and then if you faced any other questions, please feel free to ask me or visit our related article on install nextcloud centos 8.
sudo semanage fcontext -a -t httpd_sys_rw_content_t ‘/var/www/html/nextcloud/data’ sudo semanage fcontext -a -t httpd_sys_rw_content_t ‘/var/www/html/nextcloud/config(/.*)?’ sudo semanage fcontext -a -t httpd_sys_rw_content_t ‘/var/www/html/nextcloud/apps(/.*)?’ sudo semanage fcontext -a -t httpd_sys_rw_content_t ‘/var/www/html/nextcloud/3rdparty(/.*)?’ sudo semanage fcontext -a -t httpd_sys_rw_content_t ‘/var/www/html/nextcloud/.htaccess’ sudo semanage fcontext -a -t httpd_sys_rw_content_t ‘/var/www/html/nextcloud/.user.ini’ sudo restorecon -Rv ‘/var/www/html/nextcloud/
After that, open the webserver port 80 to allow external users to access NextCloud from your server. Type the following commands to do this: sudo firewall-cmd –add-port=80/tcp –zone=public –permanentsudo firewall-cmd –reload
+8595670151
7 days a week, 24 hours a day