Skip to content

A platform for community discussion. Free, open, simple.

2.2 KB
Raw Blame
# The IntermediateDB the converter produced; its `upload_sources` are read from here.
intermediate_db: "/shared/import/intermediate.db"

# The files database this run writes its results to (the same file `import.yml`
# calls `files_db`).
files_db: "/shared/import/files.db"

root_paths:
  - "/shared/import/uploads"
  - "/shared/import/more-uploads"

# Files that are downloaded from URLs are cached in this directory.
download_cache_path: "/shared/import/upload-cache"

# The number of threads to use for processing uploads is calculated as:
#   thread_count = [number of cores] * [thread_count_factor]
# The thread count will be doubled if uploads are stored on S3 because there's a higher latency.
thread_count_factor: 1.5

# Delete uploads from files.db that are not found in the IntermediateDB.
delete_surplus_uploads: false

# Delete uploads from files.db that do not have a Discourse upload record.
delete_missing_uploads: false

# Check for files missing from the upload store and recreate them during this run.
fix_missing: false

# Create optimized images for post uploads and avatars.
create_optimized_images: false

site_settings:
  authorized_extensions: "*"
  max_attachment_size_kb: 102_400
  max_image_size_kb: 102_400

  # Largest image the importer will accept without downsizing (in megapixels).
  max_image_megapixels: 150
  # Set to true when importing into a site that has secure uploads enabled.
  secure_uploads: false
  # Set to true when the S3 bucket uses object ACLs and tags for access control.
  s3_enable_access_control_tags: true

  enable_s3_uploads: true
  s3_upload_bucket: "your-bucket-name"
  s3_region: "your-region"
  s3_access_key_id: "your-access-key-id"
  s3_secret_access_key: "your-secret-access-key"
  s3_cdn_url: "https://your-cdn-url.com"

  # Set this to true if the site is a multisite and configure the `multisite_db_name` accordingly
  multisite: false
  multisite_db_name: "default"

# Sometimes a file can be found at one of many locations. Here's a list of transformations that can
# be applied to the path to try and find the file. The first transformation that results in a file
# being found will be used.
path_replacements:
#  - ["/foo/", "/bar"]
#  - ["/foo/", "/bar/baz/"]