Make sure that the pid and log directories are created during setup_app