improve the registration script
make the puppetmaster autorestart when something changed