Skip to content

Instantly share code, notes, and snippets.

@evandrododo
Created April 9, 2018 18:14
Show Gist options
  • Save evandrododo/eff8e9e7b63a77a974d580dae1f4d80d to your computer and use it in GitHub Desktop.
Save evandrododo/eff8e9e7b63a77a974d580dae1f4d80d to your computer and use it in GitHub Desktop.
Qgis server ubuntu based
sudo aptitude install qgis-mapserver libapache2-mod-fcgid
sudo chmod 755 /usr/lib/cgi-bin
sudo chown root.root /usr/lib/cgi-bin
# [sudo] edit apache config (/etc/apache2/000-default.conf ou seu hostfile)
<VirtualHost>
...
ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
<Directory "/usr/lib/cgi-bin">
AllowOverride None
Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
mkdir /var/www/cgi-bin
mkdir /var/www/cgi-bin/arteris
cp /usr/lib/cgi-bin/* /var/www/cgi-bin/
cp /var/www/cgi-bin/qgis_mapserv.cgi /var/www/cgi-bin/arteris/.
sudo service apache2 restart
#Testando cgi:
http://localhost/cgi-bin/qgis_mapserv.fcgi?SERVICE=WMS&VERSION=1.3.0&REQUEST=GetCapabilities
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment