depois de pesquisar mais, veja como resolvi este problema:
/var/log/nginx-hosts/*.access{
weekly
missingok
rotate 20
compress
dateext
notifempty
create 0640 www-data adm
sharedscripts
sharedscripts
prerotate
if [ -d /etc/logrotate.d/httpd-prerotate ]; then \
run-parts /etc/logrotate.d/httpd-prerotate; \
fi; \
endscript
postrotate
[ ! -f /var/run/nginx.pid ] || kill -USR1 'cat /var/run/nginx.pid'
endscript
}
/var/log/nginx-hosts/*.error{
weekly
missingok
rotate 20
compress
dateext
notifempty
create 0640 www-data adm
sharedscripts
sharedscripts
prerotate
if [ -d /etc/logrotate.d/httpd-prerotate ]; then \
run-parts /etc/logrotate.d/httpd-prerotate; \
fi; \
endscript
postrotate
[ ! -f /var/run/nginx.pid ] || kill -USR1 'cat /var/run/nginx.pid'
endscript
}