BigW Consortium Gitlab

web_hooks.md 1.54 KB
Newer Older
ashleys committed
1
# Webhooks
2

ashleys committed
3
## Add a webhook for **ALL** projects:
4

5 6
    # omnibus-gitlab
    sudo gitlab-rake gitlab:web_hook:add URL="http://example.com/hook"
7
    # source installations
8
    bundle exec rake gitlab:web_hook:add URL="http://example.com/hook" RAILS_ENV=production
9

ashleys committed
10
## Add a webhook for projects in a given **NAMESPACE**:
11

12 13
    # omnibus-gitlab
    sudo gitlab-rake gitlab:web_hook:add URL="http://example.com/hook" NAMESPACE=acme
14
    # source installations
15
    bundle exec rake gitlab:web_hook:add URL="http://example.com/hook" NAMESPACE=acme RAILS_ENV=production
16

ashleys committed
17
## Remove a webhook from **ALL** projects using:
18

19 20
    # omnibus-gitlab
    sudo gitlab-rake gitlab:web_hook:rm URL="http://example.com/hook"
21
    # source installations
22
    bundle exec rake gitlab:web_hook:rm URL="http://example.com/hook" RAILS_ENV=production
23

ashleys committed
24
## Remove a webhook from projects in a given **NAMESPACE**:
25

26 27
    # omnibus-gitlab
    sudo gitlab-rake gitlab:web_hook:rm URL="http://example.com/hook" NAMESPACE=acme
28
    # source installations
29
    bundle exec rake gitlab:web_hook:rm URL="http://example.com/hook" NAMESPACE=acme RAILS_ENV=production
30

ashleys committed
31
## List **ALL** webhooks:
32

33 34
    # omnibus-gitlab
    sudo gitlab-rake gitlab:web_hook:list
35
    # source installations
36
    bundle exec rake gitlab:web_hook:list RAILS_ENV=production
37

ashleys committed
38
## List the webhooks from projects in a given **NAMESPACE**:
39

40 41
    # omnibus-gitlab
    sudo gitlab-rake gitlab:web_hook:list NAMESPACE=/
42
    # source installations
43
    bundle exec rake gitlab:web_hook:list NAMESPACE=/ RAILS_ENV=production
44 45

> Note: `/` is the global namespace.