dp610807 2013-08-16 07:48
浏览 71

too long

This is the first time I've tried to use the GitHub service hooks to automatically deploy to my server; and after slowly working my way over every obstacle it looks like the very last one is the one that has done me in.

The initial clone of my git repository onto my web server was done through SSH, and I'm pretty sure that has something to do with my problems now. My current script is the basic:

<?php 
    echo(shell_exec('git pull 2>&1')); 
?>

But it returns "Permission denied (publickey). fatal: The remote end hung up unexpectedly"; which I know is where the script is failing to put in the SSH pass phrase I created. I tried doing research on how to maybe get past it, but I don't even know if those would be the correct/securest things to do.

So can this be modified to work from here or do I need to backtrack a few steps and step away from using SSH to begin with?

Thanks

  • 写回答

2条回答 默认 最新

  • dongyupen6269 2013-08-16 09:34
    关注

    Can you try to replace (in your git.config file )

    ssh://github.com/<username>/<project>.git 
    

    or

    https://github.com/<username>/<project>.git
    

    with

    git@github.com:<username>/<project>
    
    评论

报告相同问题?

悬赏问题

  • ¥15 用土力学知识进行土坡稳定性分析与挡土墙设计
  • ¥15 帮我写一个c++工程
  • ¥30 Eclipse官网打不开,官网首页进不去,显示无法访问此页面,求解决方法
  • ¥15 关于smbclient 库的使用
  • ¥15 微信小程序协议怎么写
  • ¥15 c语言怎么用printf(“\b \b”)与getch()实现黑框里写入与删除?
  • ¥20 怎么用dlib库的算法识别小麦病虫害
  • ¥15 华为ensp模拟器中S5700交换机在配置过程中老是反复重启
  • ¥15 uniapp uview http 如何实现统一的请求异常信息提示?
  • ¥15 有了解d3和topogram.js库的吗?有偿请教