Skip to content

Commit 6f6b462

Browse files
committed
refactor: Use colors service for Traffic dist
- Service deployment will not describe revisions - Traffic distribution will use blue-green-canary image to show revs/traffic - Added OpenShift videos
1 parent b0afc9a commit 6f6b462

31 files changed

Lines changed: 510 additions & 571 deletions

.github/workflows/main.yml

Lines changed: 16 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -2,43 +2,28 @@ name: Knative Tutorial
22

33
on:
44
push:
5-
branches:
6-
- release/1.x
5+
tags:
6+
- "v1.13"
77
env:
8-
SITE_DIR: 'gh-pages'
8+
SITE_DIR: "gh-pages"
9+
910
jobs:
10-
build_site:
11+
buildAnDeploySite:
1112
name: "Build site with Antora"
12-
runs-on: [ubuntu-latest]
13+
runs-on: ubuntu-latest
1314
steps:
1415
- name: Checkout
1516
uses: actions/checkout@v2
1617
- name: "Generate site using antora site action"
17-
uses: kameshsampath/antora-site-action@master
18+
uses: kameshsampath/antora-site-action@v0.2.4
1819
with:
19-
antora_playbook: site.yml
20-
- name: "Upload generated site"
21-
uses: actions/upload-artifact@v1.0.0
20+
antora_playbook: site.yml
21+
- name: Deploy Site
22+
id: deploy_site
23+
uses: peaceiris/actions-gh-pages@v3
2224
with:
23-
name: site
24-
path: "${{ github.workspace }}/${{ env.SITE_DIR }}"
25-
deploy_site:
26-
runs-on: [ubuntu-latest]
27-
needs: [build_site]
28-
name: "Deploy GitHub Pages"
29-
steps:
30-
- name: Checkout
31-
uses: actions/checkout@v2
32-
- name: Download generated site
33-
uses: actions/download-artifact@v1
34-
with:
35-
name: site
36-
path: "${{ github.workspace }}/${{ env.SITE_DIR }}"
37-
- name: Deploy to GitHub Pages
38-
uses: JamesIves/github-pages-deploy-action@3.2.1
39-
with:
40-
# ACCESS_TOKEN: # optional
41-
GITHUB_TOKEN: "${{ github.token}}"
42-
FOLDER: "${{ env.SITE_DIR }}"
43-
BRANCH: 'gh-pages'
44-
COMMIT_MESSAGE: "[CI] Publish Documentation for ${{ github.sha }}"
25+
deploy_key: "${{ secrets.TKN_STAGING_SITE_DEPLOY }}"
26+
publish_dir: "${{ env.SITE_DIR }}"
27+
publish_branch: "gh-pages"
28+
full_commit_message: "[CI]${{ github.event.head_commit.message }}"
29+

CONTRIBUTING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,4 +35,4 @@ Now you are all set,
3535
- Prepare your changes in the respective documentation repository
3636
- Send the PR to respective repositories listed above
3737

38-
We try to follow the Git commit messages using <http://karma-runner.github.io/4.0/dev/git-commit-msg.html> and thats not a hard rule ;)
38+
We try to follow the Git commit messages using <https://www.conventionalcommits.org/en/v1.0.0/> and thats not a hard rule ;)

dev-site.yml

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -22,22 +22,23 @@ content:
2222
asciidoc:
2323
attributes:
2424
tutorial-namespace: knativetutorial
25-
branch: staging
25+
branch: master
2626
workshop-domain: guru.devx.red
27-
minikube-version: v1.14.1
27+
minikube-version: v1.17.1
2828
openshift-version: v4.6
2929
kubernetes-version: v1.19.0
30-
knative-version: v0.17.0
31-
knative-serving-version: v0.17.4
32-
net-kourier-version: v0.17.2
33-
knative-eventing-version: v0.17.8
34-
knative-sources-version: v0.17.7
35-
kn-client-version: v0.17.3
30+
knative-version: v0.19.0
31+
knative-serving-version: v0.19.0
32+
net-kourier-version: v0.19.0
33+
knative-eventing-version: v0.19.2
34+
knative-sources-version: v0.19.0
35+
kn-client-version: v0.19.1
3636
kubernetes-cli: kubectl
3737
release-version: master
3838
page-pagination: true
3939
openshift-console-url: https://console-openshift-console.apps.example.com
4040
etherpad-url: http://example.com
41+
repo-base: https://github.com/redhat-developer-demos/knative-tutorial
4142
extensions:
4243
- ./lib/remote-include-processor.js
4344
- ./lib/tab-block.js

