Change mastodon:setup to prevent overwriting already-configured servers (#33684)

This commit is contained in:
Claire 2025-01-22 16:34:22 +01:00 committed by GitHub
parent 8dcfd3f246
commit a6fc776c6f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -8,6 +8,12 @@ namespace :mastodon do
prompt = TTY::Prompt.new
env = {}
if ENV['LOCAL_DOMAIN']
prompt.warn "It looks like you already configured Mastodon for domain '#{ENV['LOCAL_DOMAIN']}'."
prompt.warn 'Never re-run this task on an already-configured running server.'
next prompt.warn 'Nothing saved. Bye!' if prompt.no?('Continue anyway?')
end
clear_environment!
begin