From 9d40457766d3f7154780d57deb787d3e87934b49 Mon Sep 17 00:00:00 2001 From: karen Carias Date: Tue, 25 Aug 2015 21:57:10 -0700 Subject: added new commands --- doc/gitlab-basics/basic-git-commands.md | 2 ++ doc/gitlab-basics/command-line-commands.md | 8 ++++++++ 2 files changed, 10 insertions(+) (limited to 'doc') diff --git a/doc/gitlab-basics/basic-git-commands.md b/doc/gitlab-basics/basic-git-commands.md index 2b5767dd2d3..172568b5a1d 100644 --- a/doc/gitlab-basics/basic-git-commands.md +++ b/doc/gitlab-basics/basic-git-commands.md @@ -34,6 +34,8 @@ You'll see your changes in red when you type "git status". ``` git add CHANGES IN RED git commit -m "DESCRIBE THE INTENTION OF THE COMMIT" +or +git commit -am "DESCRIBE THE INTENTION OF THE COMMIT WITH AN ADDITIONAL MESSAGE" ``` ### Send changes to gitlab.com diff --git a/doc/gitlab-basics/command-line-commands.md b/doc/gitlab-basics/command-line-commands.md index b03cca4029c..5d22e29a86b 100644 --- a/doc/gitlab-basics/command-line-commands.md +++ b/doc/gitlab-basics/command-line-commands.md @@ -72,3 +72,11 @@ You will be asked for an administrator’s password. ``` sudo ``` + +### Tell where you are +``` +pwd +``` + +### Open new command line window +Press `command + t` on your keyboard. -- cgit v1.2.3 From bff8376ab15c7fb621f26673213e4d928c5bf8c6 Mon Sep 17 00:00:00 2001 From: karen Carias Date: Tue, 25 Aug 2015 21:58:40 -0700 Subject: added new commands --- doc/gitlab-basics/basic-git-commands.md | 2 -- 1 file changed, 2 deletions(-) (limited to 'doc') diff --git a/doc/gitlab-basics/basic-git-commands.md b/doc/gitlab-basics/basic-git-commands.md index 172568b5a1d..2b5767dd2d3 100644 --- a/doc/gitlab-basics/basic-git-commands.md +++ b/doc/gitlab-basics/basic-git-commands.md @@ -34,8 +34,6 @@ You'll see your changes in red when you type "git status". ``` git add CHANGES IN RED git commit -m "DESCRIBE THE INTENTION OF THE COMMIT" -or -git commit -am "DESCRIBE THE INTENTION OF THE COMMIT WITH AN ADDITIONAL MESSAGE" ``` ### Send changes to gitlab.com -- cgit v1.2.3 From e334ec0683b77f46f19e1474289a9edfd2fb8c13 Mon Sep 17 00:00:00 2001 From: Achilleas Pipinellis Date: Mon, 31 Aug 2015 08:24:50 +0300 Subject: Ordering of GitHub issues import is now fixed See https://gitlab.com/gitlab-org/gitlab-ce/commit/4a203aab57c69ea402939cf8fc423a0e5aaa1cab --- doc/workflow/importing/import_projects_from_github.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'doc') diff --git a/doc/workflow/importing/import_projects_from_github.md b/doc/workflow/importing/import_projects_from_github.md index 3efa92cb868..2d77c6d1172 100644 --- a/doc/workflow/importing/import_projects_from_github.md +++ b/doc/workflow/importing/import_projects_from_github.md @@ -17,4 +17,4 @@ If you want to import from a GitHub Enterprise instance, you need to use GitLab * To import a project, you can simple click "Add". The importer will import your repository and issues. Once the importer is done, a new GitLab project will be created with your imported data. ### Note -When you import your projects from GitHub, it is not possible to keep your labels and milestones and issue numbers won't match. We are working on improving this in the near future. +When you import your projects from GitHub, it is not possible to keep your labels and milestones. We are working on improving this in the near future. -- cgit v1.2.3 From 4027a26e7b5a1a2a54dd57e480507095c91af26b Mon Sep 17 00:00:00 2001 From: Jacob Vosmaer Date: Mon, 31 Aug 2015 15:30:15 +0200 Subject: Replace grack with gitlab-git-http-server --- doc/install/installation.md | 29 ++++++-- doc/update/7.14-to-8.0.md | 159 ++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 183 insertions(+), 5 deletions(-) create mode 100644 doc/update/7.14-to-8.0.md (limited to 'doc') diff --git a/doc/install/installation.md b/doc/install/installation.md index 73e36fa7e51..52031e9b9a1 100644 --- a/doc/install/installation.md +++ b/doc/install/installation.md @@ -125,13 +125,25 @@ Install the Bundler Gem: sudo gem install bundler --no-ri --no-rdoc -## 3. System Users +## 3. Go + +Since GitLab 8.0, Git HTTP requests are handled by gitlab-git-http-server. +This is a small daemon written in Go. +To install gitlab-git-http-server we need a Go compiler. + + curl -O --progress https://storage.googleapis.com/golang/go1.5.linux-amd64.tar.gz + echo '5817fa4b2252afdb02e11e8b9dc1d9173ef3bd5a go1.5.linux-amd64.tar.gz' | shasum -c - && \ + sudo tar -C /usr/local -xzf go1.5.linux-amd64.tar.gz + sudo ln -sf /usr/local/go/bin/{go,godoc,gofmt} /usr/local/bin/ + rm go1.5.linux-amd64.tar.gz + +## 4. System Users Create a `git` user for GitLab: sudo adduser --disabled-login --gecos 'GitLab' git -## 4. Database +## 5. Database We recommend using a PostgreSQL database. For MySQL check [MySQL setup guide](database_mysql.md). *Note*: because we need to make use of extensions you need at least pgsql 9.1. @@ -157,7 +169,7 @@ We recommend using a PostgreSQL database. For MySQL check [MySQL setup guide](da # Quit the database session gitlabhq_production> \q -## 5. Redis +## 6. Redis sudo apt-get install redis-server @@ -187,7 +199,7 @@ We recommend using a PostgreSQL database. For MySQL check [MySQL setup guide](da # Add git to the redis group sudo usermod -aG redis git -## 6. GitLab +## 7. GitLab # We'll install GitLab into home directory of the user "git" cd /home/git @@ -297,6 +309,13 @@ GitLab Shell is an SSH access and repository management software developed speci **Note:** Make sure your hostname can be resolved on the machine itself by either a proper DNS record or an additional line in /etc/hosts ("127.0.0.1 hostname"). This might be necessary for example if you set up gitlab behind a reverse proxy. If the hostname cannot be resolved, the final installation check will fail with "Check GitLab API access: FAILED. code: 401" and pushing commits will be rejected with "[remote rejected] master -> master (hook declined)". +### Install gitlab-git-http-server + + cd /home/git + sudo -u git -H git clone https://gitlab.com/gitlab-org/gitlab-git-http-server.git + cd gitlab-git-http-server + sudo -u git -H make + ### Initialize Database and Activate Advanced Features sudo -u git -H bundle exec rake gitlab:setup RAILS_ENV=production @@ -345,7 +364,7 @@ Check if GitLab and its environment are configured correctly: # or sudo /etc/init.d/gitlab restart -## 7. Nginx +## 8. Nginx **Note:** Nginx is the officially supported web server for GitLab. If you cannot or do not want to use Nginx as your web server, have a look at the [GitLab recipes](https://gitlab.com/gitlab-org/gitlab-recipes/). diff --git a/doc/update/7.14-to-8.0.md b/doc/update/7.14-to-8.0.md new file mode 100644 index 00000000000..29a38d07b3d --- /dev/null +++ b/doc/update/7.14-to-8.0.md @@ -0,0 +1,159 @@ +# From 7.14 to 8.0 + +### 0. Double-check your Git version + +**This notice applies only to /usr/local/bin/git** + +If you compiled Git from source on your GitLab server then please double-check +that you are using a version that protects against CVE-2014-9390. For six +months after this vulnerability became known the GitLab installation guide +still contained instructions that would install the outdated, 'vulnerable' Git +version 2.1.2. + +Run the following command to get your current Git version. + +``` +/usr/local/bin/git --version +``` + +If you see 'No such file or directory' then you did not install Git according +to the outdated instructions from the GitLab installation guide and you can go +to the next step 'Stop server' below. + +If you see a version string then it should be v1.8.5.6, v1.9.5, v2.0.5, v2.1.4, +v2.2.1 or newer. You can use the [instructions in the GitLab source +installation +guide](https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/install/installation.md#1-packages-dependencies) +to install a newer version of Git. + +### 1. Stop server + + sudo service gitlab stop + +### 2. Backup + +```bash +cd /home/git/gitlab +sudo -u git -H bundle exec rake gitlab:backup:create RAILS_ENV=production +``` + +### 3. Get latest code + +```bash +sudo -u git -H git fetch --all +sudo -u git -H git checkout -- db/schema.rb # local changes will be restored automatically +``` + +For GitLab Community Edition: + +```bash +sudo -u git -H git checkout 8-0-stable +``` + +OR + +For GitLab Enterprise Edition: + +```bash +sudo -u git -H git checkout 8-0-stable-ee +``` + +### 4. Update gitlab-shell + +```bash +cd /home/git/gitlab-shell +sudo -u git -H git fetch +sudo -u git -H git checkout v2.6.4 +``` + +### 5. Install gitlab-git-http-server + +First we download Go 1.5 and install it into /usr/local/go. + + curl -O --progress https://storage.googleapis.com/golang/go1.5.linux-amd64.tar.gz + echo '5817fa4b2252afdb02e11e8b9dc1d9173ef3bd5a go1.5.linux-amd64.tar.gz' | shasum -c - && \ + sudo tar -C /usr/local -xzf go1.5.linux-amd64.tar.gz + sudo ln -sf /usr/local/go/bin/{go,godoc,gofmt} /usr/local/bin/ + rm go1.5.linux-amd64.tar.gz + +Now we download gitlab-git-http-server and install it in /home/git/gitlab-git-http-server. + + cd /home/git + sudo -u git -H git clone https://gitlab.com/gitlab-org/gitlab-git-http-server.git + cd gitlab-git-http-server + sudo -u git -H make + +If you put your Git repositories in a directory different from /home/git/repositories, you need to tell gitlab-git-http-server about it via /etc/gitlab/default. +See lib/support/init.d/gitlab.default.example for the options. + +### 6. Install libs, migrations, etc. + +```bash +cd /home/git/gitlab + +# MySQL installations (note: the line below states '--without ... postgres') +sudo -u git -H bundle install --without development test postgres --deployment + +# PostgreSQL installations (note: the line below states '--without ... mysql') +sudo -u git -H bundle install --without development test mysql --deployment + +# Run database migrations +sudo -u git -H bundle exec rake db:migrate RAILS_ENV=production + +# Clean up assets and cache +sudo -u git -H bundle exec rake assets:clean assets:precompile cache:clear RAILS_ENV=production + +# Update init.d script +sudo cp lib/support/init.d/gitlab /etc/init.d/gitlab +``` + +### 7. Update config files + +#### New configuration options for `gitlab.yml` + +There are new configuration options available for [`gitlab.yml`](config/gitlab.yml.example). View them with the command below and apply them to your current `gitlab.yml`. + +``` +git diff origin/7-14-stable:config/gitlab.yml.example origin/8-0-stable:config/gitlab.yml.example +`````` + +#### New NGINX configuration + +Because of the new gitlab-git-http-server you need to update your NGINX configuration. +If you skip this step 'git clone' and 'git push' over HTTP(S) will stop working. + +``` +# Remove '-ssl' twice in the diff command below if you use HTTP instead of HTTPS +git diff origin/7-14-stable:lib/support/nginx/gitlab-ssl origin/8-0-stable:lib/support/nginx/gitlab-ssl +``` + +### 8. Start application + + sudo service gitlab start + sudo service nginx restart + +### 9. Check application status + +Check if GitLab and its environment are configured correctly: + + sudo -u git -H bundle exec rake gitlab:env:info RAILS_ENV=production + +To make sure you didn't miss anything run a more thorough check with: + + sudo -u git -H bundle exec rake gitlab:check RAILS_ENV=production + +If all items are green, then congratulations, the upgrade is complete! + +## Things went south? Revert to previous version (7.14) + +### 1. Revert the code to the previous version +Follow the [upgrade guide from 7.13 to 7.14](7.13-to-7.14.md), except for the database migration +(The backup is already migrated to the previous version) + +### 2. Restore from the backup: + +```bash +cd /home/git/gitlab +sudo -u git -H bundle exec rake gitlab:backup:restore RAILS_ENV=production +``` +If you have more than one backup *.tar file(s) please add `BACKUP=timestamp_of_backup` to the command above. -- cgit v1.2.3 From c924a3a8d79272355442e9ee595f09c79b0819d4 Mon Sep 17 00:00:00 2001 From: karen Carias Date: Mon, 31 Aug 2015 22:50:32 -0700 Subject: deleted additional info --- doc/gitlab-basics/command-line-commands.md | 3 --- 1 file changed, 3 deletions(-) (limited to 'doc') diff --git a/doc/gitlab-basics/command-line-commands.md b/doc/gitlab-basics/command-line-commands.md index 5d22e29a86b..addd3b6b6eb 100644 --- a/doc/gitlab-basics/command-line-commands.md +++ b/doc/gitlab-basics/command-line-commands.md @@ -77,6 +77,3 @@ sudo ``` pwd ``` - -### Open new command line window -Press `command + t` on your keyboard. -- cgit v1.2.3 From 263abda3fd7ddfb826cd17ae88fb47d0e1d67fae Mon Sep 17 00:00:00 2001 From: Kirilll Zaitsev Date: Thu, 27 Aug 2015 02:58:49 +0300 Subject: Drone CI service --- doc/api/services.md | 506 ++++++++++++++++++++++++++++++++++++++++++++- doc/web_hooks/web_hooks.md | 4 + 2 files changed, 502 insertions(+), 8 deletions(-) (limited to 'doc') diff --git a/doc/api/services.md b/doc/api/services.md index cbf767d1b25..bc5049dd302 100644 --- a/doc/api/services.md +++ b/doc/api/services.md @@ -1,8 +1,296 @@ # Services +## Asana + +Asana - Teamwork without email + +### Create/Edit Asana service + +Set Asana service for a project. + +> This service adds commit messages as comments to Asana tasks. Once enabled, commit messages are checked for Asana task URLs (for example, `https://app.asana.com/0/123456/987654`) or task IDs starting with # (for example, `#987654`). Every task ID found will get the commit comment added to it. You can also close a task with a message containing: `fix #123456`. You can find your Api Keys here: http://developer.asana.com/documentation/#api_keys + +``` +PUT /projects/:id/services/asana +``` + +Parameters: + +- `api_key` (**required**) - User API token. User must have access to task,all comments will be attributed to this user. +- `restrict_to_branch` (optional) - Comma-separated list of branches which will beautomatically inspected. Leave blank to include all branches. + +### Delete Asana service + +Delete Asana service for a project. + +``` +DELETE /projects/:id/services/asana +``` + +## Assembla + +Project Management Software (Source Commits Endpoint) + +### Create/Edit Assembla service + +Set Assembla service for a project. + +``` +PUT /projects/:id/services/assembla +``` + +Parameters: + +- `token` (**required**) +- `subdomain` (optional) + +### Delete Assembla service + +Delete Assembla service for a project. + +``` +DELETE /projects/:id/services/assembla +``` + +## Atlassian Bamboo CI + +A continuous integration and build server + +### Create/Edit Atlassian Bamboo CI service + +Set Atlassian Bamboo CI service for a project. + +> You must set up automatic revision labeling and a repository trigger in Bamboo. + +``` +PUT /projects/:id/services/bamboo +``` + +Parameters: + +- `bamboo_url` (**required**) - Bamboo root URL like https://bamboo.example.com +- `build_key` (**required**) - Bamboo build plan key like KEY +- `username` (**required**) - A user with API access, if applicable +- `password` (**required**) + +### Delete Atlassian Bamboo CI service + +Delete Atlassian Bamboo CI service for a project. + +``` +DELETE /projects/:id/services/bamboo +``` + +## Buildkite + +Continuous integration and deployments + +### Create/Edit Buildkite service + +Set Buildkite service for a project. + +``` +PUT /projects/:id/services/buildkite +``` + +Parameters: + +- `token` (**required**) - Buildkite project GitLab token +- `project_url` (**required**) - https://buildkite.com/example/project +- `enable_ssl_verification` (optional) - Enable SSL verification + +### Delete Buildkite service + +Delete Buildkite service for a project. + +``` +DELETE /projects/:id/services/buildkite +``` + +## Campfire + +Simple web-based real-time group chat + +### Create/Edit Campfire service + +Set Campfire service for a project. + +``` +PUT /projects/:id/services/campfire +``` + +Parameters: + +- `token` (**required**) +- `subdomain` (optional) +- `room` (optional) + +### Delete Campfire service + +Delete Campfire service for a project. + +``` +DELETE /projects/:id/services/campfire +``` + +## Custom Issue Tracker + +Custom issue tracker + +### Create/Edit Custom Issue Tracker service + +Set Custom Issue Tracker service for a project. + +``` +PUT /projects/:id/services/custom-issue-tracker +``` + +Parameters: + +- `new_issue_url` (**required**) - New Issue url +- `issues_url` (**required**) - Issue url +- `project_url` (**required**) - Project url +- `description` (optional) - Custom issue tracker +- `title` (optional) - Custom Issue Tracker + +### Delete Custom Issue Tracker service + +Delete Custom Issue Tracker service for a project. + +``` +DELETE /projects/:id/services/custom-issue-tracker +``` + +## Drone CI + +Drone is a Continuous Integration platform built on Docker, written in Go + +### Create/Edit Drone CI service + +Set Drone CI service for a project. + +``` +PUT /projects/:id/services/drone-ci +``` + +Parameters: + +- `token` (**required**) - Drone CI project specific token +- `drone_url` (**required**) - http://drone.example.com +- `enable_ssl_verification` (optional) - Enable SSL verification + +### Delete Drone CI service + +Delete Drone CI service for a project. + +``` +DELETE /projects/:id/services/drone-ci +``` + +## Emails on push + +Email the commits and diff of each push to a list of recipients. + +### Create/Edit Emails on push service + +Set Emails on push service for a project. + +``` +PUT /projects/:id/services/emails-on-push +``` + +Parameters: + +- `recipients` (**required**) - Emails separated by whitespace +- `disable_diffs` (optional) - Disable code diffs +- `send_from_committer_email` (optional) - Send from committer + +### Delete Emails on push service + +Delete Emails on push service for a project. + +``` +DELETE /projects/:id/services/emails-on-push +``` + +## External Wiki + +Replaces the link to the internal wiki with a link to an external wiki. + +### Create/Edit External Wiki service + +Set External Wiki service for a project. + +``` +PUT /projects/:id/services/external-wiki +``` + +Parameters: + +- `external_wiki_url` (**required**) - The URL of the external Wiki + +### Delete External Wiki service + +Delete External Wiki service for a project. + +``` +DELETE /projects/:id/services/external-wiki +``` + +## Flowdock + +Flowdock is a collaboration web app for technical teams. + +### Create/Edit Flowdock service + +Set Flowdock service for a project. + +``` +PUT /projects/:id/services/flowdock +``` + +Parameters: + +- `token` (**required**) - Flowdock Git source token + +### Delete Flowdock service + +Delete Flowdock service for a project. + +``` +DELETE /projects/:id/services/flowdock +``` + +## Gemnasium + +Gemnasium monitors your project dependencies and alerts you about updates and security vulnerabilities. + +### Create/Edit Gemnasium service + +Set Gemnasium service for a project. + +``` +PUT /projects/:id/services/gemnasium +``` + +Parameters: + +- `api_key` (**required**) - Your personal API KEY on gemnasium.com +- `token` (**required**) - The project's slug on gemnasium.com + +### Delete Gemnasium service + +Delete Gemnasium service for a project. + +``` +DELETE /projects/:id/services/gemnasium +``` + ## GitLab CI -### Edit GitLab CI service +Continuous integration server from GitLab + +### Create/Edit GitLab CI service Set GitLab CI service for a project. @@ -12,12 +300,13 @@ PUT /projects/:id/services/gitlab-ci Parameters: -- `token` (required) - CI project token -- `project_url` (required) - CI project URL +- `token` (**required**) - GitLab CI project specific token +- `project_url` (**required**) - http://ci.gitlabhq.com/projects/3 +- `enable_ssl_verification` (optional) - Enable SSL verification ### Delete GitLab CI service -Delete GitLab CI service settings for a project. +Delete GitLab CI service for a project. ``` DELETE /projects/:id/services/gitlab-ci @@ -25,17 +314,24 @@ DELETE /projects/:id/services/gitlab-ci ## HipChat -### Edit HipChat service +Private group chat and IM + +### Create/Edit HipChat service -Set HipChat service for project. +Set HipChat service for a project. ``` PUT /projects/:id/services/hipchat ``` + Parameters: -- `token` (required) - HipChat token -- `room` (required) - HipChat room name +- `token` (**required**) - Room token +- `color` (optional) +- `notify` (optional) +- `room` (optional) - Room name or ID +- `api_version` (optional) - Leave blank for default (v2) +- `server` (optional) - Leave blank for default. https://hipchat.example.com ### Delete HipChat service @@ -44,3 +340,197 @@ Delete HipChat service for a project. ``` DELETE /projects/:id/services/hipchat ``` + +## Irker (IRC gateway) + +Send IRC messages, on update, to a list of recipients through an Irker gateway. + +### Create/Edit Irker (IRC gateway) service + +Set Irker (IRC gateway) service for a project. + +> NOTE: Irker does NOT have built-in authentication, which makes it vulnerable to spamming IRC channels if it is hosted outside of a firewall. Please make sure you run the daemon within a secured network to prevent abuse. For more details, read: http://www.catb.org/~esr/irker/security.html. + +``` +PUT /projects/:id/services/irker +``` + +Parameters: + +- `recipients` (**required**) - Recipients/channels separated by whitespaces +- `default_irc_uri` (optional) - irc://irc.network.net:6697/ +- `server_port` (optional) - 6659 +- `server_host` (optional) - localhost +- `colorize_messages` (optional) + +### Delete Irker (IRC gateway) service + +Delete Irker (IRC gateway) service for a project. + +``` +DELETE /projects/:id/services/irker +``` + +## JIRA + +Jira issue tracker + +### Create/Edit JIRA service + +Set JIRA service for a project. + +> Setting `project_url`, `issues_url` and `new_issue_url` will allow a user to easily navigate to the Jira issue tracker. See the [integration doc](http://doc.gitlab.com/ce/integration/external-issue-tracker.html) for details. Support for referencing commits and automatic closing of Jira issues directly from GitLab is [available in GitLab EE.](http://doc.gitlab.com/ee/integration/jira.html) + +``` +PUT /projects/:id/services/jira +``` + +Parameters: + +- `new_issue_url` (**required**) - New Issue url +- `project_url` (**required**) - Project url +- `issues_url` (**required**) - Issue url +- `description` (optional) - Jira issue tracker + +### Delete JIRA service + +Delete JIRA service for a project. + +``` +DELETE /projects/:id/services/jira +``` + +## PivotalTracker + +Project Management Software (Source Commits Endpoint) + +### Create/Edit PivotalTracker service + +Set PivotalTracker service for a project. + +``` +PUT /projects/:id/services/pivotaltracker +``` + +Parameters: + +- `token` (**required**) + +### Delete PivotalTracker service + +Delete PivotalTracker service for a project. + +``` +DELETE /projects/:id/services/pivotaltracker +``` + +## Pushover + +Pushover makes it easy to get real-time notifications on your Android device, iPhone, iPad, and Desktop. + +### Create/Edit Pushover service + +Set Pushover service for a project. + +``` +PUT /projects/:id/services/pushover +``` + +Parameters: + +- `api_key` (**required**) - Your application key +- `user_key` (**required**) - Your user key +- `priority` (**required**) +- `device` (optional) - Leave blank for all active devices +- `sound` (optional) + +### Delete Pushover service + +Delete Pushover service for a project. + +``` +DELETE /projects/:id/services/pushover +``` + +## Redmine + +Redmine issue tracker + +### Create/Edit Redmine service + +Set Redmine service for a project. + +``` +PUT /projects/:id/services/redmine +``` + +Parameters: + +- `new_issue_url` (**required**) - New Issue url +- `project_url` (**required**) - Project url +- `issues_url` (**required**) - Issue url +- `description` (optional) - Redmine issue tracker + +### Delete Redmine service + +Delete Redmine service for a project. + +``` +DELETE /projects/:id/services/redmine +``` + +## Slack + +A team communication tool for the 21st century + +### Create/Edit Slack service + +Set Slack service for a project. + +``` +PUT /projects/:id/services/slack +``` + +Parameters: + +- `webhook` (**required**) - https://hooks.slack.com/services/... +- `username` (optional) - username +- `channel` (optional) - #channel + +### Delete Slack service + +Delete Slack service for a project. + +``` +DELETE /projects/:id/services/slack +``` + +## JetBrains TeamCity CI + +A continuous integration and build server + +### Create/Edit JetBrains TeamCity CI service + +Set JetBrains TeamCity CI service for a project. + +> The build configuration in Teamcity must use the build format number %build.vcs.number% you will also want to configure monitoring of all branches so merge requests build, that setting is in the vsc root advanced settings. + +``` +PUT /projects/:id/services/teamcity +``` + +Parameters: + +- `teamcity_url` (**required**) - TeamCity root URL like https://teamcity.example.com +- `build_type` (**required**) - Build configuration ID +- `username` (**required**) - A user with permissions to trigger a manual build +- `password` (**required**) + +### Delete JetBrains TeamCity CI service + +Delete JetBrains TeamCity CI service for a project. + +``` +DELETE /projects/:id/services/teamcity +``` + diff --git a/doc/web_hooks/web_hooks.md b/doc/web_hooks/web_hooks.md index 73717ffc7d6..09400d9b163 100644 --- a/doc/web_hooks/web_hooks.md +++ b/doc/web_hooks/web_hooks.md @@ -279,6 +279,7 @@ X-Gitlab-Event: Note Hook "name": "Gitlab Test", "ssh_url": "git@example.com:gitlab-org/gitlab-test.git", "http_url": "http://example.com/gitlab-org/gitlab-test.git", + "web_url": "http://example.com/gitlab-org/gitlab-test", "namespace": "Gitlab Org", "visibility_level": 10 }, @@ -286,6 +287,7 @@ X-Gitlab-Event: Note Hook "name": "Gitlab Test", "ssh_url": "git@example.com:gitlab-org/gitlab-test.git", "http_url": "http://example.com/gitlab-org/gitlab-test.git", + "web_url": "http://example.com/gitlab-org/gitlab-test", "namespace": "Gitlab Org", "visibility_level": 10 }, @@ -462,6 +464,7 @@ X-Gitlab-Event: Merge Request Hook "name": "awesome_project", "ssh_url": "ssh://git@example.com/awesome_space/awesome_project.git", "http_url": "http://example.com/awesome_space/awesome_project.git", + "web_url": "http://example.com/awesome_space/awesome_project", "visibility_level": 20, "namespace": "awesome_space" }, @@ -469,6 +472,7 @@ X-Gitlab-Event: Merge Request Hook "name": "awesome_project", "ssh_url": "ssh://git@example.com/awesome_space/awesome_project.git", "http_url": "http://example.com/awesome_space/awesome_project.git", + "web_url": "http://example.com/awesome_space/awesome_project", "visibility_level": 20, "namespace": "awesome_space" }, -- cgit v1.2.3 From 3700e5a9607ba9980940a29d275e22034538473d Mon Sep 17 00:00:00 2001 From: Valery Sizov Date: Mon, 31 Aug 2015 13:59:52 +0300 Subject: Crowd integration --- doc/integration/crowd.md | 58 +++++++++++++++++++++++++++++++++++++++++++++ doc/integration/omniauth.md | 1 + 2 files changed, 59 insertions(+) create mode 100644 doc/integration/crowd.md (limited to 'doc') diff --git a/doc/integration/crowd.md b/doc/integration/crowd.md new file mode 100644 index 00000000000..2ecc8795ac1 --- /dev/null +++ b/doc/integration/crowd.md @@ -0,0 +1,58 @@ +# Crowd OmniAuth Provider + +To enable the Crowd OmniAuth provider you must register your application with Crowd. To configure Crowd integration you need an application name and password. + +1. On your GitLab server, open the configuration file. + + For omnibus package: + + ```sh + sudo editor /etc/gitlab/gitlab.rb + ``` + + For instalations from source: + + ```sh + cd /home/git/gitlab + + sudo -u git -H editor config/gitlab.yml + ``` + +1. See [Initial OmniAuth Configuration](omniauth.md#initial-omniauth-configuration) for initial settings. + +1. Add the provider configuration: + + For omnibus package: + + ```ruby + gitlab_rails['omniauth_providers'] = [ + { + "name" => "crowd", + "args" => { + "crowd_server_url" => "CROWD", + "application_name" => "YOUR_APP_NAME", + "application_password" => "YOUR_APP_PASSWORD" + } + } + ] + ``` + + For installations from source: + + ``` + - { name: 'crowd', + args: { + crowd_server_url: 'CROWD SERVER URL', + application_name: 'YOUR_APP_NAME', + application_password: 'YOUR_APP_PASSWORD' } } + ``` + +1. Change 'YOUR_APP_NAME' to the application name from Crowd applications page. + +1. Change 'YOUR_APP_PASSWORD' to the application password you've set. + +1. Save the configuration file. + +1. Restart GitLab for the changes to take effect. + +On the sign in page there should now be a Crowd tab in the sign in form. \ No newline at end of file diff --git a/doc/integration/omniauth.md b/doc/integration/omniauth.md index 2010cb9b8a1..c5cecbc2f2d 100644 --- a/doc/integration/omniauth.md +++ b/doc/integration/omniauth.md @@ -76,6 +76,7 @@ Now we can choose one or more of the Supported Providers below to continue confi - [Shibboleth](shibboleth.md) - [Twitter](twitter.md) - [SAML](saml.md) +- [Crowd](crowd.md) ## Enable OmniAuth for an Existing User -- cgit v1.2.3 From 8ec59bd18bcacf13c012a34b3e37c2c9167bcc65 Mon Sep 17 00:00:00 2001 From: "Artem V. Navrotskiy" Date: Sat, 29 Aug 2015 12:52:21 +0300 Subject: Add API method for get user by ID of an SSH key --- doc/api/users.md | 45 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) (limited to 'doc') diff --git a/doc/api/users.md b/doc/api/users.md index 7ba2db248ff..eb6726b60d3 100644 --- a/doc/api/users.md +++ b/doc/api/users.md @@ -150,6 +150,51 @@ Parameters: } ``` +### Get SSH key with user by ID of an SSH key + +Get SSH key with user by ID of an SSH key. Note only administrators can lookup SSH key with user by ID of an SSH key. + +``` +GET /keys/:id +``` + +Parameters: + +- `id` (required) - The ID of an SSH key + +```json +{ + "id": 1, + "title": "Sample key 25", + "key": "ssh-rsa AAAAB3NzaC1yc2EAAAABJQAAAIEAiPWx6WM4lhHNedGfBpPJNPpZ7yKu+dnn1SJejgt1256k6YjzGGphH2TUxwKzxcKDKKezwkpfnxPkSMkuEspGRt/aZZ9wa++Oi7Qkr8prgHc4soW6NUlfDzpvZK2H5E7eQaSeP3SAwGmQKUFHCddNaP0L+hM7zhFNzjFvpaMgJw0=", + "created_at": "2015-09-03T07:24:44.627Z", + "user": { + "name": "John Smith", + "username": "john_smith", + "id": 25, + "state": "active", + "avatar_url": "http://www.gravatar.com/avatar/cfa35b8cd2ec278026357769582fa563?s=40\u0026d=identicon", + "web_url": "http://localhost:3000/u/john_smith", + "created_at": "2015-09-03T07:24:01.670Z", + "is_admin": false, + "bio": null, + "skype": "", + "linkedin": "", + "twitter": "", + "website_url": "", + "email": "john@example.com", + "theme_id": 2, + "color_scheme_id": 1, + "projects_limit": 10, + "current_sign_in_at": null, + "identities": [], + "can_create_group": true, + "can_create_project": true, + "two_factor_enabled": false + } +} +``` + ## User creation Creates a new user. Note only administrators can create new users. -- cgit v1.2.3 From 1be79e8e7cd20abaec7d2efcbbf7d7fe4e2a0760 Mon Sep 17 00:00:00 2001 From: "Artem V. Navrotskiy" Date: Thu, 3 Sep 2015 16:32:21 +0300 Subject: Move get user by ID of an SSH key documentation to separate file --- doc/api/README.md | 1 + doc/api/keys.md | 46 ++++++++++++++++++++++++++++++++++++++++++++++ doc/api/users.md | 45 --------------------------------------------- 3 files changed, 47 insertions(+), 45 deletions(-) create mode 100644 doc/api/keys.md (limited to 'doc') diff --git a/doc/api/README.md b/doc/api/README.md index f369c3fd978..6b8528de50c 100644 --- a/doc/api/README.md +++ b/doc/api/README.md @@ -21,6 +21,7 @@ - [Groups](groups.md) - [Namespaces](namespaces.md) - [Settings](settings.md) +- [Keys](keys.md) ## Clients diff --git a/doc/api/keys.md b/doc/api/keys.md new file mode 100644 index 00000000000..faa6f212b43 --- /dev/null +++ b/doc/api/keys.md @@ -0,0 +1,46 @@ +# Keys + +## Get SSH key with user by ID of an SSH key + +Get SSH key with user by ID of an SSH key. Note only administrators can lookup SSH key with user by ID of an SSH key. + +``` +GET /keys/:id +``` + +Parameters: + +- `id` (required) - The ID of an SSH key + +```json +{ + "id": 1, + "title": "Sample key 25", + "key": "ssh-rsa AAAAB3NzaC1yc2EAAAABJQAAAIEAiPWx6WM4lhHNedGfBpPJNPpZ7yKu+dnn1SJejgt1256k6YjzGGphH2TUxwKzxcKDKKezwkpfnxPkSMkuEspGRt/aZZ9wa++Oi7Qkr8prgHc4soW6NUlfDzpvZK2H5E7eQaSeP3SAwGmQKUFHCddNaP0L+hM7zhFNzjFvpaMgJw0=", + "created_at": "2015-09-03T07:24:44.627Z", + "user": { + "name": "John Smith", + "username": "john_smith", + "id": 25, + "state": "active", + "avatar_url": "http://www.gravatar.com/avatar/cfa35b8cd2ec278026357769582fa563?s=40\u0026d=identicon", + "web_url": "http://localhost:3000/u/john_smith", + "created_at": "2015-09-03T07:24:01.670Z", + "is_admin": false, + "bio": null, + "skype": "", + "linkedin": "", + "twitter": "", + "website_url": "", + "email": "john@example.com", + "theme_id": 2, + "color_scheme_id": 1, + "projects_limit": 10, + "current_sign_in_at": null, + "identities": [], + "can_create_group": true, + "can_create_project": true, + "two_factor_enabled": false + } +} +``` diff --git a/doc/api/users.md b/doc/api/users.md index eb6726b60d3..7ba2db248ff 100644 --- a/doc/api/users.md +++ b/doc/api/users.md @@ -150,51 +150,6 @@ Parameters: } ``` -### Get SSH key with user by ID of an SSH key - -Get SSH key with user by ID of an SSH key. Note only administrators can lookup SSH key with user by ID of an SSH key. - -``` -GET /keys/:id -``` - -Parameters: - -- `id` (required) - The ID of an SSH key - -```json -{ - "id": 1, - "title": "Sample key 25", - "key": "ssh-rsa AAAAB3NzaC1yc2EAAAABJQAAAIEAiPWx6WM4lhHNedGfBpPJNPpZ7yKu+dnn1SJejgt1256k6YjzGGphH2TUxwKzxcKDKKezwkpfnxPkSMkuEspGRt/aZZ9wa++Oi7Qkr8prgHc4soW6NUlfDzpvZK2H5E7eQaSeP3SAwGmQKUFHCddNaP0L+hM7zhFNzjFvpaMgJw0=", - "created_at": "2015-09-03T07:24:44.627Z", - "user": { - "name": "John Smith", - "username": "john_smith", - "id": 25, - "state": "active", - "avatar_url": "http://www.gravatar.com/avatar/cfa35b8cd2ec278026357769582fa563?s=40\u0026d=identicon", - "web_url": "http://localhost:3000/u/john_smith", - "created_at": "2015-09-03T07:24:01.670Z", - "is_admin": false, - "bio": null, - "skype": "", - "linkedin": "", - "twitter": "", - "website_url": "", - "email": "john@example.com", - "theme_id": 2, - "color_scheme_id": 1, - "projects_limit": 10, - "current_sign_in_at": null, - "identities": [], - "can_create_group": true, - "can_create_project": true, - "two_factor_enabled": false - } -} -``` - ## User creation Creates a new user. Note only administrators can create new users. -- cgit v1.2.3 From a73044320f806c660a21992fdbf63deb161c615e Mon Sep 17 00:00:00 2001 From: Stan Hu Date: Thu, 3 Sep 2015 20:49:13 +0000 Subject: Fix `rake services:doc` generation [ci skip] --- doc/development/rake_tasks.md | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'doc') diff --git a/doc/development/rake_tasks.md b/doc/development/rake_tasks.md index 53f8095cb13..a4a980cf0e0 100644 --- a/doc/development/rake_tasks.md +++ b/doc/development/rake_tasks.md @@ -27,3 +27,9 @@ You can find results under the `doc/code` directory. ``` bundle exec rake gitlab:generate_docs ``` + +## Generate API documentation for project services (e.g. Slack) + +``` +bundle exec rake services:doc +``` -- cgit v1.2.3 From 4d6f8a6aee345d12d81f03f8dc1dfdfc2e3bd777 Mon Sep 17 00:00:00 2001 From: Robert Speicher Date: Tue, 8 Sep 2015 13:31:54 -0400 Subject: Bump gitlab-shell to v2.6.5 --- doc/install/installation.md | 2 +- doc/update/6.x-or-7.x-to-7.14.md | 4 ++-- doc/update/7.13-to-7.14.md | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) (limited to 'doc') diff --git a/doc/install/installation.md b/doc/install/installation.md index 52031e9b9a1..ee13b0f2537 100644 --- a/doc/install/installation.md +++ b/doc/install/installation.md @@ -299,7 +299,7 @@ We recommend using a PostgreSQL database. For MySQL check [MySQL setup guide](da GitLab Shell is an SSH access and repository management software developed specially for GitLab. # Run the installation task for gitlab-shell (replace `REDIS_URL` if needed): - sudo -u git -H bundle exec rake gitlab:shell:install[v2.6.3] REDIS_URL=unix:/var/run/redis/redis.sock RAILS_ENV=production + sudo -u git -H bundle exec rake gitlab:shell:install[v2.6.5] REDIS_URL=unix:/var/run/redis/redis.sock RAILS_ENV=production # By default, the gitlab-shell config is generated from your main GitLab config. # You can review (and modify) the gitlab-shell config as follows: diff --git a/doc/update/6.x-or-7.x-to-7.14.md b/doc/update/6.x-or-7.x-to-7.14.md index a1488474f60..5bc1f84270a 100644 --- a/doc/update/6.x-or-7.x-to-7.14.md +++ b/doc/update/6.x-or-7.x-to-7.14.md @@ -127,7 +127,7 @@ sudo apt-get install nodejs ```bash cd /home/git/gitlab-shell sudo -u git -H git fetch -sudo -u git -H git checkout v2.6.4 +sudo -u git -H git checkout v2.6.5 ``` ## 7. Install libs, migrations, etc. @@ -167,7 +167,7 @@ git diff 6-0-stable:config/gitlab.yml.example 7.14-stable:config/gitlab.yml.exam * Make `/home/git/gitlab/config/gitlab.yml` the same as https://gitlab.com/gitlab-org/gitlab-ce/blob/7-14-stable/config/gitlab.yml.example but with your settings. * Make `/home/git/gitlab/config/unicorn.rb` the same as https://gitlab.com/gitlab-org/gitlab-ce/blob/7-14-stable/config/unicorn.rb.example but with your settings. -* Make `/home/git/gitlab-shell/config.yml` the same as https://gitlab.com/gitlab-org/gitlab-shell/blob/v2.6.0/config.yml.example but with your settings. +* Make `/home/git/gitlab-shell/config.yml` the same as https://gitlab.com/gitlab-org/gitlab-shell/blob/v2.6.5/config.yml.example but with your settings. * Copy rack attack middleware config ```bash diff --git a/doc/update/7.13-to-7.14.md b/doc/update/7.13-to-7.14.md index 7c2d3f4498a..6dd9727fb49 100644 --- a/doc/update/7.13-to-7.14.md +++ b/doc/update/7.13-to-7.14.md @@ -63,7 +63,7 @@ sudo -u git -H git checkout 7-14-stable-ee ```bash cd /home/git/gitlab-shell sudo -u git -H git fetch -sudo -u git -H git checkout v2.6.4 +sudo -u git -H git checkout v2.6.5 ``` ### 5. Install libs, migrations, etc. -- cgit v1.2.3 From e156f42079ebf8247b6a39fa6314d4d5c6b73d12 Mon Sep 17 00:00:00 2001 From: Jared Szechy Date: Tue, 4 Aug 2015 18:21:12 -0400 Subject: FogBugz project import --- doc/workflow/importing/README.md | 1 + .../fogbugz_importer/fogbugz_import_finished.png | Bin 0 -> 53276 bytes .../fogbugz_importer/fogbugz_import_login.png | Bin 0 -> 44444 bytes .../fogbugz_import_select_fogbogz.png | Bin 0 -> 35415 bytes .../fogbugz_import_select_project.png | Bin 0 -> 62552 bytes .../fogbugz_importer/fogbugz_import_user_map.png | Bin 0 -> 157856 bytes .../importing/import_projects_from_fogbugz.md | 29 +++++++++++++++++++++ 7 files changed, 30 insertions(+) create mode 100644 doc/workflow/importing/fogbugz_importer/fogbugz_import_finished.png create mode 100644 doc/workflow/importing/fogbugz_importer/fogbugz_import_login.png create mode 100644 doc/workflow/importing/fogbugz_importer/fogbugz_import_select_fogbogz.png create mode 100644 doc/workflow/importing/fogbugz_importer/fogbugz_import_select_project.png create mode 100644 doc/workflow/importing/fogbugz_importer/fogbugz_import_user_map.png create mode 100644 doc/workflow/importing/import_projects_from_fogbugz.md (limited to 'doc') diff --git a/doc/workflow/importing/README.md b/doc/workflow/importing/README.md index 5cde90993d2..7ccf06fbd60 100644 --- a/doc/workflow/importing/README.md +++ b/doc/workflow/importing/README.md @@ -3,6 +3,7 @@ 1. [Bitbucket](import_projects_from_bitbucket.md) 2. [GitHub](import_projects_from_github.md) 3. [GitLab.com](import_projects_from_gitlab_com.md) +4. [FogBugz](import_projects_from_fogbugz.md) 4. [SVN](migrating_from_svn.md) ### Note diff --git a/doc/workflow/importing/fogbugz_importer/fogbugz_import_finished.png b/doc/workflow/importing/fogbugz_importer/fogbugz_import_finished.png new file mode 100644 index 00000000000..205c515bd3f Binary files /dev/null and b/doc/workflow/importing/fogbugz_importer/fogbugz_import_finished.png differ diff --git a/doc/workflow/importing/fogbugz_importer/fogbugz_import_login.png b/doc/workflow/importing/fogbugz_importer/fogbugz_import_login.png new file mode 100644 index 00000000000..a1e348d46ad Binary files /dev/null and b/doc/workflow/importing/fogbugz_importer/fogbugz_import_login.png differ diff --git a/doc/workflow/importing/fogbugz_importer/fogbugz_import_select_fogbogz.png b/doc/workflow/importing/fogbugz_importer/fogbugz_import_select_fogbogz.png new file mode 100644 index 00000000000..ed362846909 Binary files /dev/null and b/doc/workflow/importing/fogbugz_importer/fogbugz_import_select_fogbogz.png differ diff --git a/doc/workflow/importing/fogbugz_importer/fogbugz_import_select_project.png b/doc/workflow/importing/fogbugz_importer/fogbugz_import_select_project.png new file mode 100644 index 00000000000..d2fbd0267bd Binary files /dev/null and b/doc/workflow/importing/fogbugz_importer/fogbugz_import_select_project.png differ diff --git a/doc/workflow/importing/fogbugz_importer/fogbugz_import_user_map.png b/doc/workflow/importing/fogbugz_importer/fogbugz_import_user_map.png new file mode 100644 index 00000000000..b1cc4b58525 Binary files /dev/null and b/doc/workflow/importing/fogbugz_importer/fogbugz_import_user_map.png differ diff --git a/doc/workflow/importing/import_projects_from_fogbugz.md b/doc/workflow/importing/import_projects_from_fogbugz.md new file mode 100644 index 00000000000..71af0f9ea44 --- /dev/null +++ b/doc/workflow/importing/import_projects_from_fogbugz.md @@ -0,0 +1,29 @@ +# Import your project from FogBugz to GitLab + +It only takes a few simple steps to import your project from FogBugz. +The importer will import all of your cases and comments with original case +numbers and timestamps. You will also have the opportunity to map FogBugz +users to GitLab users. + +* From your GitLab dashboard click 'New project' + +* Click on the 'FogBugz' button + +![FogBugz](fogbugz_importer/fogbugz_import_select_fogbogz.png) + +* Enter your FogBugz URL, email address, and password. + +![Login](fogbugz_importer/fogbugz_import_login.png) + +* Create mapping from FogBugz users to GitLab users. + +![User Map](fogbugz_importer/fogbugz_import_user_map.png) + +* Select the projects you wish to import by clicking the Import buttons + +![Import Project](fogbugz_importer/fogbugz_import_select_project.png) + +* Once the import has finished click the link to take you to the project +dashboard. Follow the directions to push your existing repository. + +![Finished](fogbugz_importer/fogbugz_import_finished.png) -- cgit v1.2.3