Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Jérome Perrin
gitlab-ce
Commits
20a6183b
Commit
20a6183b
authored
Dec 12, 2016
by
Sean McGivern
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update custom hooks docs and set 4.1.0
parent
3f768f9a
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
17 additions
and
9 deletions
+17
-9
GITLAB_SHELL_VERSION
GITLAB_SHELL_VERSION
+1
-1
doc/administration/custom_hooks.md
doc/administration/custom_hooks.md
+15
-7
doc/update/8.14-to-8.15.md
doc/update/8.14-to-8.15.md
+1
-1
No files found.
GITLAB_SHELL_VERSION
View file @
20a6183b
4.
0.3
4.
1.0
doc/administration/custom_hooks.md
View file @
20a6183b
...
@@ -44,22 +44,30 @@ as appropriate.
...
@@ -44,22 +44,30 @@ as appropriate.
## Chained hooks support
## Chained hooks support
> [Introduced][93] in GitLab Shell 4.1.0.
> [Introduced][93] in GitLab Shell 4.1.0
and GitLab 8.15
.
The hooks could be also placed in
`hooks/<hook_name>.d`
(global) or
`custom_hooks/<hook_name>.d`
(per project)
Hooks can be also placed in
`hooks/<hook_name>.d`
(global) or
directories supporting chained execution of the hooks.
`custom_hooks/<hook_name>.d`
(per project) directories supporting chained
execution of the hooks.
To look in a different directory for the global custom hooks (those in
`hooks/<hook_name.d>`
), set
`custom_hooks_dir`
in gitlab-shell config. For
Omnibus installations, this can be set in
`gitlab.rb`
; and in source
installations, this can be set in
`gitlab-shell/config.yml`
.
The hooks are searched and executed in this order:
The hooks are searched and executed in this order:
1.
`<project>.git/hooks/`
- symlink to
`gitlab-shell/hooks`
global dir
1.
`<project>.git/hooks/`
- symlink to
`gitlab-shell/hooks`
global dir
1.
`<project>.git/hooks/<hook_name>`
- executed by
`git`
itself, this is
`gitlab-shell/hooks/<hook_name>`
1.
`<project>.git/hooks/<hook_name>`
- executed by
`git`
itself, this is
`gitlab-shell/hooks/<hook_name>`
1.
`<project>.git/custom_hooks/<hook_name>`
- per project hook (this is already existing behavior)
1.
`<project>.git/custom_hooks/<hook_name>`
- per project hook (this is already existing behavior)
1.
`<project>.git/custom_hooks/<hook_name>.d/*`
- per project hooks
1.
`<project>.git/custom_hooks/<hook_name>.d/*`
- per project hooks
1.
`<project>.git/hooks/<hook_name>.d/*`
- global hooks: all executable files (minus editor backup files)
1.
`<project>.git/hooks/<hook_name>.d/*`
OR
`<custom_hooks_dir>/<hook_name.d>/*`
- global hooks: all executable files (minus editor backup files)
Files in
`.d`
directories need to be executable and not match the backup file pattern (
`*~`
).
Files in
`.d`
directories need to be executable and not match the backup file
pattern (
`*~`
).
The hooks of the same type are executed in order and execution stops on the
first
The hooks of the same type are executed in order and execution stops on the
script exiting with
non-zero value.
first script exiting with a
non-zero value.
## Custom error messages
## Custom error messages
...
...
doc/update/8.14-to-8.15.md
View file @
20a6183b
...
@@ -72,7 +72,7 @@ sudo -u git -H git checkout 8-15-stable-ee
...
@@ -72,7 +72,7 @@ sudo -u git -H git checkout 8-15-stable-ee
```
bash
```
bash
cd
/home/git/gitlab-shell
cd
/home/git/gitlab-shell
sudo
-u
git
-H
git fetch
--all
--tags
sudo
-u
git
-H
git fetch
--all
--tags
sudo
-u
git
-H
git checkout v4.
0.3
sudo
-u
git
-H
git checkout v4.
1.0
```
```
### 6. Update gitlab-workhorse
### 6. Update gitlab-workhorse
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment