Skip to content

A self-hosted media server and file management system

add backup command

aminnausinffdeef55d6e8
diff --git a/.gitignore b/.gitignore
index 3228197a..f2fa34cb 100755
--- a/.gitignore
+++ b/.gitignore
@@ -23,4 +23,5 @@ yarn-error.log
storage/app/public/*
storage/debugbar/*
storage/framework/*
-storage/logs/*
\ No newline at end of file
+storage/logs/*
+databaseBackups/*
\ No newline at end of file
diff --git a/commands.txt b/commands.txt
index ab4f55ee..58698709 100644
--- a/commands.txt
+++ b/commands.txt
@@ -2,4 +2,7 @@ Auto delete local copies of merged/deleted remote branches
git branch --merged | %{$_.trim()} | ?{$_ -notmatch 'dev' -and $_ -notmatch 'main'} | %{git branch -d $_}
Fix sql ID
-select setval('ecommerce."purchases_id_seq"', coalesce((select max(id)+1 from ecommerce.purchases), 1), false)
\ No newline at end of file
+select setval('ecommerce."purchases_id_seq"', coalesce((select max(id)+1 from ecommerce.purchases), 1), false)
+
+Backup pgsql
+pg_dump -h 127.0.0.1 -p 5432 -U postgres -Fc -d mediaServer -v -f databaseBackups/pgsql_bk_mediaServer20240818
\ No newline at end of file