mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2024-12-25 09:47:30 +00:00
Update backup instructions to align with archive structure (#26902)
Signed-off-by: JonRB <jon.roadleybattin@gmail.com> fixes https://github.com/go-gitea/gitea/issues/25878
This commit is contained in:
parent
682552378f
commit
1859c5b636
|
@ -43,10 +43,10 @@ directory. There should be some output similar to the following:
|
||||||
Inside the `gitea-dump-1482906742.zip` file, will be the following:
|
Inside the `gitea-dump-1482906742.zip` file, will be the following:
|
||||||
|
|
||||||
- `app.ini` - Optional copy of configuration file if originally stored outside the default `custom/` directory
|
- `app.ini` - Optional copy of configuration file if originally stored outside the default `custom/` directory
|
||||||
- `custom` - All config or customization files in `custom/`.
|
- `custom/` - All config or customization files in `custom/`.
|
||||||
- `data` - Data directory (APP_DATA_PATH), except sessions if you are using file session. This directory includes `attachments`, `avatars`, `lfs`, `indexers`, SQLite file if you are using SQLite.
|
- `data/` - Data directory (APP_DATA_PATH), except sessions if you are using file session. This directory includes `attachments`, `avatars`, `lfs`, `indexers`, SQLite file if you are using SQLite.
|
||||||
|
- `repos/` - Complete copy of the repository directory.
|
||||||
- `gitea-db.sql` - SQL dump of database
|
- `gitea-db.sql` - SQL dump of database
|
||||||
- `gitea-repo.zip` - Complete copy of the repository directory.
|
|
||||||
- `log/` - Various logs. They are not needed for a recovery or migration.
|
- `log/` - Various logs. They are not needed for a recovery or migration.
|
||||||
|
|
||||||
Intermediate backup files are created in a temporary directory specified either with the
|
Intermediate backup files are created in a temporary directory specified either with the
|
||||||
|
@ -89,10 +89,10 @@ Example:
|
||||||
```sh
|
```sh
|
||||||
unzip gitea-dump-1610949662.zip
|
unzip gitea-dump-1610949662.zip
|
||||||
cd gitea-dump-1610949662
|
cd gitea-dump-1610949662
|
||||||
mv data/conf/app.ini /etc/gitea/conf/app.ini
|
mv app.ini /etc/gitea/conf/app.ini
|
||||||
mv data/* /var/lib/gitea/data/
|
mv data/* /var/lib/gitea/data/
|
||||||
mv log/* /var/lib/gitea/log/
|
mv log/* /var/lib/gitea/log/
|
||||||
mv repos/* /var/lib/gitea/repositories/
|
mv repos/* /var/lib/gitea/gitea-repositories/
|
||||||
chown -R gitea:gitea /etc/gitea/conf/app.ini /var/lib/gitea
|
chown -R gitea:gitea /etc/gitea/conf/app.ini /var/lib/gitea
|
||||||
|
|
||||||
# mysql
|
# mysql
|
||||||
|
@ -126,7 +126,7 @@ cd gitea-dump-1610949662
|
||||||
# restore the gitea data
|
# restore the gitea data
|
||||||
mv data/* /data/gitea
|
mv data/* /data/gitea
|
||||||
# restore the repositories itself
|
# restore the repositories itself
|
||||||
mv repos/* /data/git/repositories/
|
mv repos/* /data/git/gitea-repositories/
|
||||||
# adjust file permissions
|
# adjust file permissions
|
||||||
chown -R git:git /data
|
chown -R git:git /data
|
||||||
# Regenerate Git Hooks
|
# Regenerate Git Hooks
|
||||||
|
@ -150,7 +150,7 @@ mv data/conf/app.ini /etc/gitea/app.ini
|
||||||
# restore the gitea data
|
# restore the gitea data
|
||||||
mv data/* /var/lib/gitea
|
mv data/* /var/lib/gitea
|
||||||
# restore the repositories itself
|
# restore the repositories itself
|
||||||
mv repos/* /var/lib/gitea/git/repositories
|
mv repos/* /var/lib/gitea/git/gitea-repositories
|
||||||
# adjust file permissions
|
# adjust file permissions
|
||||||
chown -R git:git /etc/gitea/app.ini /var/lib/gitea
|
chown -R git:git /etc/gitea/app.ini /var/lib/gitea
|
||||||
# Regenerate Git Hooks
|
# Regenerate Git Hooks
|
||||||
|
|
Loading…
Reference in a new issue