在开发、登台和生产之间同步 Drupal 站点 [英] Syncing Drupal site between dev, staging and production

查看:36
本文介绍了在开发、登台和生产之间同步 Drupal 站点的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

通常在 Drupal (6.x) 站点启动后,人们开始注册并输入他们自己的内容.每当需要升级时,将生产数据库复制到 dev,然后在 dev 上完成开发,然后推送到暂存以供客户批准.

Often after a Drupal (6.x) site is launched, I have people starting to sign up and enter their own content. Whenever there is need for an upgrade, the database on production is copied to dev and then the development is done on dev, later get pushed to staging for client's approval.

当网站最终准备好上线时,就会出现问题.生产服务器具有最新的用户输入内容,开发和登台具有最新的功能.简单地在生产中覆盖数据库是行不通的.我通常做的是写下对开发所做的工作,然后按照步骤在生产中再次执行实现.随着系统变得越来越大,生产中的一个错误可能会导致业务损失.我无法关闭网站几个小时.我无法确定在给定时间有多少人在使用该网站,即使如此,也不可能等到网站上没有人再进行升级.

When the site is eventually ready to go live, there is a problem. Production server has the latest user inputted content, dev and staging have the latest functionality. Simply overwriting the database on production won't work. What I usually do is to write down what has been done to dev and than follow the steps to go though the implementations again on production. As the system grows bigger, one single mistake on production may cause lost of business. I can't shutdown the site for several hours. I can't tell how many people are using the site at a given time, even so it's impossible to wait for a time where nobody is on the site to make the upgrade.

有人有什么好主意吗?

提前致谢.

推荐答案

您需要研究两个概念:第一个是Exportables" 这通常是导出给定模块的所有配置的一种方式.第二个是Features"(名字很吓人,是的),这是一种将一组可导出对象分组到用于版本控制、更新、部署、回滚等的给定变更集.

There are two concepts you need to look into: The first is "Exportables" which is generally a way of exporting all the configuration of a given module. The second is "Features" (terribly named, yes) which is a way of grouping a set of Exportables into a given changeset for version control, updating, deployment, rollback, etc.

为了澄清起见,许多模块实现了他们自己的Exportables"方法,我在上面链接到的是 Exportables 模块.这是一个更广泛的策略 - http://www.sthlmconnection.se/tips-and-tweaks/exportable-configuration-your-drupal-module-ctools

For clarification, many modules implement their own "Exportables" methodology what I linked to above was the Exportables module. Here's a wider strategy for it - http://www.sthlmconnection.se/tips-and-tweaks/exportable-configuration-your-drupal-module-ctools

这篇关于在开发、登台和生产之间同步 Drupal 站点的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