发布生产代码的最佳方式
是否有发布 PHP 生产代码的最佳实践?
我知道使用 Java,您可以将源代码作为 WAR 或 JAR 发布,但是 PHP 有类似的东西吗?
随着我们的组织不断发展,我想找到一种更好的方式来发布生产代码,而不是使用当前的流程,这是不可接受的。
当前流程:
- 将新代码签入 SVN (Subversion) 备份
- 当前生产脚本并附加 .bak.date_time_stamp
- 将新脚本移至生产(FTP、SSH、SFTP)
需要能够
- 恢复更改
- 可选容器(例如 JAR)
- 存档当前的生产代码
- 是否自动化?这是一个愿望清单选项
还有其他建议/选项/实践可以很好地纳入吗?考虑改变组织流程。
Is there a best practice for releasing production code for PHP?
I know with Java you can release the source code as a WAR or JAR but does PHP have something like this?
As our org grows I wanted to find a better way of releasing production code instead of the current process with is not acceptable.
Current Process:
- Check New Code into SVN (Subversion)
- Make backup of current production script and append it with .bak.date_time_stamp
- Move new script into production (FTP, SSH, SFTP)
Need the ability to
- revert changes
- optional container (think JAR)
- archive current production code
- automate? this is a wish list option
Any other suggestions/options/practices that would be good to incorporate? Looking at changing the org process.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
War 或 Jar 的粗略等效项是 Phar。 Cal Evans 的教程位于
不会讨论其他部署策略,因为这些策略之前已经讨论过:
The rough equivalent to War or Jar would be Phar. There is a tutorial by Cal Evans at
Won't go into other Deployment strategies, because those have been discussed before:
看看 phar 作为 jar/war 的 PHP 替代品;以及用于构建/部署版本的 phing 等工具(它是 ant 的 PHP 变体)
Take a look at phar as a PHP alternative to jar/war; and at tools like phing for building/deploying releases (it's a PHP variant of ant)