sudo -u renderaccount PGPASSWORD='renerpassword' osm2pgsql -d osmdb --create --slim -G --hstore --tag-transform-script /usr/local/share/openstreetmap-carto/openstreetmap-carto.lua -C 3000 --number-processes 4 -S /usr/local/share/openstreetmap-carto/openstreetmap-carto.style south-africa-241021.osm.pbf
/usr/local/bin/renderd -f -c /usr/local/etc/renderd.conf
sudo -u gsimrenderaccount render_list -a  -n 4 -z 0 -Z 2 -m default
sudo nano /etc/systemd/system/tile-pre-render.service

[Unit]
Description=OSM Tile Pre-rendering Service
After=network.target

[Service]
Type=simple
User=renderaccount
ExecStart=/usr/local/bin/render_list -a -n 4 -z 0 -Z 18 -m default
Restart=on-failure

[Install]sudo systemctl daemon-reload
sudo systemctl start tile-pre-render.service
sudo systemctl enable tile-pre-render.service

WantedBy=multi-user.target



sudo systemctl daemon-reload
sudo systemctl start tile-pre-render.service
sudo systemctl enable tile-pre-render.service



sudo systemctl status tile-pre-render.service
journalctl -u tile-pre-render.service -f