Some configuration files are dependent on where the location of you location is. Therefore I mostly have variables in the configuration files, that I replace upon installation using sed.
As an example I have a systemd service file (example.service):
[Unit]
Description=My app
[Service]
WorkingDirectory={{WORKING_DIR}}
ExecStart=/usr/bin/python3 {{WORKING_DIR}}/app.sh
Restart=always
[Install]
WantedBy=multi-user.target
Then run the following on this file:
sed "s,{{WORKING_DIR}},/location/to/application/dir,g" example.service > /etc/systemd/system/example.service
Then the service file is installed and the variables are replaced with the path to your liking.