diff --git a/README.md b/README.md index a17cb9c..62ab30a 100644 --- a/README.md +++ b/README.md @@ -274,8 +274,30 @@ For this, you need to make sure your host allows python script execution. This method uses HTTP calls to fetch the RSS feeds, which will be handled through `mod_cgi` for example on Apache severs. -Please pay attention to `main.py` permissions for it to be executable. Also -ensure that the provided `/www/.htaccess` works well with your server. +Please pay attention to `main.py` permissions for it to be executable. See below +some tips for the `.htaccess` file. + +```htaccess +Options -Indexes + +ErrorDocument 404 /cgi/main.py + +# Turn debug on for all requests +SetEnv DEBUG 1 + +# Turn debug on for requests with :debug in the url +SetEnvIf Request_URI :debug DEBUG=1 + + + deny from all + + + + allow from all + AddHandler cgi-script .py + Options +ExecCGI + +``` ### As a CLI application diff --git a/setup.py b/setup.py index 5490aaf..b284995 100644 --- a/setup.py +++ b/setup.py @@ -30,7 +30,6 @@ setup( data_files = [ ('share/' + package_name, ['README.md', 'LICENSE']), ('share/' + package_name + '/www', glob('www/*.*')), - ('share/' + package_name + '/www/cgi', []) ], entry_points = { 'console_scripts': [package_name + '=' + package_name + '.__main__:main'] diff --git a/www/.htaccess b/www/.htaccess deleted file mode 100644 index dec4307..0000000 --- a/www/.htaccess +++ /dev/null @@ -1,15 +0,0 @@ -Options -Indexes - -ErrorDocument 403 "Access forbidden" -ErrorDocument 404 /cgi/main.py -ErrorDocument 500 "A very nasty bug found his way onto this very server" - -# Uncomment below line to turn debug on for all requests -#SetEnv DEBUG 1 - -# Uncomment below line to turn debug on for requests with :debug in the url -#SetEnvIf Request_URI :debug DEBUG=1 - - - deny from all - diff --git a/www/cgi/.htaccess b/www/cgi/.htaccess deleted file mode 100644 index b966e7d..0000000 --- a/www/cgi/.htaccess +++ /dev/null @@ -1,9 +0,0 @@ -order allow,deny - -deny from all - - - allow from all - AddHandler cgi-script .py - Options +ExecCGI -