Changes
Page history
Update Create a DB dump
authored
Aug 07, 2019
by
Daniel Palomar
Hide whitespace changes
Inline
Side-by-side
Create-a-DB-dump.md
View page @
936c586c
...
@@ -26,6 +26,9 @@ $ docker exec -ti postgres bash
...
@@ -26,6 +26,9 @@ $ docker exec -ti postgres bash
# pg_dump -U opencell -W -f opencell.19.08.07.dump opencell
# pg_dump -U opencell -W -f opencell.19.08.07.dump opencell
```
```
> If you don't know the db user and password, you can check it in the `docker-compose.yml` file with the keys: `DB_USER` and `DB_PASSWORD`.
5.
Exit and copy the dump out of the container:
5.
Exit and copy the dump out of the container:
```
```
...
@@ -43,7 +46,7 @@ daniel@opencell-test:~$ sudo chown daniel:daniel /home/opencell/opencell.19.08.0
...
@@ -43,7 +46,7 @@ daniel@opencell-test:~$ sudo chown daniel:daniel /home/opencell/opencell.19.08.0
daniel@opencell-test:~$ sudo mv /home/opencell/opencell.19.08.07.dump .
daniel@opencell-test:~$ sudo mv /home/opencell/opencell.19.08.07.dump .
```
```
6
.
Copy the dump form the server to your machine:
7
.
Copy the dump form the server to your machine:
```
```
$ logout
$ logout
...
@@ -52,3 +55,5 @@ Connection to opencell-test.coopdevs.org closed.
...
@@ -52,3 +55,5 @@ Connection to opencell-test.coopdevs.org closed.
$ scp opencell-test.coopdevs.org:opencell.19.08.07.dump .
$ scp opencell-test.coopdevs.org:opencell.19.08.07.dump .
opencell.19.08.07.dump 100% 1027KB 2.5MB/s 00:00
opencell.19.08.07.dump 100% 1027KB 2.5MB/s 00:00
```
```
And you have the dump in your local machine!
\ No newline at end of file