Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

deploy weather-weather-pipeline-jdpsr-anthos-export-zzd6j-pod-t6mrq #46

Open
wants to merge 68 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
68 commits
Select commit Hold shift + click to select a range
abea03b
push bg image fix
daniyalj Jul 24, 2019
9d8af00
revert css
daniyalj Jul 24, 2019
8e5da41
add openshift template
daniyalj Sep 3, 2019
95b5d5f
Create deployment.yaml
daniyalj Nov 13, 2019
c194b62
Create build-task.yaml
daniyalj Nov 14, 2019
e886f71
Create deploy-task.yaml
daniyalj Nov 14, 2019
09ef99d
Create pipeline-run.yaml
daniyalj Nov 14, 2019
5839261
Update style.css
daniyalj Nov 14, 2019
d0d917e
Update pipeline-run.yaml
daniyalj Nov 14, 2019
e70c269
Create pipeline.yaml
daniyalj Nov 14, 2019
6b56478
Update pipeline.yaml
daniyalj Nov 14, 2019
735f30d
change image to washington
daniyalj Nov 14, 2019
2101abe
change to v2
daniyalj Nov 14, 2019
86fae2a
replace image to blue
daniyalj Nov 14, 2019
a6a7269
Update pipeline-run.yaml
daniyalj Nov 14, 2019
f6a2caf
change back to mountain
daniyalj Nov 14, 2019
bf7f970
change back to name
daniyalj Nov 14, 2019
c0dc8f0
change to washington
daniyalj Nov 14, 2019
36c7cbd
Update pipeline-run.yaml
daniyalj Nov 14, 2019
7ff8bee
Draft create
daniyalj Nov 19, 2019
1bfe682
Revert "Update pipeline-run.yaml"
daniyalj Nov 19, 2019
09cf508
remove jenkins
daniyalj Nov 19, 2019
5568629
Delete .helmignore
daniyalj Nov 19, 2019
7136f58
remove jenkins
daniyalj Nov 19, 2019
cc2b2ab
Merge branch 'static' of https://github.com/arctiqteam/weather-app in…
daniyalj Nov 19, 2019
7b9610a
Delete .dockerignore
daniyalj Nov 19, 2019
ce277ff
Update style.css
daniyalj Dec 9, 2019
895cd36
Create manifest.yml
daniyalj Oct 30, 2020
9b10cfb
Update README.md
daniyalj Oct 30, 2020
3e9f468
Update README.md
daniyalj Oct 30, 2020
da0da1e
Update README.md
daniyalj Nov 1, 2020
155983e
Update README.md
daniyalj Nov 1, 2020
7d0d5f8
Update README.md
daniyalj Nov 1, 2020
ddf973d
Update README.md
daniyalj Nov 1, 2020
6effb89
Update README.md
daniyalj Nov 1, 2020
db9f4df
Update README.md
daniyalj Nov 1, 2020
d96dceb
Update README.md
daniyalj Nov 1, 2020
a2ee695
Update README.md
daniyalj Nov 1, 2020
eb3f8a5
Update README.md
daniyalj Nov 1, 2020
6cfb73e
Update README.md
daniyalj Nov 1, 2020
7d5ff7a
Update style.css
daniyalj Nov 2, 2020
b5de33f
commit sf
daniyalj Nov 3, 2020
800dd99
sf
daniyalj Nov 3, 2020
c523743
Update style.css
daniyalj Nov 3, 2020
eadddc7
Update server.js
daniyalj Nov 3, 2020
41e6fef
change sf
daniyalj Nov 3, 2020
dfe0e7e
update docs
daniyalj Nov 3, 2020
b0cc940
Update style.css
daniyalj Nov 4, 2020
b761e1b
Update server.js
daniyalj Nov 4, 2020
43c5e2d
Update server.js
daniyalj Nov 4, 2020
aeeeea1
Update style.css
daniyalj Nov 4, 2020
13db427
Merge pull request #1 from backstage-pass-kf/imperial
daniyalj Nov 4, 2020
6914a5d
Revert "Change to Farenheit"
daniyalj Nov 4, 2020
99115a7
Merge pull request #2 from backstage-pass-kf/revert-1-imperial
daniyalj Nov 4, 2020
dfc3d2d
Update style.css
daniyalj Nov 5, 2020
8d56fcc
Update server.js
daniyalj Nov 5, 2020
b647f36
Merge pull request #3 from backstage-pass-kf/imperial
daniyalj Nov 5, 2020
e8ff643
Update style.css
daniyalj Nov 5, 2020
51d114b
Update server.js
daniyalj Nov 5, 2020
88ad313
Update style.css
daniyalj Nov 5, 2020
aea2bd5
Update server.js
daniyalj Nov 5, 2020
2b7df6d
Merge pull request #4 from backstage-pass-kf/imperial
daniyalj Nov 5, 2020
f25eff4
Update style.css
daniyalj Nov 5, 2020
f5f8b9c
Update server.js
daniyalj Nov 5, 2020
4c4eea7
Update style.css
daniyalj Nov 5, 2020
43d1c50
Update server.js
daniyalj Nov 5, 2020
8473e5a
Merge pull request #5 from backstage-pass-kf/imperial
daniyalj Nov 5, 2020
fc15843
deploy weather-weather-pipeline-jdpsr-anthos-export-zzd6j-pod-t6mrq
Nov 6, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 4 additions & 21 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,23 +1,6 @@
# Arctiq Weather App - utilized in an OpenShift Pipeline
# Arctiq Weather App
Simple Node.js Command Line Weather Application

* Built upon bmorielli25's [weather-app](https://github.com/bmorelli25/simple-nodejs-weather-app)

