@ossy/deployment-tools 0.0.1 → 0.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -28735,9 +28735,6 @@ class ContainerManagerServer {
28735
28735
 
28736
28736
 
28737
28737
 
28738
- const username = 'oskarssylwan'
28739
- const authentication = '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'
28740
-
28741
28738
  class ContainerManagerCommands {
28742
28739
 
28743
28740
  static deploy(
@@ -28797,7 +28794,10 @@ class ContainerManagerCommands {
28797
28794
  }
28798
28795
  }
28799
28796
 
28797
+ //eslint-disable-next-line max-params
28800
28798
  deploy(
28799
+ username,
28800
+ authentication,
28801
28801
  targetEnvironment = 'local-dev',
28802
28802
  pathToDeploymentPlatforms,
28803
28803
  pathToOssyFile
@@ -28877,7 +28877,7 @@ After=network.target
28877
28877
  Environment=DEPLOYMENT_TOOLS_PORT=3000
28878
28878
  User=root
28879
28879
  WorkingDirectory=/%h/deployment-tools
28880
- ExecStart=/usr/bin/node /%h/deployment-tools/index.js start-container-manager
28880
+ ExecStart=npx @ossy/deployment-tools start-container-manager
28881
28881
  Restart=on-failure
28882
28882
 
28883
28883
  [Install]
@@ -28908,6 +28908,12 @@ const deployHandler = () => {
28908
28908
  console.log('Running deploy command')
28909
28909
 
28910
28910
  const args = arg({
28911
+ '--username': String,
28912
+ '-u': '--username',
28913
+
28914
+ '--authentication': String,
28915
+ '--p': '--authentication',
28916
+
28911
28917
  '--target-env': String,
28912
28918
  '-t': '--target-env',
28913
28919
 
@@ -28921,6 +28927,8 @@ const deployHandler = () => {
28921
28927
  console.log('args', args)
28922
28928
 
28923
28929
  ContainerManagerCommands.deploy(
28930
+ args['--username'],
28931
+ args['--authentication'],
28924
28932
  args['--target-env'],
28925
28933
  args['--platforms'],
28926
28934
  args['--ossyfile']
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ossy/deployment-tools",
3
- "version": "0.0.1",
3
+ "version": "0.0.2",
4
4
  "description": "Collection of scripts and tools to aid deployment of containers and static files",
5
5
  "main": "dist/index.js",
6
6
  "type": "module",
@@ -2,9 +2,6 @@ import { resolve } from 'path'
2
2
  import { readFileSync } from 'fs'
3
3
  import fetch from 'node-fetch'
4
4
 
5
- const username = 'oskarssylwan'
6
- const authentication = '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'
7
-
8
5
  export class ContainerManagerCommands {
9
6
 
10
7
  static deploy(
@@ -64,7 +61,10 @@ export class ContainerManagerCommands {
64
61
  }
65
62
  }
66
63
 
64
+ //eslint-disable-next-line max-params
67
65
  deploy(
66
+ username,
67
+ authentication,
68
68
  targetEnvironment = 'local-dev',
69
69
  pathToDeploymentPlatforms,
70
70
  pathToOssyFile
package/src/index.js CHANGED
@@ -29,7 +29,7 @@ After=network.target
29
29
  Environment=DEPLOYMENT_TOOLS_PORT=3000
30
30
  User=root
31
31
  WorkingDirectory=/%h/deployment-tools
32
- ExecStart=/usr/bin/node /%h/deployment-tools/index.js start-container-manager
32
+ ExecStart=npx @ossy/deployment-tools start-container-manager
33
33
  Restart=on-failure
34
34
 
35
35
  [Install]
@@ -60,6 +60,12 @@ const deployHandler = () => {
60
60
  console.log('Running deploy command')
61
61
 
62
62
  const args = arg({
63
+ '--username': String,
64
+ '-u': '--username',
65
+
66
+ '--authentication': String,
67
+ '--p': '--authentication',
68
+
63
69
  '--target-env': String,
64
70
  '-t': '--target-env',
65
71
 
@@ -73,6 +79,8 @@ const deployHandler = () => {
73
79
  console.log('args', args)
74
80
 
75
81
  ContainerManagerCommands.deploy(
82
+ args['--username'],
83
+ args['--authentication'],
76
84
  args['--target-env'],
77
85
  args['--platforms'],
78
86
  args['--ossyfile']