Database location? how to make a backup? #270

Closed
opened 2026-02-04 18:16:27 +03:00 by OVERLORD · 8 comments
Owner

Originally created by @ghost on GitHub (Jan 4, 2023).

everything that is done in the kanban, be it adding tasks, images, attaching files, etc. Where is it saved? what is the path of the folder that contains the database? Please help

Originally created by @ghost on GitHub (Jan 4, 2023). everything that is done in the kanban, be it adding tasks, images, attaching files, etc. Where is it saved? what is the path of the folder that contains the database? Please help
Author
Owner

@meltyshev commented on GitHub (Jan 4, 2023):

Hi! There are 2 folders (server/public and server/private) with uploaded files and the database itself. So you need to copy these two folders and backup the database with pg_dump planka > planka.sql. If you run Planka in Docker then you have to do it inside the container. I'm gonna add backup and restore services to the docker compose so it can be done with just one command.

@meltyshev commented on GitHub (Jan 4, 2023): Hi! There are 2 folders (`server/public` and `server/private`) with uploaded files and the database itself. So you need to copy these two folders and backup the database with `pg_dump planka > planka.sql`. If you run Planka in Docker then you have to do it inside the container. I'm gonna add backup and restore services to the docker compose so it can be done with just one command.
Author
Owner

@ghost commented on GitHub (Jan 5, 2023):

Hi! There are 2 folders (server/public and server/private) with uploaded files and the database itself. So you need to copy these two folders and backup the database with pg_dump planka > planka.sql. If you run Planka in Docker then you have to do it inside the container. I'm gonna add backup and restore services to the docker compose so it can be done with just one command.

In my folder (server/private) there is a folder called attachments and inside that folder a file called .gitkeep. On the other hand, in my folder (server/public) there are two folders one called project-background-images which contains the .gitkeep file and the other folder is called user-avatars with the same .gitkeep file.
I have the following questions:

  1. If I have already created the board with different things, and I want to delete everything I did, how do I delete it? I tried deleting the container, the image and when I re-download and install it, it returns to the way I left it and not by default.
  2. If I want to make a backup. What are the files that I should save? And how is the step by step to perform the backup of postgres?
  3. And finally, once I have made the backup, how do I upload the backup? Please if you can help me in the simplest way. I am starting and I have many doubts, but for the moment I am progressing well. Thank you
@ghost commented on GitHub (Jan 5, 2023): > Hi! There are 2 folders (`server/public` and `server/private`) with uploaded files and the database itself. So you need to copy these two folders and backup the database with `pg_dump planka > planka.sql`. If you run Planka in Docker then you have to do it inside the container. I'm gonna add backup and restore services to the docker compose so it can be done with just one command. In my folder (server/private) there is a folder called attachments and inside that folder a file called .gitkeep. On the other hand, in my folder (server/public) there are two folders one called project-background-images which contains the .gitkeep file and the other folder is called user-avatars with the same .gitkeep file. I have the following questions: 1) If I have already created the board with different things, and I want to delete everything I did, how do I delete it? I tried deleting the container, the image and when I re-download and install it, it returns to the way I left it and not by default. 2) If I want to make a backup. What are the files that I should save? And how is the step by step to perform the backup of postgres? 3) And finally, once I have made the backup, how do I upload the backup? Please if you can help me in the simplest way. I am starting and I have many doubts, but for the moment I am progressing well. Thank you
Author
Owner

@meltyshev commented on GitHub (Jan 9, 2023):

If I have already created the board with different things, and I want to delete everything I did, how do I delete it? I tried deleting the container, the image and when I re-download and install it, it returns to the way I left it and not by default.

There are 4 volumes: user-avatars, project-background-images, attachments, db-data. To delete all data you have to delete all docker volumes.

If I want to make a backup. What are the files that I should save? And how is the step by step to perform the backup of postgres?

Mount volumes and backup uploaded files in server/public and server/private.
To backup the database: docker exec -t planka-postgres-1 pg_dumpall -c -U postgres > dump.sql.

And finally, once I have made the backup, how do I upload the backup?

Mount volumes and copy uploaded files from the backup.
To restore the database: cat dump.sql | docker exec -i planka-postgres-1 psql -U postgres.

@meltyshev commented on GitHub (Jan 9, 2023): > If I have already created the board with different things, and I want to delete everything I did, how do I delete it? I tried deleting the container, the image and when I re-download and install it, it returns to the way I left it and not by default. There are 4 volumes: `user-avatars`, `project-background-images`, `attachments`, `db-data`. To delete all data you have to [delete](https://docs.docker.com/engine/reference/commandline/volume_rm/) all docker volumes. > If I want to make a backup. What are the files that I should save? And how is the step by step to perform the backup of postgres? Mount volumes and backup uploaded files in `server/public` and `server/private`. To backup the database: `docker exec -t planka-postgres-1 pg_dumpall -c -U postgres > dump.sql`. > And finally, once I have made the backup, how do I upload the backup? Mount volumes and copy uploaded files from the backup. To restore the database: `cat dump.sql | docker exec -i planka-postgres-1 psql -U postgres`.
Author
Owner

@vsaw commented on GitHub (Jan 16, 2023):

Duplicate of https://github.com/plankanban/planka/issues/128 therefore suggest to close this issue.

@vsaw commented on GitHub (Jan 16, 2023): Duplicate of https://github.com/plankanban/planka/issues/128 therefore suggest to close this issue.
Author
Owner

@Daniel-Why commented on GitHub (Oct 27, 2023):

Hi,where is the 2 folders(server/public and server/private)? I can't find

@Daniel-Why commented on GitHub (Oct 27, 2023): Hi,where is the 2 folders(```server/public``` and ```server/private```)? I can't find
Author
Owner

@vsaw commented on GitHub (Oct 27, 2023):

They are part of the docker container. You won't find them in your local file system unless you mount the folders with Docker to your local file system.

@vsaw commented on GitHub (Oct 27, 2023): They are part of the docker container. You won't find them in your local file system unless you mount the folders with Docker to your local file system.
Author
Owner

@Daniel-Why commented on GitHub (Nov 1, 2023):

They are part of the docker container. You won't find them in your local file system unless you mount the folders with Docker to your local file system.

thanks for you reply!I wanna know which docker container contains these files? I have searched in planka_planka_1 and planka_postgres_1, but I could not find them.

@Daniel-Why commented on GitHub (Nov 1, 2023): > They are part of the docker container. You won't find them in your local file system unless you mount the folders with Docker to your local file system. thanks for you reply!I wanna know which docker container contains these files? I have searched in planka_planka_1 and planka_postgres_1, but I could not find them.
Author
Owner

@Daniel-Why commented on GitHub (Nov 1, 2023):

They are part of the docker container. You won't find them in your local file system unless you mount the folders with Docker to your local file system.

thanks for you reply!I wanna know which docker container contains these files? I have searched in planka_planka_1 and planka_postgres_1, but I could not find them.

😸
I found these folders. There is no folder named "server". The "public" and "private" folders are located in the container "plank_plank_1" at the path "/app".

@Daniel-Why commented on GitHub (Nov 1, 2023): > > They are part of the docker container. You won't find them in your local file system unless you mount the folders with Docker to your local file system. > > thanks for you reply!I wanna know which docker container contains these files? I have searched in planka_planka_1 and planka_postgres_1, but I could not find them. 😸 I found these folders. There is no folder named "server". The "public" and "private" folders are located in the container "plank_plank_1" at the path "/app".
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/planka#270