files/gitlab-cookbooks/nginx/templates/default/sv-nginx-run.erb (5 lines of code) (raw):
#!/bin/sh
exec 2>&1
<%= render("mount_point_check.erb", cookbook: 'gitlab') %>
cd <%= node['gitlab']['nginx']['dir'] %>
exec chpst -P /opt/gitlab/embedded/sbin/nginx -p <%= node['gitlab']['nginx']['dir'] %>