@nginstack/build-tools
Auxiliary tools used for build JAZ packages on nginstack platform.
Last updated 22 days ago by dyad-tecnologia .
Original npm · Tarball · package.json
$ cnpm install @nginstack/build-tools 
SYNC missed versions from official npm registry.

Build Tools

Auxiliary tools used for build JAZ packages on nginstack platform.

Install

Prerequisites

Installation

  1. Install @nginstack/build-tools using npm (or yarn):

    yarn install @nginstack/build-tools
    

Configuration

Build tools scripts requires a configuration about the target database that will run the tests and receive the build artifacts. The configuration can be informed by environment variables or by a .env config file placed at repository root.

The build API and scripts will search custom jaz archives automatically at directory build/ and they will use directory .engine as Engine work directory. It´s recommended to ignore this directory in .gitignore to avoid to commit Engine large temporary files like logs and database local caches.

Configure defining the environment variables:

  • ENGINE_URL: engine server URL. Example: http://my_database.nginstack.com.
  • ENGINE_DATABASE: database name. Example: MY_DATABASE.
  • ENGINE_USERNAME: user name used to upload artifacts and run tests.
  • ENGINE_PASSWORD: user password used to upload artifacts and run tests.

Or use a .env file:

ENGINE_URL=http://my_database.nginstack.com
ENGINE_DATABASE=MY_DATABASE
ENGINE_USERNAME=username
ENGINE_PASSWORD=password

Build and utilities scripts

uploadToVfs

Upload one or more build artifacts to Engine Virtual File System.

Usage:

uploadToVfs PATH_1 FILE_KEY_1 PATH_2 FILE_KEY_2 ... PATH_N FILE_KEY_N

runTests

Run server testes on Engine and save the results to a file using the JUnit tests XML report file format. If the report path was not informed it will use "build/server-tests.xml".

Usage:

runTests.js TESTS_PATHS [OUT_REPORT_PATH] 

Experimental: inform the parameter -v8 to run tests using the V8 as default JavaScript runtime.

runTests.js TESTS_PATHS [OUT_REPORT_PATH] -v8

installJazDependencies

Read the array property jazDependencies of package.json and download the informed JAZ packages of the server informed by the environment variable SERVER_URL. The downloaded JAZ packages are extracted in node_modules.

Is recommended to use installJazDependencies as a postinstall script of package.json.

Usage:

installJazDependencies

packJaz

Build a JAZ file using a config file informed as argument. Config example:

{
  "dest": "build/my-package.jaz",
  "files": [
    "package.json", "lib/**", "routes/**", "controllers/**", "keys/**", "tests/**",
    "publicModules.js", "scripts/**", "startups/**"
  ],
  "ignore": [
      "lib/localConfig.js"
  ],
  "minifier": {
    "files": [
      "lib/**"
    ]
  },
  "e2c": [
    {
      "metadata": {
        "license": {
          "product": -1898148465
        }
      },
      "files": [
        "lib/testing/e2c/**"
      ]
    }
  ]  
}

Use the minifier option to minify and to obfuscate the files of the JAZ Package and the e2c option to encrypt files using the Engine E2C file format. Both features are experimental and not were officially released as supported product features.

Usage:

packJaz jaz.config.json

Current Tags

  • 36.0.1                                ...           beta (22 days ago)
  • 35.0.30                                ...           latest (22 days ago)

56 Versions

  • 36.0.1                                ...           22 days ago
  • 35.0.30                                ...           22 days ago
  • 35.0.23                                ...           24 days ago
  • 35.0.22                                ...           24 days ago
  • 35.0.16                                ...           a month ago
  • 35.0.1                                ...           2 months ago
  • 34.0.33                                ...           2 months ago
  • 34.0.7                                ...           2 months ago
  • 34.0.6                                ...           2 months ago
  • 34.0.5                                ...           2 months ago
  • 34.0.1                                ...           3 months ago
  • 33.0.38                                ...           3 months ago
  • 33.0.14                                ...           3 months ago
  • 33.0.1                                ...           4 months ago
  • 32.0.39                                ...           4 months ago
  • 32.0.1                                ...           5 months ago
  • 31.0.29                                ...           5 months ago
  • 31.0.5                                ...           6 months ago
  • 31.0.1                                ...           6 months ago
  • 30.0.55                                ...           6 months ago
  • 30.0.23                                ...           6 months ago
  • 30.0.1                                ...           7 months ago
  • 29.0.72                                ...           7 months ago
  • 29.0.68                                ...           7 months ago
  • 29.0.61                                ...           7 months ago
  • 29.0.55                                ...           7 months ago
  • 29.0.31                                ...           7 months ago
  • 29.0.1                                ...           8 months ago
  • 28.0.54                                ...           8 months ago
  • 28.0.51                                ...           8 months ago
  • 28.0.48                                ...           8 months ago
  • 28.0.34                                ...           8 months ago
  • 28.0.18                                ...           8 months ago
  • 28.0.1                                ...           9 months ago
  • 27.0.46                                ...           9 months ago
  • 27.0.26                                ...           9 months ago
  • 27.0.12                                ...           9 months ago
  • 26.0.36                                ...           10 months ago
  • 27.0.1                                ...           10 months ago
  • 26.0.5                                ...           a year ago
  • 26.0.4                                ...           a year ago
  • 26.0.3                                ...           a year ago
  • 26.0.1                                ...           a year ago
  • 25.0.42                                ...           a year ago
  • 25.0.17                                ...           a year ago
  • 25.0.15                                ...           a year ago
  • 25.0.11                                ...           a year ago
  • 25.0.9                                ...           a year ago
  • 24.0.60                                ...           a year ago
  • 25.0.1                                ...           a year ago
  • 24.0.55                                ...           a year ago
  • 24.0.17                                ...           a year ago
  • 24.0.1                                ...           a year ago
  • 23.0.50                                ...           a year ago
  • 23.0.15                                ...           a year ago
  • 23.0.3                                ...           a year ago
Downloads
Today 0
This Week 1
This Month 1
Last Day 1
Last Week 0
Last Month 65
Dependencies (14)
Dev Dependencies (0)
None
Dependents (0)
None

Copyright 2014 - 2017 © taobao.org |