Created
February 12, 2019 09:48
-
-
Save l0rd/d86a6c32931d7c0713f23259a07d9003 to your computer and use it in GitHub Desktop.
express-mongo workspace
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"defaultEnv": "default", | |
"environments": { | |
"default": { | |
"machines": { | |
"demo/nodejs": { | |
"attributes": { | |
"memoryLimitBytes": "536870912" | |
}, | |
"servers": { | |
"node": { | |
"port": "3000", | |
"protocol": "http", | |
"path": "/", | |
"attributes": {} | |
} | |
}, | |
"volumes": { | |
"projects": { | |
"path": "/projects" | |
} | |
}, | |
"installers": [], | |
"env": {} | |
}, | |
"demo/mongo": { | |
"attributes": { | |
"memoryLimitBytes": "322122547" | |
}, | |
"servers": {}, | |
"volumes": {}, | |
"installers": [], | |
"env": {} | |
} | |
}, | |
"recipe": { | |
"type": "kubernetes", | |
"content": "apiVersion: v1\nkind: List\nitems:\n- apiVersion: v1\n kind: Service\n metadata:\n labels:\n name: mongo\n name: mongo\n spec:\n ports:\n - port: 27017\n targetPort: 27017\n selector:\n name: demo\n- apiVersion: apps/v1\n kind: Deployment\n metadata:\n labels:\n name: demo\n name: controllers\n spec:\n replicas: 1\n selector:\n matchLabels:\n name: demo\n template:\n metadata:\n labels:\n name: demo\n name: demo\n spec:\n containers:\n - image: mongo\n name: mongo\n ports:\n - name: mongo\n containerPort: 27017\n hostPort: 27017\n - image: node:0.10.40\n command: ['/bin/sh', '-c']\n args: ['tail -f /dev/null']\n name: nodejs\n ports:\n - containerPort: 3000\n name: http-server\n- apiVersion: v1\n kind: Service\n metadata:\n name: web\n labels:\n name: web\n spec:\n ports:\n - port: 3000\n targetPort: 3000\n protocol: TCP\n selector:\n name: demo\n- apiVersion: extensions/v1beta1\n kind: Ingress\n metadata:\n name: nodejs-ingress\n annotations:\n kubernetes.io/ingress.class: \"nginx\"\n nginx.ingress.kubernetes.io/proxy-read-timeout: \"3600\"\n nginx.ingress.kubernetes.io/proxy-connect-timeout: \"3600\"\n nginx.ingress.kubernetes.io/ssl-redirect: \"false\"\n spec:\n rules:\n - host: 192.168.99.100.nip.io\n http:\n paths:\n - path: /\n backend:\n serviceName: web\n servicePort: 3000", | |
"contentType": "application/x-yaml" | |
} | |
} | |
}, | |
"projects": [ | |
{ | |
"displayName": "NodeJS-Sample-App", | |
"description": "", | |
"source": { | |
"location": "https://github.com/l0rd/NodeJS-Sample-App.git", | |
"type": "git", | |
"parameters": {} | |
}, | |
"options": {}, | |
"mixins": [], | |
"problems": [], | |
"projects": [], | |
"commands": [], | |
"tags": [ | |
"blank" | |
], | |
"links": [], | |
"category": "", | |
"name": "demo", | |
"path": "/demo", | |
"attributes": {} | |
} | |
], | |
"name": "nodejs-mongo", | |
"attributes": { | |
"editor": "org.eclipse.che.editor.theia:1.0.0", | |
"sidecar.theia-ide.memory_limit": "1500Mi", | |
"plugins": "che-machine-exec-plugin:0.0.1" | |
}, | |
"commands": [ | |
{ | |
"commandLine": "cd /projects/demo/EmployeeDB && npm install", | |
"name": "Build demo", | |
"attributes": { | |
"machineName": "demo/nodejs", | |
"goal": "Build" | |
}, | |
"type": "Build" | |
}, | |
{ | |
"commandLine": "cd /projects/demo/EmployeeDB && npm install && node app.js", | |
"name": "Run demo", | |
"attributes": { | |
"machineName": "demo/nodejs", | |
"goal": "Run", | |
"previewUrl": "${server.node}" | |
}, | |
"type": "Run" | |
}, | |
{ | |
"commandLine": "cd /projects/demo/EmployeeDB && npm install && node --inspect app.js", | |
"name": "Run demo (debug mode)", | |
"attributes": { | |
"machineName": "demo/nodejs", | |
"goal": "Run", | |
"previewUrl": "${server.node}" | |
}, | |
"type": "Run" | |
}, | |
{ | |
"commandLine": "kill $(pgrep node | head -n 1)", | |
"name": "Stop", | |
"type": "che", | |
"attributes": { | |
"machineName": "demo/nodejs" | |
} | |
} | |
], | |
"links": [] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment