M
M
marataziat2016-06-20 16:00:58
Apache HTTP Server
marataziat, 2016-06-20 16:00:58

cgi scripts not working on apache raspberrypi?

I want to run python scripts on raspberry pi using apache webserver i set it up

<VirtualHost *:80>
<Directory "/var/www/html/cgi-bin">
AddHandler cgi-script .py
</Directory>

        ServerAdmin [email protected]
        DocumentRoot /var/www/html

        # Available loglevels: trace8, ..., trace1, debug, info, notice, warn,
        # error, crit, alert, emerg.
        # It is also possible to configure the loglevel for particular
        # modules, e.g.
        #LogLevel info ssl:warn

        ErrorLog ${APACHE_LOG_DIR}/error.log
        CustomLog ${APACHE_LOG_DIR}/access.log combined

        # For most configuration files from conf-available/, which are
        # enabled or disabled at a global level, it is possible to
        # include a line for only one particular virtual host. For example the
        # modules, e.g.
        #LogLevel info ssl:warn

        ErrorLog ${APACHE_LOG_DIR}/error.log
        CustomLog ${APACHE_LOG_DIR}/access.log combined

        # For most configuration files from conf-available/, which are
        # enabled or disabled at a global level, it is possible to
        # include a line for only one particular virtual host. For example the
        # following line enables the CGI configuration for this host only
        # after it has been globally disabled with "a2disconf".
        #Include conf-available/serve-cgi-bin.conf
</VirtualHost>

# vim: syntax=apache ts=4 sw=4 sts=4 sr noet

to the fact that in the /var/www/html/cgi-bin directory there are python scripts and when I run them, the contents of the script are written to me:
dc67c3c260424f01be2ba2fe82572c34.png
Help, what is the problem?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Dim Boy, 2016-06-20
@twix007

read logs

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question