简体   繁体   English

用于node.js和mongo的部署软件

[英]Deployment software for node.js & mongo

I have my production and development servers (developed in node.js) on AWS as different instant, and connect to different mongoDB server. 我的生产和开发服务器(在node.js中开发)在AWS上具有不同的即时性,并连接到不同的mongoDB服务器。 The code is in github repo. 该代码在github repo中。

So, I want to find out what is the easiest way to do deployment after changes are confirmed at Dev server. 因此,我想找出在开发服务器上确认更改后最简单的部署方法。

What I would like to do is once I confirmed Dev is good, then I just go to a deployment panel or page that I can press a button and then the Prod will get the latest code from git and get the latest copy of data from dev db, and copy to prod mongoDB. 我想做的是,一旦我确定Dev是好的,那么我就转到部署面板或页面,按一下按钮,然后Prod将从git获取最新代码,并从dev获取最新数据副本。 db,然后复制到prod mongoDB。 All data are static, no user data. 所有数据都是静态的,没有用户数据。

I have used Jenkins but never installed it. 我曾经使用过詹金斯,但从未安装过它。 and I feel that Jenkins will be too big for that simple task. 我觉得詹金斯(Jenkins)对于这个简单的任务来说太大了。 (or not?) (或不?)

Is there an easier solutions? 有没有更简单的解决方案? or it is better for me to just spend my time installing Jenkins? 还是花些时间安装Jenkins对我来说更好?

Oh. 哦。 I'm on Ubuntu. 我在Ubuntu上。 Is that a problem installing Jenkins onto it? 在其上安装Jenkins是否有问题?

We use CircleCi for our continuous integration. 我们使用CircleCi进行持续集成。 Circle makes it easy to do deployment workflows based on the branch that is pushed. Circle使您可以轻松地根据推送的分支来执行部署工作流。 Plug for CircleCi. CircleCi的插件。

We had a Jenkins server, please just quit using it because it was a hassle compared to a hosted service. 我们有一个Jenkins服务器,请停止使用它,因为与托管服务相比,它很麻烦。

We do a similar process for one of our tool sets. 我们对其中一个工具集执行类似的过程。 We use the master branch for development, and the release branch for production. 我们将master分支用于开发,将release分支用于生产。 The exception is a successful test run builds our release branch, not a human clicking a button. 一个例外是成功的测试运行会构建我们的release分支,而不是人工单击按钮。 Do something like the following: 执行以下操作:

  1. Develop your code in a master branch master分支中开发代码
  2. Changes to your master branch are pushed to your development machines master分支的更改将推送到您的开发机器
  3. You create a button that executes an action to merge into the release branch, and push back to origin: 您创建一个按钮,该按钮执行一个要合并到release分支中的动作,然后按回原点:

    git fetch origin/release && git rebase origin/master && git checkout release && git merge master && git push origin release

If someone makes the release branch unmergeable from master, your auto-merge button, which is good. 如果有人使发布分支与master不可合并,则使用自动合并按钮,这很好。 It will require some manual interaction then. 然后将需要一些手动交互。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM