从弹性beanstalk部署中排除目录 [英] Exclude directories from elastic beanstalk deploy

查看:135
本文介绍了从弹性beanstalk部署中排除目录的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一些我想要在我的本地git仓库中的目录,但是当我部署到我的beanstalk环境时,不在远程仓库中。

我有搜索了一下,发现了几年前的帖子:

http://blog.beanstalkapp.com/post/38164899272/patterns-for-excluded-deployment-paths



解释说在某个地方有这个选项,但是我到处寻找并找不到它。我认为它仍然在那里,可能它已经移动了?



如果这有帮助(尽管它可能没有任何区别),我有一个环境基于示例node.js应用程序。这个选项在哪里?



是否可以在.ebextensions文件夹中的配置文件中完成它?

eb cli v3.x 弹性beanstalk支持 .ebignore 文件。它遵循与 .gitignore 文件相同的格式,并在部署时取代它。



如果您想要使用 .ebignore 然后您需要将您的 .gitignore 复制到文件中,然后将额外的排除项添加到文件中。如果将来编辑 .gitignore 文件,则需要将任何更改复制到 .ebignore 文件中。



请参阅弹性豆荚文档了解更多详情


I have some directories that I would like to be in my local git repository, but NOT in the remote repository when I deploy to my beanstalk environment.

I have googled a bit, and found a few years old posts like this:

http://blog.beanstalkapp.com/post/38164899272/patterns-for-excluded-deployment-paths

that explain that there is this option somewhere, but I have looked everywhere and cannot find it. I think it must still be there and possibly it's been moved around?

If that helps (though it probably doesn't make any difference), I've got an environment based on the sample node.js application. Where is this option?

Is it possible to do it in a config file in the .ebextensions folder instead?

解决方案

With the current eb cli v3.x elastic beanstalk supports the .ebignore file. It follows the same format as a .gitignore file and it replaces it on deploy.

If you want to use .ebignore then you need to copy your .gitignore into the file and then add the extra exclusions to the file. If you edit your .gitignore file in the future you will need to replicate any changes into you .ebignore file.

See elastic beanstalk docs for more details

这篇关于从弹性beanstalk部署中排除目录的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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