0.3.0 • Published 6 years ago

@metaparticle/package v0.3.0

Weekly downloads
-
License
MIT
Repository
github
Last release
6 years ago

Metaparticle/Package for JavaScript

Metaparticle/Package is a collection of libraries intended to make building and deploying containers a seamless and idiomatic experience for developers.

This is the implementation for JavaScript (NodeJS).

Introduction

Metaparticle/Package simplifies and centralizes the task of building and deploying a container image.

Here is a quick example.

Consider this simple Javascript application:

console.log('hello world!');

To containerize this application, you need to use the @metaparticle/package library and the containerize wrapper function like this:

const mp = require('@metaparticle/package');

mp.containerize(
	{
		repository: 'brendanburns',
	},
	() => {
        console.log('hello world');
	}
);

You can then compile this application just as you have before. But now, when you run the application, instead of printing "Hello world", it first packages itself as a container, and then (optionally) deploys itself inside that container.

Tutorial

For a more complete exploration of the Metaparticle/Package for javascript, please see the in-depth tutorial.

Use ACI

const mp = require('@metaparticle/package');

mp.containerize(
    {
		repository: 'myrepo',
		publish: 'true',
		runner: 'aci',
		resourceGroup: 'myResourceGroup',
		subscriptionId: '00000000-0000-0000-0000-000000000000',
		public: 'true',
		ports: [80],
		clientId: '00000000-0000-0000-0000-000000000000',
		clientSecret: 'mykey',
		tenantId: '00000000-0000-0000-0000-000000000000'
    },
    () => {
        console.log('hello world');
    }
);
0.3.0

6 years ago

0.2.0

6 years ago

0.1.0

6 years ago

0.0.2

6 years ago

0.0.1

7 years ago