pg_tileserv¶
Table of Contents
pg_tileserv¶
pg_tileserv is installed as a systemd service during installation.
The service can be started and stopped via command line or Webmin.
The service file contents are show below.
1 2 3 4 5 6 7 8 9 10 11 12 13 | [Unit] Description=PG TileServ After=multi-user.target [Service] User=pgis WorkingDirectory=/opt/pg_tileserv Type=simple Restart=always ExecStart=/opt/pg_tileserv/pg_tileserv --config /opt/pg_tileserv/config/pg_tileserv.toml [Install] WantedBy=multi-user.target |
The file is installed at:
/etc/systemd/system/pg_tileserv.service
Access¶
pg_tileserv runs of port 7800 and can be accessed at http://doamin.com:7800
You can change the port via the pg_tileserv.toml file located under /opt/pg_tileserv/config
Database¶
On installation, a database is created called postgisftw.
This database contains the demo data.
A user pgis is also created and given permission to the database.
The password for pgis is displayed at the end of installation as well as saved to /root/auth.txt
Structure¶
pg_tileserv is installed by default at:
/opt/pgtileserv
The directory structure is show below:
/opt/pg_tileserv
├── LICENSE.md
├── README.md
├── assets
├── index.html
├── preview-function.html
└── preview-table.html
├── config
├── pg_tileserv.toml
└── pg_tileserv.toml.example.save
└── pg_tileserv
Configuration File¶
On installation, the pg_tileserv.toml configuration file is updated to include the postgisftw connection inforation:
DbConnection = "postgresql://pgis:G84iwLdL9jeyA7IiwkTmWhyHwKR41Qxz@localhost/postgisftw"