documentation/modules/ROOT/pages/_partials/serving-nav.adoc

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,10 @@ endif::[]
2626
** xref:serving:basic-fundas.adoc#deploying-new-revision[Deploy a New Revision of a Service]
2727
** xref:serving:basic-fundas.adoc#basics-cleanup[Cleanup]
2828
29-
* xref:serving:traffic-distribution.adoc[Traffic Distribution]
30-
** xref:serving:traffic-distribution.adoc#deploying-revisions[Arbitrary Revision Names]
29+
* xref:serving:traffic-distribution.adoc[Revisions and Traffic Distribution]
30+
** xref:serving:traffic-distribution.adoc#deploy-colors-service[Deploy Colors Service]
31+
** xref:serving:traffic-distribution.adoc#deploying-new-revision[Deploy New Revision]
32+
** xref:serving:traffic-distribution.adoc#tag-service-revisions[Tagging Revisions]
3133
** xref:serving:traffic-distribution.adoc#blue-green[Blue-Green Deployment]
3234
** xref:serving:traffic-distribution.adoc#canary-release[Canary Release]
3335
Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
** xref:setup:tutorial-sources.adoc#download-tutorial-sources[Download Tutorial Sources]
1+
** xref:setup:setup.adoc#download-tutorial-sources[Tutorial Sources]
2+
** xref:setup:setup.adoc#tools[Tutorial Tools]
23
** xref:setup:kubernetes-cluster.adoc#kubernetes-cluster[Choose your Kubernetes Cluster]
34
*** xref:setup:minikube.adoc[Minikube]
45
**** xref:setup:minikube.adoc#start-minikube[Configure and Start Minikube]
@@ -8,8 +9,4 @@
89
**** xref:setup:minikube.adoc#install-ingress-controller[Install Ingress Controller]
910
**** xref:setup:minikube.adoc#install-knative-eventing[Install Knative Eventing]
1011
**** xref:setup:minikube.adoc#create-tutorial-namespace[Create Tutorial Namespace]
11-
*** xref:setup:openshift.adoc[OpenShift]
12-
** xref:setup:setup.adoc[Development Environment]
13-
// TODO - not sure we need this
14-
// *** xref:setup:setup.adoc[Install Locally]
15-
// *** xref:setup:tutorial-dev-env.adoc[All in One]
12+
*** xref:setup:openshift.adoc[OpenShift]
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
apiVersion: serving.knative.dev/v1
2+
kind: Service
3+
metadata:
4+
name: blue-green-canary
5+
spec:
6+
template:
7+
spec:
8+
containers:
9+
- image: quay.io/rhdevelopers/blue-green-canary
10+
env:
11+
- name: BLUE_GREEN_CANARY_COLOR
12+
value: "#6bbded"
13+
- name: BLUE_GREEN_CANARY_MESSAGE
14+
value: "Hello"
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
apiVersion: serving.knative.dev/v1
2+
kind: Service
3+
metadata:
4+
name: blue-green-canary
5+
spec:
6+
template:
7+
spec:
8+
containers:
9+
- image: quay.io/rhdevelopers/blue-green-canary
10+
env:
11+
- name: BLUE_GREEN_CANARY_COLOR
12+
value: "#f2f25e"
13+
- name: BLUE_GREEN_CANARY_MESSAGE
14+
value: "Bonjour"
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
apiVersion: serving.knative.dev/v1
2+
kind: Service
3+
metadata:
4+
name: blue-green-canary
5+
spec:
6+
template:
7+
spec:
8+
containers:
9+
- image: quay.io/rhdevelopers/blue-green-canary
10+
env:
11+
- name: BLUE_GREEN_CANARY_COLOR
12+
value: "#5bbf45"
13+
- name: BLUE_GREEN_CANARY_MESSAGE
14+
value: "Namaste"

documentation/modules/serving/examples/serving/greeter-v1-service.yaml

Lines changed: 0 additions & 17 deletions
This file was deleted.

documentation/modules/serving/examples/serving/greeter-v2-service.yaml

Lines changed: 0 additions & 20 deletions
This file was deleted.

0 commit comments

Comments
 (0)