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

update fission docs #34

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
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
2 changes: 1 addition & 1 deletion module16/fission/3.functions/1.go-env.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ spec:
- A builder pod is composed by env builder, which is to build the source, and fetcher, which is to retrieve code. The two containers share the same sharedVolume

```
kubectl get deployment -n fission-builder go-254706 -oyaml
kubectl get deployment go-254706 -oyaml
```
```
apiVersion: apps/v1
Expand Down
4 changes: 2 additions & 2 deletions module16/fission/3.functions/2.go-fn.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,8 +121,8 @@ poolmgr-go-default-254706-788858ccb8-v978z 2/2 Running 0 27s
the code is compiled as golang plugin

```
go build -buildmode=plugin httpserver.go
ls -la httpserver.so
go build -buildmode=plugin hello.go
ls -la hello.so
```
and is loaded by go server, which is defined in fission golang env repo

Expand Down
7 changes: 7 additions & 0 deletions module16/fission/3.functions/hello.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@

module.exports = async function(context) {
return {
status: 200,
body: "hello, world!\n"
};
}
Binary file added module16/fission/3.functions/hello.so
Binary file not shown.
2 changes: 1 addition & 1 deletion module16/knative/3.eventing/2.source-and-channel.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ kn channel create knative-hello-channel
### edit pingsource and set sink to channel and let fn subscribe the event

```
kubectl apply -f pingsource.yaml
kubectl replace -f pingsource.yaml
```

### wait for ping being invoked and function pod being scaled
Expand Down
17 changes: 17 additions & 0 deletions module16/knative/3.eventing/sample-app.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,23 @@ spec:
kind: Service
name: helloworld-go
---
# Knative Eventing Trigger to trigger the helloworld-go service
apiVersion: eventing.knative.dev/v1
kind: Trigger
metadata:
name: event-display
spec:
broker: default
filter:
attributes:
type: dev.knative.samples.hifromknative
source: knative/eventing/samples/hello-world
subscriber:
ref:
apiVersion: v1
kind: Service
name: helloworld-go
---
apiVersion: serving.knative.dev/v1
kind: Service
metadata:
Expand Down