This repo was used to build an app and promote across different OpenShift clusters in this [demo](https://www.arctiq.ca/our-blog/2018/10/6/multi-cloud-application-container-deployment-pipeline/)

### Pre-requisites

* [Skopeo Jenkins slave image for image promotion](https://github.com/redhat-cop/containers-quickstarts/tree/master/jenkins-slaves/jenkins-slave-image-mgmt)
* 3 OpenShift clusters:
* DEV/QA Cluster
* PROD A Cluster
* PROD B Cluster
* Replace cluster URLs in <your-openshift-console> snippets.

### How to run:

`oc create -f jenkins/pipeline.yaml`

### Run the pipeline and see the weather!

![gif](https://github.com/arctiqteam/weather-app/blob/master/giphy.gif?raw=true 'website gif')
```
$ cf push
```
123 changes: 123 additions & 0 deletions config-management/namespaces/weather/deployment.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,123 @@
apiVersion: apps/v1
kind: Deployment
metadata:
annotations:
deployment.kubernetes.io/revision: "36"
labels:
app.kubernetes.io/component: app-scaler
app.kubernetes.io/managed-by: kf
app.kubernetes.io/name: weather
name: weather
spec:
progressDeadlineSeconds: 600
replicas: 1
revisionHistoryLimit: 10
selector:
matchLabels:
app.kubernetes.io/component: app-server
app.kubernetes.io/managed-by: kf
app.kubernetes.io/name: weather
strategy:
rollingUpdate:
maxSurge: 25%
maxUnavailable: 25%
type: RollingUpdate
template:
metadata:
annotations:
sidecar.istio.io/inject: "true"
traffic.sidecar.istio.io/includeOutboundIPRanges: '*'
creationTimestamp: null
labels:
app.kubernetes.io/component: app-server
app.kubernetes.io/managed-by: kf
app.kubernetes.io/name: weather
kf.dev/networkpolicy: app
spec:
containers:
- env:
- name: PORT
value: "8080"
- name: VCAP_APP_PORT
value: $(PORT)
- name: CF_INSTANCE_IP
valueFrom:
fieldRef:
apiVersion: v1
fieldPath: status.podIP
- name: CF_INSTANCE_INTERNAL_IP
value: $(CF_INSTANCE_IP)
- name: VCAP_APP_HOST
value: $(CF_INSTANCE_IP)
- name: CF_INSTANCE_PORT
value: "8080"
- name: CF_INSTANCE_ADDR
value: $(CF_INSTANCE_IP):$(CF_INSTANCE_PORT)
- name: CF_INSTANCE_GUID
valueFrom:
fieldRef:
apiVersion: v1
fieldPath: metadata.uid
- name: INSTANCE_GUID
value: $(CF_INSTANCE_GUID)
- name: CF_INSTANCE_INDEX
value: "0"
- name: INSTANCE_INDEX
value: $(CF_INSTANCE_INDEX)
- name: MEMORY_LIMIT
valueFrom:
resourceFieldRef:
divisor: 1Mi
resource: limits.memory
- name: DISK_LIMIT
valueFrom:
resourceFieldRef:
divisor: 1Mi
resource: limits.ephemeral-storage
- name: LANG
value: en_US.UTF-8
- name: VCAP_SERVICES
valueFrom:
secretKeyRef:
key: VCAP_SERVICES
name: kf-injected-envs-weather
optional: false
- name: DATABASE_URL
valueFrom:
secretKeyRef:
key: DATABASE_URL
name: kf-injected-envs-weather
optional: true
- name: MEMORY_LIMIT
value: $(MEMORY_LIMIT)M
- name: KF_UPDATE_REQUESTS_22d1139e-aa64-485d-8bac-acc75574daa5
value: "34"
image: northamerica-northeast1-docker.pkg.dev/arctiq-anthos/kf-processing/app_weather_weather-34:33377576-bc2a-4b4e-a5c0-a6458a58c7b5
imagePullPolicy: Always
name: user-container
ports:
- containerPort: 8080
name: http-user-port
protocol: TCP
readinessProbe:
failureThreshold: 3
periodSeconds: 10
successThreshold: 1
tcpSocket:
port: 8080
timeoutSeconds: 60
resources:
requests:
cpu: 100m
ephemeral-storage: 1Gi
memory: 1Gi
terminationMessagePath: /dev/termination-log
terminationMessagePolicy: File
dnsPolicy: ClusterFirst
enableServiceLinks: false
restartPolicy: Always
schedulerName: default-scheduler
serviceAccount: sa-weather
serviceAccountName: sa-weather
terminationGracePeriodSeconds: 30

11 changes: 11 additions & 0 deletions config-management/namespaces/weather/namespace.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
apiVersion: v1
kind: Namespace
metadata:
labels:
app.kubernetes.io/managed-by: kf
istio-injection: enabled
name: weather
spec:
finalizers:
- kubernetes

11 changes: 11 additions & 0 deletions config-management/namespaces/weather/sa.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
apiVersion: v1
kind: ServiceAccount
metadata:
labels:
app.kubernetes.io/component: serviceaccount
app.kubernetes.io/managed-by: kf
app.kubernetes.io/name: weather
name: sa-weather
secrets:
- name: sa-weather-token-2nkk7

18 changes: 18 additions & 0 deletions config-management/namespaces/weather/service.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
apiVersion: v1
kind: Service
metadata:
labels:
app.kubernetes.io/component: service
app.kubernetes.io/managed-by: kf
app.kubernetes.io/name: weather
name: weather
spec:
ports:
- name: http-user-port
port: 80
targetPort: 8080
selector:
app.kubernetes.io/component: app-server
app.kubernetes.io/managed-by: kf
app.kubernetes.io/name: weather

Empty file.
Loading