How to create a custom nginx template

Post Reply
myvesta_pk
Posts: 1
Joined: Wed May 08, 2024 7:19 pm

I am using Apache+Nginx on my VPS. To enable IPv6 for my domains, I manually modified domain specific configuration files of Nginx by adding "Listen [IPv6]:443 SSL;". However, I am facing a weird issue.
Those domain specific configuration files of Nginx get overwritten whenever Nginx or SSL certificate is updated.

So, I thought if I change the proxy template, the changes will remain permanent. I am using 'hosting' proxy template for Nginx. So, I modified "hosting.tpl" and "hosting.stpl" files in folder /usr/local/vesta/data/templates/web/nginx. The changes worked, but changes in those template files are also gone after some update.

Is there any way to create custom template that will not be overwritten due to system update and I can use the custom template for my domain?

Tags:
User avatar
myVesta
Site Admin
Posts: 934
Joined: Fri Jun 19, 2020 9:59 am
Has thanked: 8 times
Been thanked: 6 times

Code: Select all

cd /usr/local/vesta/data/templates/web/nginx
cp hosting.tpl mycustom.tpl
cp hosting.stpl mycustom.stpl
Post Reply