venditan/appengine-deploy
Composer 安装命令:
composer require venditan/appengine-deploy
包简介
Environment and Deployment Manager for Google App Engine Applications
关键字:
README 文档
README
Environment and Deployment Manager for Google App Engine Applications.
Supports multiple modules and multiple deployment targets (i.e. deploy to multiple unique appid's).
Working towards this: http://12factor.net/config
Table of Contents
What is this? Is it different from appcfg.py?
This allows you to deploy the same code/application to multiple target environments (local, multiple different App Engine projects).
Critically, it also allows you to manage environment variables distinctly for each deployment target.
This tool uses appcfg.py to actually push the deployments out, but it builds a dynamic command, overriding the target application id and environment variables at deploy time.
Example deploy.json file
Deployment targets and environments are configured in deploy.json, usually in your project root.
Here's a quick example where we have different database credentials for alpha and live environments.
{
"targets": {
"alpha": {
"app_id": "myapp-alpha",
"version": "alpha++",
"require_label": false,
"environment": {
"APP_DB_USER": "root",
"APP_DB_NAME": "DatabaseName",
"APP_DB_SOCKET": "/cloudsql/myapp:instance"
}
},
"live": {
"app_id": "myapp",
"version": "2",
"require_label": true,
"environment": {
"APP_DB_USER": "root",
"APP_DB_NAME": "LiveDatabaseName",
"APP_DB_SOCKET": "/cloudsql/myapp:instance"
}
}
}
}
Local development environment
You can configure the environment variables for your local development server in your yaml files like this:
env_variables: APP_DB_USER: root APP_DB_NAME: localdb
Usage
Deployment targets configured in deploy.json are executed using the deploy command, which is made available the vendor/bin folder by Composer.
For example, from your project root:
Deploy the examples module to the alpha target environment
vendor/bin/deploy --run --module=examples --target=alpha
Create a template deploy.json file
vendor/bin/deploy --init
Show the planned appcfg.py command for a deployment, but do not run it
vendor/bin/deploy --test --module=default --target=live
List the configured deployment targets
vendor/bin/deploy --verbose targets
Default Module
You can use either app or default to deploy the default App Engine module (which is configured in your app.yaml file).
Targets
Each target is a different deployment, like "staging" and "production".
They must be uniquely named.
Versions
If you suffix your version name with ++ then we will auto-increment the version on each deployment.
In the example above, the first deployment gets alpha1 and the second alpha2 and so on.
In order to do this, we have to be able to detect what versions are already running. So, if you delete all your versions, we will start at 1 again.
Labels
You can supply a version label like this:
vendor/bin/deploy --run --module=examples --target=alpha --label=rel200
When the code is deployed, the label will be suffixed to the version number. So, for example if the version is "alpha3":
alpha3-rel200
If your configuration defines "require_label" as true, when you deploy to that target, you will be required to enter a label. This is particularly useful for production environments, for managing feature releases, etc.
Important Labels must match the following regex: [a-zA-Z0-9_]+ (one or more alphanumerics or underscores)
Code Separation, Redirects
You can "redirect" from your deploy.json file to another, usually intended for situations where your environment configurations are stored in another version control repository.
So, this might be your deploy file from your application folder:
{
"file":"../vendor/my-company/my-app-environment/deploy.json"
}
Installing this tool
In your composer.json require section:
{
"venditan/appengine-deploy": "1.1.*"
}
or with the command line
composer require venditan/appengine-deploy:1.1.*
venditan/appengine-deploy 适用场景与选型建议
venditan/appengine-deploy 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 6.73k 次下载、GitHub Stars 达 4, 最近一次更新时间为 2015 年 09 月 14 日, 在 PHP 生态内属于活跃度较高的组件。
它主要适用于以下技术方向: 「deploy」 「app engine」 「venditan」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。
我们在过去多个企业项目中使用过 venditan/appengine-deploy 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 venditan/appengine-deploy 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
与 venditan/appengine-deploy 相关的其它包
同方向 / 同关键字的高下载量 PHP Composer 包推荐,方便对比选型:
blueways deployer recipes
The Laragoon utility package
A SilverStripe module to optimise the Meta, crawling, indexing, and sharing of your website content (forked from Cyber-Duck/Silverstripe-SEO)
A Highly Opinionated Symfony3/4 Deployer Recipe
Make your bundle an application
A Processor for Markup written in PHP. Allows extraction of Markup into a data structure, orchestrated nested manipulation of said structure, and output as (optimized) Markup.
统计信息
- 总下载量: 6.73k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 4
- 点击次数: 16
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: Unknown
- 更新时间: 2015-09-14