LogLevelstring`name:"log-level" usage:"Log level to run at: [trace, debug, info, warn, fatal]"`
LogDbQueriesbool`name:"log-db-queries" usage:"Log database queries verbosely when log-level is trace or debug"`
ApplicationNamestring`name:"application-name" usage:"Name of the application, used in various places internally"`
LandingPageUserstring`name:"landing-page-user" usage:"the user that should be shown on the instance's landing page"`
ConfigPathstring`name:"config-path" usage:"Path to a file containing gotosocial configuration. Values set in this file will be overwritten by values set as env vars or arguments"`
Hoststring`name:"host" usage:"Hostname to use for the server (eg., example.org, gotosocial.whatever.com). DO NOT change this on a server that's already run!"`
AccountDomainstring`name:"account-domain" usage:"Domain to use in account names (eg., example.org, whatever.com). If not set, will default to the setting for host. DO NOT change this on a server that's already run!"`
Protocolstring`name:"protocol" usage:"Protocol to use for the REST api of the server (only use http if you are debugging or behind a reverse proxy!)"`
BindAddressstring`name:"bind-address" usage:"Bind address to use for the GoToSocial server (eg., 0.0.0.0, 172.138.0.9, [::], localhost). For ipv6, enclose the address in square brackets, eg [2001:db8::fed1]. Default binds to all interfaces."`
Portint`name:"port" usage:"Port to use for GoToSocial. Change this to 443 if you're running the binary directly on the host machine."`
TrustedProxies[]string`name:"trusted-proxies" usage:"Proxies to trust when parsing x-forwarded headers into real IPs."`
DbTLSCACertstring`name:"db-tls-ca-cert" usage:"Path to CA cert for db tls connection"`
WebTemplateBaseDirstring`name:"web-template-base-dir" usage:"Basedir for html templating files for rendering pages and composing emails."`
WebAssetBaseDirstring`name:"web-asset-base-dir" usage:"Directory to serve static assets from, accessible at example.org/assets/"`
InstanceExposePeersbool`name:"instance-expose-peers" usage:"Allow unauthenticated users to query /api/v1/instance/peers?filter=open"`
InstanceExposeSuspendedbool`name:"instance-expose-suspended" usage:"Expose suspended instances via web UI, and allow unauthenticated users to query /api/v1/instance/peers?filter=suspended"`
InstanceExposePublicTimelinebool`name:"instance-expose-public-timeline" usage:"Allow unauthenticated users to query /api/v1/timelines/public"`
InstanceDeliverToSharedInboxesbool`name:"instance-deliver-to-shared-inboxes" usage:"Deliver federated messages to shared inboxes, if they're available."`
AccountsRegistrationOpenbool`name:"accounts-registration-open" usage:"Allow anyone to submit an account signup request. If false, server will be invite-only."`
AccountsApprovalRequiredbool`name:"accounts-approval-required" usage:"Do account signups require approval by an admin or moderator before user can log in? If false, new registrations will be automatically approved."`
AccountsReasonRequiredbool`name:"accounts-reason-required" usage:"Do new account signups require a reason to be submitted on registration?"`
AccountsAllowCustomCSSbool`name:"accounts-allow-custom-css" usage:"Allow accounts to enable custom CSS for their profile pages and statuses."`
MediaImageMaxSizebytesize.Size`name:"media-image-max-size" usage:"Max size of accepted images in bytes"`
MediaVideoMaxSizebytesize.Size`name:"media-video-max-size" usage:"Max size of accepted videos in bytes"`
MediaDescriptionMinCharsint`name:"media-description-min-chars" usage:"Min required chars for an image description"`
MediaDescriptionMaxCharsint`name:"media-description-max-chars" usage:"Max permitted chars for an image description"`
MediaRemoteCacheDaysint`name:"media-remote-cache-days" usage:"Number of days to locally cache media from remote instances. If set to 0, remote media will be kept indefinitely."`
MediaEmojiLocalMaxSizebytesize.Size`name:"media-emoji-local-max-size" usage:"Max size in bytes of emojis uploaded to this instance via the admin API."`
MediaEmojiRemoteMaxSizebytesize.Size`name:"media-emoji-remote-max-size" usage:"Max size in bytes of emojis to download from other instances."`
StorageBackendstring`name:"storage-backend" usage:"Storage backend to use for media attachments"`
StorageLocalBasePathstring`name:"storage-local-base-path" usage:"Full path to an already-created directory where gts should store/retrieve media files. Subfolders will be created within this dir."`
StorageS3UseSSLbool`name:"storage-s3-use-ssl" usage:"Use SSL for S3 connections. Only set this to 'false' when testing locally"`
StorageS3BucketNamestring`name:"storage-s3-bucket" usage:"Place blobs in this bucket"`
StorageS3Proxybool`name:"storage-s3-proxy" usage:"Proxy S3 contents through GoToSocial instead of redirecting to a presigned URL"`
StatusesMaxCharsint`name:"statuses-max-chars" usage:"Max permitted characters for posted statuses"`
StatusesCWMaxCharsint`name:"statuses-cw-max-chars" usage:"Max permitted characters for content/spoiler warnings on statuses"`
StatusesPollMaxOptionsint`name:"statuses-poll-max-options" usage:"Max amount of options permitted on a poll"`
StatusesPollOptionMaxCharsint`name:"statuses-poll-option-max-chars" usage:"Max amount of characters for a poll option"`
StatusesMediaMaxFilesint`name:"statuses-media-max-files" usage:"Maximum number of media files/attachments per status"`
LetsEncryptEnabledbool`name:"letsencrypt-enabled" usage:"Enable letsencrypt TLS certs for this server. If set to true, then cert dir also needs to be set (or take the default)."`
LetsEncryptPortint`name:"letsencrypt-port" usage:"Port to listen on for letsencrypt certificate challenges. Must not be the same as the GtS webserver/API port."`
LetsEncryptCertDirstring`name:"letsencrypt-cert-dir" usage:"Directory to store acquired letsencrypt certificates."`
LetsEncryptEmailAddressstring`name:"letsencrypt-email-address" usage:"Email address to use when requesting letsencrypt certs. Will receive updates on cert expiry etc."`
OIDCEnabledbool`name:"oidc-enabled" usage:"Enabled OIDC authorization for this instance. If set to true, then the other OIDC flags must also be set."`
OIDCIdpNamestring`name:"oidc-idp-name" usage:"Name of the OIDC identity provider. Will be shown to the user when logging in."`
OIDCSkipVerificationbool`name:"oidc-skip-verification" usage:"Skip verification of tokens returned by the OIDC provider. Should only be set to 'true' for testing purposes, never in a production environment!"`
OIDCIssuerstring`name:"oidc-issuer" usage:"Address of the OIDC issuer. Should be the web address, including protocol, at which the issuer can be reached. Eg., 'https://example.org/auth'"`
OIDCClientIDstring`name:"oidc-client-id" usage:"ClientID of GoToSocial, as registered with the OIDC provider."`
OIDCClientSecretstring`name:"oidc-client-secret" usage:"ClientSecret of GoToSocial, as registered with the OIDC provider."`
OIDCLinkExistingbool`name:"oidc-link-existing" usage:"link existing user accounts to OIDC logins based on the stored email value"`
SMTPHoststring`name:"smtp-host" usage:"Host of the smtp server. Eg., 'smtp.eu.mailgun.org'"`
SMTPPortint`name:"smtp-port" usage:"Port of the smtp server. Eg., 587"`
SMTPUsernamestring`name:"smtp-username" usage:"Username to authenticate with the smtp server as. Eg., 'postmaster@mail.example.org'"`
SMTPPasswordstring`name:"smtp-password" usage:"Password to pass to the smtp server."`
SMTPFromstring`name:"smtp-from" usage:"Address to use as the 'from' field of the email. Eg., 'gotosocial@example.org'"`
SyslogEnabledbool`name:"syslog-enabled" usage:"Enable the syslog logging hook. Logs will be mirrored to the configured destination."`
SyslogProtocolstring`name:"syslog-protocol" usage:"Protocol to use when directing logs to syslog. Leave empty to connect to local syslog."`
SyslogAddressstring`name:"syslog-address" usage:"Address:port to send syslog logs to. Leave empty to connect to local syslog."`
AdvancedCookiesSamesitestring`name:"advanced-cookies-samesite" usage:"'strict' or 'lax', see https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Set-Cookie/SameSite"`
AdvancedRateLimitRequestsint`name:"advanced-rate-limit-requests" usage:"Amount of HTTP requests to permit within a 5 minute window. 0 or less turns rate limiting off."`
// Cache configuration vars.
CacheCacheConfiguration`name:"cache"`
// TODO: move these elsewhere, these are more ephemeral vs long-running flags like above
AdminAccountUsernamestring`name:"username" usage:"the username to create/delete/etc"`
AdminAccountEmailstring`name:"email" usage:"the email address of this account"`
AdminAccountPasswordstring`name:"password" usage:"the password to set for this account"`
AdminTransPathstring`name:"path" usage:"the path of the file to import from/export to"`
AdminMediaPruneDryRunbool`name:"dry-run" usage:"perform a dry run and only log number of items eligible for pruning"`