Skip to content
Snippets Groups Projects
Commit 3c8fb323 authored by Marin Jankovski's avatar Marin Jankovski
Browse files

Relocate configuration section. Extract backup to a separate doc.

parent 33396a40
No related branches found
No related tags found
1 merge request!410Major docs update
Loading
Loading
@@ -27,7 +27,7 @@ Omnibus GitLab is using a fork of [omnibus project](https://github.com/chef/omni
To setup GitLab CI please see the [separate GitLab CI
documentation](doc/gitlab-ci/README.md).
 
## Configuration options
### Configuration options
 
See [doc/settings/configuration.md](doc/settings/configuration.md).
 
Loading
Loading
@@ -109,6 +109,10 @@ See [doc/settings/nginx.md](doc/settings/nginx.md).
 
See [doc/settings/nginx.md](doc/settings/nginx.md).
 
##### Only start omnibus-gitlab services after a given filesystem is mounted
See [doc/settings/configuration.md](doc/settings/configuration.md#only-start-omnibus-gitlab-services-after-a-given-filesystem-is-mounted).
## Installation
 
Please follow the steps on the [downloads page][downloads].
Loading
Loading
@@ -262,60 +266,26 @@ See [doc/common_installation_problems.md](doc/common_installation_problems.md#gi
See [doc/common_installation_problems.md](doc/common_installation_problems.mdr#short-read-or-oom-loading-db-error).
 
 
## Configuration
### Backups
 
### Backup and restore omnibus-gitlab configuration
See [doc/settings/backups.md](doc/settings/backups.md).
 
All configuration for omnibus-gitlab is stored in `/etc/gitlab`. To backup your
configuration, just backup this directory.
##### Backup and restore omnibus-gitlab configuration
 
```shell
# Example backup command for /etc/gitlab:
# Create a time-stamped .tar file in the current directory.
# The .tar file will be readable only to root.
sudo sh -c 'umask 0077; tar -cf $(date "+etc-gitlab-%s.tar") -C / etc/gitlab'
```
See [doc/settings/backups.md](doc/settings/backups.md#backup-and-restore-omnibus-gitlab-configuration).
 
You can extract the .tar file as follows.
```shell
# Rename the existing /etc/gitlab, if any
sudo mv /etc/gitlab /etc/gitlab.$(date +%s)
# Change the example timestamp below for your configuration backup
sudo tar -xf etc-gitlab-1399948539.tar -C /
```
##### Creating an application backup
 
Remember to run `sudo gitlab-ctl reconfigure` after restoring a configuration
backup.
NOTE: Your machines SSH host keys are stored in a separate location at `/etc/ssh/`. Be sure to also [backup and restore those keys](https://superuser.com/questions/532040/copy-ssh-keys-from-one-server-to-another-server/532079#532079) to avoid man-in-the-middle attack warnings if you have to perform a full machine restore.
See [doc/settings/backups.md](doc/settings/backups.md#creating-an-application-backup).
 
### Restoring an application backup
 
See [backup restore documentation](http://doc.gitlab.com/ce/raketasks/backup_restore.html#omnibus-installations).
 
## Backups
### Backup and restore using non-packaged database
 
If you are using non-packaged database see [documentation on using non-packaged database](doc/settings/database.md#using-a-non-packaged-postgresql-database-management-server).
 
### Creating an application backup
To create a backup of your repositories and GitLab metadata, follow the [backup create documentation](http://doc.gitlab.com/ce/raketasks/backup_restore.html#create-a-backup-of-the-gitlab-system).
Backup create will store a tar file in `/var/opt/gitlab/backups`.
Similarly for CI, backup create will store a tar file in `/var/opt/gitlab/ci-backups`.
If you want to store your GitLab backups in a different directory, add the
following setting to `/etc/gitlab/gitlab.rb` and run `sudo gitlab-ctl
reconfigure`:
```ruby
gitlab_rails['backup_path'] = '/mnt/backups'
```
### Restoring an application backup
See [backup restore documentation](http://doc.gitlab.com/ce/raketasks/backup_restore.html#omnibus-installations).
### Upload backups to remote (cloud) storage
 
For details check [backup restore document of GitLab CE](https://gitlab.com/gitlab-org/gitlab-ce/blob/966f68b33e1f15f08e383ec68346ed1bd690b59b/doc/raketasks/backup_restore.md#upload-backups-to-remote-cloud-storage).
Loading
Loading
@@ -418,17 +388,6 @@ See [doc/settings/database.md](doc/settings/database.md).
 
See [doc/settings/database.md](doc/settings/database.md).
 
## Only start omnibus-gitlab services after a given filesystem is mounted
If you want to prevent omnibus-gitlab services (nginx, redis, unicorn etc.)
from starting before a given filesystem is mounted, add the following to
`/etc/gitlab/gitlab.rb`:
```ruby
# wait for /var/opt/gitlab to be mounted
high_availability['mountpoint'] = '/var/opt/gitlab'
```
## Building your own package
 
See [the separate build documentation](doc/build.md).
Loading
Loading
Loading
Loading
@@ -10,3 +10,4 @@
- [Redis](redis.md)
- [Database](database.md)
- [Logs](logs.md)
- [Backups](backups.md)
# Backups
### Backup and restore omnibus-gitlab configuration
All configuration for omnibus-gitlab is stored in `/etc/gitlab`. To backup your
configuration, just backup this directory.
```shell
# Example backup command for /etc/gitlab:
# Create a time-stamped .tar file in the current directory.
# The .tar file will be readable only to root.
sudo sh -c 'umask 0077; tar -cf $(date "+etc-gitlab-%s.tar") -C / etc/gitlab'
```
You can extract the .tar file as follows.
```shell
# Rename the existing /etc/gitlab, if any
sudo mv /etc/gitlab /etc/gitlab.$(date +%s)
# Change the example timestamp below for your configuration backup
sudo tar -xf etc-gitlab-1399948539.tar -C /
```
Remember to run `sudo gitlab-ctl reconfigure` after restoring a configuration
backup.
NOTE: Your machines SSH host keys are stored in a separate location at `/etc/ssh/`. Be sure to also [backup and restore those keys](https://superuser.com/questions/532040/copy-ssh-keys-from-one-server-to-another-server/532079#532079) to avoid man-in-the-middle attack warnings if you have to perform a full machine restore.
### Creating an application backup
To create a backup of your repositories and GitLab metadata, follow the [backup create documentation](http://doc.gitlab.com/ce/raketasks/backup_restore.html#create-a-backup-of-the-gitlab-system).
Backup create will store a tar file in `/var/opt/gitlab/backups`.
Similarly for CI, backup create will store a tar file in `/var/opt/gitlab/ci-backups`.
If you want to store your GitLab backups in a different directory, add the
following setting to `/etc/gitlab/gitlab.rb` and run `sudo gitlab-ctl
reconfigure`:
```ruby
gitlab_rails['backup_path'] = '/mnt/backups'
```
### Restoring an application backup
See [backup restore documentation](http://doc.gitlab.com/ce/raketasks/backup_restore.html#omnibus-installations).
### Backup and restore using non-packaged database
If you are using non-packaged database see [documentation on using non-packaged database](doc/settings/database.md#using-a-non-packaged-postgresql-database-management-server).
### Upload backups to remote (cloud) storage
For details check [backup restore document of GitLab CE](https://gitlab.com/gitlab-org/gitlab-ce/blob/966f68b33e1f15f08e383ec68346ed1bd690b59b/doc/raketasks/backup_restore.md#upload-backups-to-remote-cloud-storage).
Loading
Loading
@@ -75,6 +75,38 @@ user['group'] = "gitlab"
 
Run `sudo gitlab-ctl reconfigure` for the change to take effect.
 
### Specify numeric user and group identifiers
Omnibus-gitlab creates users for GitLab, PostgreSQL, Redis and NGINX. You can
specify the numeric identifiers for these users in `/etc/gitlab/gitlab.rb` as
follows.
```ruby
user['uid'] = 1234
user['gid'] = 1234
postgresql['uid'] = 1235
postgresql['gid'] = 1235
redis['uid'] = 1236
redis['gid'] = 1236
web_server['uid'] = 1237
web_server['gid'] = 1237
```
Run `sudo gitlab-ctl reconfigure` for the changes to take effect.
## Only start omnibus-gitlab services after a given filesystem is mounted
If you want to prevent omnibus-gitlab services (nginx, redis, unicorn etc.)
from starting before a given filesystem is mounted, add the following to
`/etc/gitlab/gitlab.rb`:
```ruby
# wait for /var/opt/gitlab to be mounted
high_availability['mountpoint'] = '/var/opt/gitlab'
```
Run `sudo gitlab-ctl reconfigure` for the change to take effect.
### Setting up LDAP sign-in
 
See [doc/settings/ldap.md](doc/settings/ldap.md).
Loading
Loading
@@ -112,23 +144,6 @@ See
 
See [doc/settings/gitlab.yml.md](doc/settings/gitlab.yml.md).
 
### Specify numeric user and group identifiers
Omnibus-gitlab creates users for GitLab, PostgreSQL, Redis and NGINX. You can
specify the numeric identifiers for these users in `/etc/gitlab/gitlab.rb` as
follows.
```ruby
user['uid'] = 1234
user['gid'] = 1234
postgresql['uid'] = 1235
postgresql['gid'] = 1235
redis['uid'] = 1236
redis['gid'] = 1236
web_server['uid'] = 1237
web_server['gid'] = 1237
```
### Sending application email via SMTP
 
See [doc/settings/smtp.md](doc/settings/smtp.md).
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment