更容易基于Docker部署到AWS。

fuku的Python项目详细描述


#福彩 [![pypi版本](https://badge.fury.io/py/fuku.svg)](https://badge.fury.io/py/fuku

fuku是一个帮助管理web应用程序基础设施的(年轻的)系统 使用AWS。它的目的是复制一些简单的英雄没有 成本。

##要求:

在安装fuku之前,请先安装以下要求:

  • Python 3.6
  • ssh
  • ssh-agent
  • gpg
  • psql
  • awscli

##安装

标准PIP安装:

`bash pip install fuku `

##新配置的快速启动

  1. Configure your AWS credentials as usual (aws configure).

  2. fuku profile ls to see available profiles.

    [optional] If you need multiple AWS profiles, create a new profile by editing the file ~/.aws/credentials and copying the default lines.

    fuku profile sl <profile> to select the active AWS profile for Fuku.

  3. fuku profile bucket <bucket> to set a workspace for Fuku.

  4. fuku region ls to see available regions.

    fuku region sl <region> to select a region.

  5. fuku cluster mk <name> to create a cluster.

<> >现有结构的快速启动

  1. Configure your AWS credentials as usual (aws configure).

  2. fuku profile ls to see available profiles.

    fuku profile sl <name> to select your profile.

  3. fuku profile bucket <bucket> to set a workspace for Fuku.

  4. fuku region ls to see available regions.

    fuku region sl <region> to select a region.

  5. fuku cluster ls to see available clusters.

    fuku cluster sl <cluster> to select a cluster.

    Enter password to access cluster key file.

  6. fuku app ls to see available apps.

    fuku app sl <app> to select an app.

  7. fuku pg ls to see available DBs.

    fuku pg sl <db> to select a DB.

    Enter password to access PGPASS file.

此时,您已经为特定的集群、应用程序和 和数据库。为了方便起见,最好缓存会话以便于检索:

fuku session sv <name>

fuku session ld <name>

##下载当前数据库

下载当前数据库:

fuku pg dump <dumpfile> <dump_path>

##上传数据库

用新内容覆盖数据库(注意):

fuku pg restore <filename>

##通过ssh连接到节点

要直接访问群集中的一个节点:

fuku node ssh <name>

##运行任意命令

运行命令:

fuku service run <task> <command>

从指定的任务附加到正在运行的容器,然后 运行提供的命令。

##日志记录

要控制打印的日志,请使用标志–log,它使用可用的日志级别(严重、警告、信息、调试)

fuku –log=DEBUG <command>

默认情况下,日志设置为警告。

##在子进程中运行fuku

默认行为是假设一个用户始终在一个应用程序和/或数据库实例上。

但是,如果需要在不同的应用程序和/或数据库实例上生成多个运行命令的进程, 您可以使用–app–db标志。

例如,我们可以并行运行:

fuku –app=first_app service wait bg; fuku –app=first_app service run bg “./manage.py migrate”;

fuku –app=second_app service wait bg; fuku –app=second_app service run bg “./manage.py migrate”;

欢迎加入QQ群-->: 979659372 Python中文网_新手群

推荐PyPI第三方库


热门话题
java无法启动应用程序:JNLP错误   java根据用户输入在PreparedStatement中使用setTime()或setNull()   java EJB与同步   java以object为键通过hashmap进行搜索   java中的模10^9+7   针对包含其他对象的对象的java OOP最佳实践   如何将字符串作为HTML代码从Java文件读取到JSP页面?   java我的POM怎么了?“解析表达式..检测到递归表达式循环”   用于Hbase的Mapreduce的java NoSuchMethodError   JAVAlang.SecurityException:权限拒绝:启动意图{act=安卓.Intent.action.MAIN cat=[安卓.Intent.category.LAUNCHER]   数组初始化谜语Java   通过arraylist搜索时的java句柄关联