dockerfile-builder

0.1.5 • Public • Published

Dockerfile-Builder

DockerfileBuilder 是一款用于配合 jenkins 处理 docker 镜像构建的工具。根据 Dockerfile.json 配置的 apk软件,npm 模块,以及自编写的 shell 脚本构建出 node 应用所需要的 Dockerfile 文件。

Install

$ npm install -g dockerfile-builder

USAGE

$ dockerfile-builder
 
// 命令会查找当前目录是否存在 Dockerfile.json,如果存在,则通过 Dockerfile.json 的配置内容,生成 Dockerfile

CONFIG

Dockerfile.json

{
  "alpine": "docker.io/node:8.7.0",
  "apk": [
    "curl"
  ],
  "npm": [
    "typescript@2.5.2"
  ],
  "shell": {
    "store": "/data1/dockerfile-builder/shell-store",
    "packages": [
      "shell2@1.0.0"
    ]
  },
  "dockerfile": [
    "EXPOSE 22",
    "CMD [ \"/usr/sbin/sshd\"\"-D\" ]"
  ]
}

Readme

Keywords

none

Package Sidebar

Install

npm i dockerfile-builder

Weekly Downloads

1

Version

0.1.5

License

MIT

Last publish

Collaborators

  • niklaus0823