config.sample.php 1.6 KB

123456789101112131415161718192021222324252627282930
  1. <?php
  2. // Copy this file to config.php and change the password before deploying.
  3. define("BACKUP_SERVER_PASSWORD", "change-me");
  4. // Optional stronger alternative:
  5. // define("BACKUP_SERVER_PASSWORD_HASH", "$2y$10$replace-this-with-a-precomputed-password-hash");
  6. define("BACKUP_SERVER_RETENTION", 30);
  7. define("BACKUP_SERVER_BACKUP_DIR", __DIR__ . "/backups/");
  8. define("BACKUP_SERVER_INDEX_FILE", BACKUP_SERVER_BACKUP_DIR . "index.json");
  9. define("BACKUP_SERVER_SETTINGS_FILE", BACKUP_SERVER_BACKUP_DIR . "settings.json");
  10. // S3-compatible object storage (optional). Leave disabled for local-only behavior.
  11. // When enabled, every upload is archived to S3 and only the newest local copies
  12. // are kept on disk. All five connection values must be filled in.
  13. define("BACKUP_SERVER_S3_ENABLED", false);
  14. define("BACKUP_SERVER_S3_ENDPOINT", "https://fsn1.your-objectstorage.com"); // e.g. Hetzner
  15. define("BACKUP_SERVER_S3_REGION", "fsn1");
  16. define("BACKUP_SERVER_S3_BUCKET", "");
  17. define("BACKUP_SERVER_S3_PREFIX", "psa-backups"); // key prefix inside the bucket, may be ""
  18. define("BACKUP_SERVER_S3_ACCESS_KEY", "");
  19. define("BACKUP_SERVER_S3_SECRET_KEY", "");
  20. // Addressing style. false = virtual-hosted (https://<bucket>.<endpoint>/<key>),
  21. // which Hetzner and most providers expect. Set true only if your provider
  22. // requires path-style (https://<endpoint>/<bucket>/<key>).
  23. define("BACKUP_SERVER_S3_PATH_STYLE", false);
  24. define("BACKUP_SERVER_S3_TIMEOUT", 120); // seconds per HTTP request
  25. define("BACKUP_SERVER_S3_RETENTION", 365); // default S3 backups kept per instance
  26. define("BACKUP_SERVER_LOG_FILE", BACKUP_SERVER_BACKUP_DIR . "s3.log");