fixed rake file to use NGINX_EXEC environment variable correctly
added database creation and cache entries removal from database and filesystem