提交 92663f73 编写于 作者: R Robert Marshall 提交者: Achilleas Pipinellis

Document EE License Auto Import During Install

- Document how to properly configure `GITLAB_LICENSE_FILE` environment
  variable in source and omnibus installations.

Resolves: https://gitlab.com/gitlab-org/gitlab-ee/issues/10808Signed-off-by: NRobert Marshall <rmarshall@gitlab.com>
上级 12752f3d
---
title: Document EE License Auto Import During Install
merge_request: 28106
author:
type: other
......@@ -40,6 +40,7 @@ Learn how to install, configure, update, and maintain your GitLab instance.
- [Geo](https://docs.gitlab.com/ee/administration/geo/replication/index.html): Replicate your GitLab instance to other geographic locations as a read-only fully operational version. **[PREMIUM ONLY]**
- [Disaster Recovery](https://docs.gitlab.com/ee/administration/geo/disaster_recovery/index.html): Quickly fail-over to a different site with minimal effort in a disaster situation. **[PREMIUM ONLY]**
- [Pivotal Tile](https://docs.gitlab.com/ee/install/pivotal/index.html): Deploy GitLab as a pre-configured appliance using Ops Manager (BOSH) for Pivotal Cloud Foundry. **[PREMIUM ONLY]**
- [Add License](../user/admin_area/license.md): Upload a license at install time to unlock features that are in paid tiers of GitLab. **[STARTER ONLY]**
### Configuring GitLab
......
......@@ -579,10 +579,10 @@ sudo -u git -H bundle exec rake gitlab:setup RAILS_ENV=production force=yes
```
NOTE: **Note:**
You can set the Administrator/root password and e-mail by supplying them in environmental variables, `GITLAB_ROOT_PASSWORD` and `GITLAB_ROOT_EMAIL` respectively, as seen below. If you don't set the password (and it is set to the default one), wait to expose GitLab to the public internet until the installation is done and you've logged into the server the first time. During the first login, you'll be forced to change the default password.
You can set the Administrator/root password and e-mail by supplying them in environmental variables, `GITLAB_ROOT_PASSWORD` and `GITLAB_ROOT_EMAIL` respectively, as seen below. If you don't set the password (and it is set to the default one), wait to expose GitLab to the public internet until the installation is done and you've logged into the server the first time. During the first login, you'll be forced to change the default password. An Enterprise Edition license may also be installed at this time by supplying a full path in the `GITLAB_LICENSE_FILE` environment variable.
```sh
sudo -u git -H bundle exec rake gitlab:setup RAILS_ENV=production GITLAB_ROOT_PASSWORD=yourpassword GITLAB_ROOT_EMAIL=youremail
sudo -u git -H bundle exec rake gitlab:setup RAILS_ENV=production GITLAB_ROOT_PASSWORD=yourpassword GITLAB_ROOT_EMAIL=youremail GITLAB_LICENSE_FILE="/path/to/license"
```
### Secure secrets.yml
......
......@@ -2,7 +2,8 @@
To activate all GitLab Enterprise Edition (EE) functionality, you need to upload
a license. Once you've received your license from GitLab Inc., you can upload it
by **signing into your GitLab instance as an admin**.
by **signing into your GitLab instance as an admin** or add it at
installation time.
The license has the form of a base64 encoded ASCII text with a `.gitlab-license`
extension and can be obtained when you [purchase one][pricing] or when you sign
......@@ -42,6 +43,36 @@ Otherwise, you can:
"Enter license key" option, copy the license, paste it into the "License key"
field and click **Upload license**.
## Add your license at install time
The license may be automatically injected during installation using one of
two methods.
The first requires a license file named `Gitlab.gitlab-release`.
Place it in the `config/` directory if installing from source or in the
`/etc/gitlab/` directory if installing Omnibus.
The second allows the administrator to configure the location and
filename of the license.
Source installations should set the `GITLAB_LICENSE_FILE` environment
variable with the path to a valid GitLab Enterprise Edition license.
```sh
export GITLAB_LICENSE_FILE="/path/to/license/file"
```
Omnibus installations should add this entry to `gitlab.rb`:
```ruby
gitlab_rails['license_file'] = "/path/to/license/file"
```
CAUTION:: **Caution:**
These methods will only add a license at the time of installation. Use the
admin area in the web ui to renew or upgrade licenses.
---
Once the license is uploaded, all GitLab Enterprise Edition functionality
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册