Gitlab+jenkins自动构建

  1. jenkins安装插件
    • Gitlab Hook Plugin
    • GitLab Plugin
  2. jenkins系统设置
    • Enable authentication for ‘/project’ end-point 去掉勾子,否则gitlab触发webhook自动构建,会出现调用jenkins没有权限的问题
    <html>
    <head>
    <meta http-equiv="Content-Type" content="text/html;charset=utf-8"/>
    <title>Error 403 anonymous is missing the Job/Build permission</title>
    </head>
    <body><h2>HTTP ERROR 403</h2>
    <p>Problem accessing /project/robot_test. Reason:
    <pre>    anonymous is missing the Job/Build permission</pre></p><hr><a href="http://eclipse.org/jetty">Powered by Jetty:// 9.4.z-SNAPSHOT</a><hr/>
    
    </body>
    </html>
    
  3. jenkins设置项目push自动编译
    • Build Triggers > Build when a change is pushed to GitLab
  4. Gitlab设置webhook
    • settings > Integrations,URL填jenkins项目里GitLab webhook URL后面的地址

UniFi Controller AC控制器安装SSL证书

腾讯云

  1. qcloud.com申请免费SSL证书.
  2. 修改文件名
    1_root_bundle.crt >> unifi.chain.crt
    2_xxx.crt >> unifi.crt
    3_xxx.key >> unifi.key
  3. 上传证书文件至 /var/lib/unifi

  4. cd /var/lib/unifi

  5. openssl pkcs12 -export -in unifi.crt -inkey unifi.key -certfile unifi.chain.crt -out unifi.p12 -name unifi -password pass:aircontrolenterprise

  6. keytool -importkeystore -srckeystore unifi.p12 -srcstoretype PKCS12 -srcstorepass aircontrolenterprise -destkeystore /usr/lib/unifi/data/keystore -storepass aircontrolenterprise

  7. 重启unifi>> service unifi restart

阿里云

继续阅读UniFi Controller AC控制器安装SSL证书

jenkins完成robotframework任务发送钉钉消息

前提条件

1、申请钉钉测试企业帐号:http://open-dev.dingtalk.com/

  • 获取企业id:corpid
  • 获取企业密钥:corpsecret

2、将个人需要接受钉钉消息的帐号加入该测试企业,https://oa.dingtalk.com

钉钉API

1、获取access_token
通过corpid、corpsecret,获取access_token
https://open-doc.dingtalk.com/docs/doc.htm?spm=a219a.7629140.0.0.yx7wdO&treeId=172&articleId=104980&docType=1
继续阅读jenkins完成robotframework任务发送钉钉消息