Snapshot: 504 Gateway Timeout

Every time I try to run Snapshot or Managed Backup on the site I get 504 Gateway Timeout.