discourse backup creates a backup with uploads, regardless of the site setting that controls that. Is there a way to do a database only backup from the command line? It would be handy to be able do this for a number of reasons.
「いいね!」 3
「いいね!」 6
Thanks! I read enough here that I think I know and remember everything that’s been posted and sometimes forget to search. 
I marked your post as the solution, but here’s the one-liner:
/var/discourse/launcher run app "echo 'BackupRestore::Backuper.new(Discourse.system_user.id, with_uploads: false).run' | rails c"
「いいね!」 4
将来の参照のために自分用のメモ:
# dockerコンテナに入る、または ./launcher enter <dockername>
docker exec -it <dockername> bash
# マルチサイトの場合、railsコンソールを実行する際にデータベースを指定することを忘れないでください
RAILS_DB=db_name rails c
# コマンドを確認:
BackupRestore::Backuper.new(Discourse.system_user.id, with_uploads: false)
# その後、バックアップコマンドを実行します
BackupRestore::Backuper.new(Discourse.system_user.id, with_uploads: false).run
このトピックは、最後の返信から30日後に自動的にクローズされました。新しい返信は許可されていません。