coding.net - ansible git 模块不拉代码?

 星空下的舞者j 发布于 2022-10-26 10:58

这个是我本地的log

commit dd43f262408f4d541b03b4163d3f0949f683dcc5
Author: yiwozhiming

Date: Fri Dec 23 11:12:31 2016 +0800

广告编辑添加server_platform_id

这个是我服务器的log:

commit 5124dc0b40bc75be7dd43e412c23fe32c7128911

Author: yiwozhiming
Date: Fri Dec 23 10:10:29 2016 +0800

广告编辑添加server_platform_id

可以看到服务器的log落后我本地的log
ansible:

---
- hosts: sp
  vars:
    ansible_ssh_pipelining: yes 
  
  tasks:
    - git:
        repo: git@git.coding.net:xxxx/GitName.git
        dest: /home/servername/GitName
         
        
        version: master
        update: yes
        key_file: /home/servername/.ssh/id_rsa
        
        

      notify:
        - restart GitName 
        - restart task-name
      
  handlers:
    - name: restart GitName
      supervisorctl: name=GitName state=restarted 
    - name: restart task-name
      supervisorctl: name=task-name state=restarted     

这个是git的log

changed: [sp] => {"after": "4086a3e3819b8c7df298f1333b060b97c3f35979", "before": "ba3f9d29c63ca96c2829de819d8fd4914160814d", "changed": true, "invocation": {"module_a
rgs": {"accept_hostkey": false, "bare": false, "clone": true, "depth": null, "dest": "/home/servername/GitNmae", "executable": null, "force": false, "key_file": "/hom
e/servername/.ssh/id_rsa", "recursive": true, "reference": null, "refspec": null, "remote": "origin", "repo": "git@git.coding.net:xxx/GitName.git", "ssh_opts": nu
ll, "track_submodules": false, "update": true, "verify_commit": false, "version": "master"}, "module_name": "git"}, "warnings": []}    

请问我是哪里错了?

撰写答案
今天,你开发时遇到什么问题呢?
立即提问
热门标签
PHP1.CN | 中国最专业的PHP中文社区 | PNG素材下载 | DevBox开发工具箱 | json解析格式化 |PHP资讯 | PHP教程 | 数据库技术 | 服务器技术 | 前端开发技术 | PHP框架 | 开发工具 | 在线工具
Copyright © 1998 - 2020 PHP1.CN. All Rights Reserved 京公网安备 11010802041100号 | 京ICP备19059560号-4 | PHP1.CN 第一PHP社区 版权所有