Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
K
k3s
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jacklull
k3s
Commits
d27a1044
Commit
d27a1044
authored
Aug 19, 2015
by
Sandeep Dinesh
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added Node.js / MongoDB example
parent
8a43bd62
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
103 additions
and
0 deletions
+103
-0
README.md
examples/nodesjs-mongodb/README.md
+0
-0
mongo-controller.yaml
examples/nodesjs-mongodb/mongo-controller.yaml
+29
-0
mongo-service.yaml
examples/nodesjs-mongodb/mongo-service.yaml
+13
-0
web-controller-demo.yaml
examples/nodesjs-mongodb/web-controller-demo.yaml
+24
-0
web-controller.yaml
examples/nodesjs-mongodb/web-controller.yaml
+22
-0
web-service.yaml
examples/nodesjs-mongodb/web-service.yaml
+15
-0
No files found.
examples/nodesjs-mongodb/README.md
0 → 100644
View file @
d27a1044
This diff is collapsed.
Click to expand it.
examples/nodesjs-mongodb/mongo-controller.yaml
0 → 100644
View file @
d27a1044
apiVersion
:
v1
kind
:
ReplicationController
metadata
:
labels
:
name
:
mongo
name
:
mongo-controller
spec
:
replicas
:
1
template
:
metadata
:
labels
:
name
:
mongo
spec
:
containers
:
-
image
:
mongo
name
:
mongo
ports
:
-
name
:
mongo
containerPort
:
27017
hostPort
:
27017
volumeMounts
:
-
name
:
mongo-persistent-storage
mountPath
:
/data/db
volumes
:
-
name
:
mongo-persistent-storage
gcePersistentDisk
:
pdName
:
mongo-disk
fsType
:
ext4
\ No newline at end of file
examples/nodesjs-mongodb/mongo-service.yaml
0 → 100644
View file @
d27a1044
apiVersion
:
v1
kind
:
Service
metadata
:
labels
:
name
:
mongo
name
:
mongo
spec
:
ports
:
-
port
:
27017
targetPort
:
27017
selector
:
name
:
mongo
\ No newline at end of file
examples/nodesjs-mongodb/web-controller-demo.yaml
0 → 100644
View file @
d27a1044
apiVersion
:
v1
kind
:
ReplicationController
metadata
:
labels
:
name
:
web
name
:
web-controller
spec
:
replicas
:
2
selector
:
name
:
web
template
:
metadata
:
labels
:
name
:
web
spec
:
containers
:
-
image
:
node:0.10.40
command
:
[
'
/bin/sh'
,
'
-c'
]
args
:
[
'
cd
/home
&&
git
clone
https://github.com/ijason/NodeJS-Sample-App.git
demo
&&
cd
demo/EmployeeDB/
&&
npm
install
&&
sed
-i
--
'
'
s/localhost/mongo/g'
'
app.js
&&
node
app.js'
]
name
:
web
ports
:
-
containerPort
:
3000
name
:
http-server
\ No newline at end of file
examples/nodesjs-mongodb/web-controller.yaml
0 → 100644
View file @
d27a1044
apiVersion
:
v1
kind
:
ReplicationController
metadata
:
labels
:
name
:
web
name
:
web-controller
spec
:
replicas
:
2
selector
:
name
:
web
template
:
metadata
:
labels
:
name
:
web
spec
:
containers
:
-
image
:
<YOUR-CONTAINER>
name
:
web
ports
:
-
containerPort
:
3000
name
:
http-server
\ No newline at end of file
examples/nodesjs-mongodb/web-service.yaml
0 → 100644
View file @
d27a1044
apiVersion
:
v1
kind
:
Service
metadata
:
name
:
web
labels
:
name
:
web
spec
:
type
:
LoadBalancer
ports
:
-
port
:
80
targetPort
:
3000
protocol
:
TCP
selector
:
name
:
web
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment