41st Micro Service CICD (3)-Jenkins + Gitlab + webhooks + publish-over-ssh (1)

Source: Internet
Author: User
Tags git client

First, the role

    • Using Webhooks to implement the GIT Client push code to Gitlab, Jenkins will immediately go to Gitlab and build the replacement code.

Second, step

1, install the plug-in

    • Ruby_runtime (Hook plugin depends on the plugin)
    • Gitlab Hook Plugin

2. Jenkins Global Configuration

System Management, System settings

Description: Make a two tick and build a branch

3. Jenkins project configuration

Project, "Configuration"

Note: Tick "poll SCM", but the time expression is empty.

4, Gitlab Webhook configuration

Attention:

    • The URL is http./jenkins-server/gitlab/notify_commit
    • Tick "Push Events"
    • SSL Not applicable

After that, click on the "Test" button below to test

Third, testing

After modifying the code,

    • git add--all
    • git commit-m "xxx"
    • Git push Origin Head:dev

View the compilation of Jenkins.

41st Micro Service CICD (3)-Jenkins + Gitlab + webhooks + publish-over-ssh (1)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.