New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

codedeploy-scripts

Package Overview
Dependencies
Maintainers
1
Versions
10
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

codedeploy-scripts - npm Package Compare versions

Comparing version
0.0.9
to
1.0.0
+22
src/nodedeployment.js
"use strict";
class NodeDeployment extends require("./deployment") {
constructor(options) {
super(options);
var Node = require("./node");
this.node = new Node(this.appName, options.nodePort || 5000, options.serverScript || "server.js");
}
BeforeInstall() {
this.node.stop();
}
AfterInstall() {
this.writeSecretFile(this.appName + "/.env", ".env");
}
ApplicationStart() {
this.node.start();
}
}
module.exports = NodeDeployment;
+1
-1

@@ -5,3 +5,3 @@ {

"description": "AWS CodeDeploy lifecycle scripts using ES6 to deploy a node app to EC2",
"version": "0.0.9",
"version": "1.0.0",
"keywords": [

@@ -8,0 +8,0 @@ "AWS",

@@ -7,2 +7,4 @@ # CodeDeploy Scripts

See https://github.com/tqc/react-demo for a minimal working example.
## Usage

@@ -21,3 +23,3 @@

files:
+ source: /
- source: /
destination: /apps/appname

@@ -29,12 +31,12 @@ hooks:

BeforeInstall:
+ location: deployment.js
- location: deployment.js
timeout: 180
AfterInstall:
+ location: deployment.js
- location: deployment.js
timeout: 180
ApplicationStart:
+ location: deployment.js
- location: deployment.js
timeout: 180
ValidateService:
+ location: deployment.js
- location: deployment.js
timeout: 180

@@ -57,4 +59,10 @@

domains: "deploytest.example.com",
// files in these folders will be served from nginx without calling the node server
buildFolder: "build",
staticFolder: "static"
staticFolder: "static",
// files in s3 my-secret-bucket/deploytest will be copied to /apps/deploytest; suitable for ssh keys and
// config files which can't be part of the code deployment
secretBucket: "my-secret-bucket",
// if true, nginx will be set to serve https using /apps/deploytest/deploytest.[crt|key]
useSSL: false
});

@@ -70,4 +78,7 @@ deployment.run();

* The target is a standard Amazon Linux instance
* io.js is installed as /usr/local/bin/node
* node.js is installed
* The app will be installed to /apps/appname
* static files are in /apps/appname/static and /apps/appname/build
A userdata script that will sufficiently configure a standard Amazon Linux instance can be found at https://github.com/tqc/ec2scripts/blob/master/userdata-app.sh
Manual configuration is required for the security settings - the machine role will need the standard CodeDeploy access settings, plus access to the secrets bucket if used.

@@ -6,3 +6,4 @@

Deployment: require("./deployment"),
SimpleDeployment: require("./simpledeployment")
SimpleDeployment: require("./simpledeployment"),
NodeDeployment: require("./nodedeployment"),
};