Skip to content

Commit f3169a5

Browse files
Ticket #63: Write documentation
1 parent 4466fbb commit f3169a5

File tree

83 files changed

+426
-673
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

83 files changed

+426
-673
lines changed

README.md

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -10,27 +10,27 @@ For project documentation, please visit [docs](https://simpleidserver.github.io/
1010

1111
| Command | Description |
1212
| -------------------------- | --------------------------------------- |
13-
| psake publishHelmAndWebsite | Publish Helm Charts and the website |
14-
15-
## Packages
16-
17-
| | | | |
18-
| --------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------- |
19-
| `FaasNet.Runtime` | [![MyGet (dev)](https://img.shields.io/myget/advance-ict/v/FaasNet.Runtime.svg)](https://www.myget.org/feed/advance-ict/package/nuget/FaasNet.Runtime) | [![NuGet](https://img.shields.io/nuget/v/FaasNet.Runtime.svg)](https://nuget.org/packages/FaasNet.Runtime) | [![NuGet](https://img.shields.io/nuget/dt/FaasNet.Runtime.svg)](https://nuget.org/packages/FaasNet.Runtime) |
20-
| `FaasNet.Templates` | [![MyGet (dev)](https://img.shields.io/myget/advance-ict/v/FaasNet.Templates.svg)](https://www.myget.org/feed/advance-ict/package/nuget/FaasNet.Templates) | [![NuGet](https://img.shields.io/nuget/v/FaasNet.Templates.svg)](https://nuget.org/packages/FaasNet.Templates) | [![NuGet](https://img.shields.io/nuget/dt/FaasNet.Templates.svg)](https://nuget.org/packages/FaasNet.Templates) |
13+
| psake publishWebsite | Publish website |
14+
| psake publishDockerCI | Build and publish docker images |
15+
| psake packTemplate | Build template package |
2116

2217
## How to release ?
2318

2419
1. Build the Docker images and publish them into the Hub.
2520

2621
```
27-
psake builderDockerImage
22+
psake publishDockerCI
2823
```
2924

30-
2. Build the website and helm package and publish them into the GITHUB page.
25+
2. Build and publish the website.
3126

3227
```
33-
psake publishHelmAndWebsite
28+
psake publishWebsite
3429
```
3530

36-
3. Create and publish the tag release.
31+
3. Create and publish the tag release.
32+
4. Build the template and upload the Nuget package.
33+
34+
```
35+
psake packTemplate
36+
```

default.ps1

Lines changed: 25 additions & 55 deletions
Original file line numberDiff line numberDiff line change
@@ -12,17 +12,13 @@ properties {
1212
$versionSuffix = @{ $true = "--version-suffix=$($suffix)"; $false = ""}[$suffix -ne ""]
1313
}
1414

15-
16-
task default -depends local
17-
task local -depends compile, test
18-
task ci -depends clean, release, local, pack, publish
19-
2015
# DEV tasks
2116
task packDev -depends clean, packNoSuffix, packTemplate
2217
task dockerDev -depends clean, publishDockerDev
2318

2419
# CI tasks
2520
task dockerCI -depends clean, publishDockerCI
21+
task ci -depends clean, test, pack, publishCLI
2622

2723
task clean {
2824
rd "$source_dir\artifacts" -recurse -force -ErrorAction SilentlyContinue | out-null
@@ -47,56 +43,6 @@ task compile -depends clean {
4743
exec { dotnet build .\EventMesh.sln -c $config --version-suffix=$buildSuffix }
4844
}
4945

50-
task publishHelmAndWebsite {
51-
exec { git checkout gh-pages }
52-
exec { git rm -r . }
53-
exec { git checkout HEAD -- .gitignore }
54-
exec { git add . }
55-
exec { git commit -m "Remove" }
56-
exec { git checkout master }
57-
exec { helm package ./helm -d ./docs/charts }
58-
exec { Copy-item "./helm/Chart.yaml" -Destination "./docs/charts" }
59-
exec { helm repo index ./docs/charts }
60-
exec { Remove-Item "./docs/charts/Chart.yaml" }
61-
rd "$base_dir\docs\obj" -recurse -force -ErrorAction SilentlyContinue | out-null
62-
exec { docfx ./docs/docfx.json }
63-
exec { git add . }
64-
exec { git commit -m "Publish helm" }
65-
exec { Copy-item -Force -Recurse -Verbose "./docs/_site/*" -Destination "." }
66-
exec { git checkout gh-pages --merge }
67-
exec { git add . }
68-
exec { git commit -m "Update Documentation" }
69-
exec { git rebase -i HEAD~2 }
70-
exec { git push origin gh-pages }
71-
exec { git checkout master }
72-
}
73-
74-
task initLocalKubernetes {
75-
exec { kubectl apply -f ./kubernetes/faas-namespace.yml }
76-
exec { kubectl apply -f ./kubernetes/run-mssql.yml --namespace=faas }
77-
exec { kubectl apply -f ./kubernetes/mssql-internal-svc.yml --namespace=faas }
78-
exec { kubectl apply -f ./kubernetes/prometheus-persistent-volume.yml --namespace=faas }
79-
exec { kubectl apply -f ./kubernetes/prometheus-persistent-volume-claim.yml --namespace=faas }
80-
exec { kubectl apply -f ./kubernetes/run-faas-kubernetes.yml --namespace=faas }
81-
exec { kubectl apply -f ./kubernetes/faas-kubernetes-svc.yml --namespace=faas }
82-
exec { kubectl apply -f ./kubernetes/run-prometheus.yml --namespace=faas }
83-
exec { kubectl apply -f ./kubernetes/faas-prometheus-svc.yml --namespace=faas }
84-
exec { kubectl apply -f ./kubernetes/run-faas-gateway.yml --namespace=faas }
85-
exec { kubectl apply -f ./kubernetes/faas-gateway-svc.yml --namespace=faas }
86-
exec { kubectl apply -f ./kubernetes/run-website.yml --namespace=faas }
87-
exec { kubectl apply -f ./kubernetes/faas-website-svc.yml --namespace=faas }
88-
}
89-
90-
task initDevKubernetes {
91-
exec { kubectl apply -f ./kubernetes/faas-namespace.yml }
92-
exec { kubectl apply -f ./kubernetes/prometheus-persistent-volume.yml --namespace=faas }
93-
exec { kubectl apply -f ./kubernetes/prometheus-persistent-volume-claim.yml --namespace=faas }
94-
exec { kubectl apply -f ./kubernetes/run-prometheus.yml --namespace=faas }
95-
exec { kubectl apply -f ./kubernetes/faas-prometheus-svc.yml --namespace=faas }
96-
exec { kubectl apply -f ./kubernetes/run-faas-kubernetes.yml --namespace=faas }
97-
exec { kubectl apply -f ./kubernetes/faas-kubernetes-external-svc.yml --namespace=faas }
98-
}
99-
10046
# Publish assets
10147
task publishCLI {
10248
exec { dotnet publish $source_dir\FaasNet.CLI\FaasNet.CLI.csproj -c $config -o $result_dir\cli }
@@ -112,6 +58,7 @@ task publishDocker {
11258

11359
# Pack
11460
task pack -depends release, compile {
61+
exec { dotnet pack $source_dir\FaasNet.Function\FaasNet.Function.csproj -c $config --no-build $versionSuffix --output $result_dir }
11562
exec { dotnet pack $source_dir\FaasNet.Runtime\FaasNet.Runtime.csproj -c $config --no-build $versionSuffix --output $result_dir }
11663
exec { dotnet pack $source_dir\EventMesh.Runtime\EventMesh.Runtime.csproj -c $config --no-build $versionSuffix --output $result_dir }
11764
exec { dotnet pack $source_dir\EventMesh.Runtime.AMQP\EventMesh.Runtime.AMQP.csproj -c $config --no-build $versionSuffix --output $result_dir }
@@ -120,6 +67,7 @@ task pack -depends release, compile {
12067
}
12168

12269
task packNoSuffix -depends release, compile {
70+
exec { dotnet pack $source_dir\FaasNet.Function\FaasNet.Function.csproj -c $config --output $result_dir }
12371
exec { dotnet pack $source_dir\FaasNet.Runtime\FaasNet.Runtime.csproj -c $config --output $result_dir }
12472
exec { dotnet pack $source_dir\EventMesh.Runtime\EventMesh.Runtime.csproj -c $config --output $result_dir }
12573
exec { dotnet pack $source_dir\EventMesh.Runtime.AMQP\EventMesh.Runtime.AMQP.csproj -c $config --output $result_dir }
@@ -187,6 +135,28 @@ task deployEventMeshServerKafka {
187135
exec { kubectl apply -f ./kubernetes/eventmeshserver.kafka.yml --namespace=faas }
188136
}
189137

138+
task deployServerlessWorkflow {
139+
exec { kubectl apply -f ./kubernetes/serverlessworkflow.yml --namespace=faas }
140+
}
141+
142+
# Publish
143+
task publishWebsite {
144+
exec { git checkout gh-pages }
145+
exec { git rm -r . }
146+
exec { git checkout HEAD -- .gitignore }
147+
exec { git add . }
148+
exec { git commit -m "Remove" }
149+
exec { git checkout master }
150+
exec { docfx ./docs/docfx.json }
151+
exec { Copy-item -Force -Recurse -Verbose "./docs/_site/*" -Destination "." }
152+
exec { git checkout gh-pages --merge }
153+
exec { git add . }
154+
exec { git commit -m "Update Documentation" }
155+
exec { git rebase -i HEAD~2 }
156+
exec { git push origin gh-pages }
157+
exec { git checkout master }
158+
}
159+
190160
task test {
191161
Push-Location -Path $base_dir\tests\EventMesh.Runtime.Tests
192162

20.2 KB
Loading
Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,11 @@
11
# Introduction
22

3-
The FaasNet architecture is made of 6 blocks :
3+
FaasNet architecture is made of five blocks :
44

5-
* **Function** : Each function is deployed into one or more Kubernetes PODs.
6-
* **Gateway** : Expose operations to the angular website & CLI. They are used to manage the lifecyle of the functions and workflows.
7-
* **Monitoring** : Prometheus product is configured by default in order to monitor the published functions.
8-
* **Website** : Portal application which can be used by developers to manage the functions.
9-
* **CLI** : Command Line Interface (CLI) which can be used by developers to manage the functions.
10-
* **FaasNet Kubernetes** : API used by the gateway to interact with Kubernetes.
5+
* **Function** : One function can be deployed into one or more Kubernetes PODs.
6+
* **Gateway** : Expose operations to the portal and CLI. They can be used to perform administrative tasks on `function`, `serverless workflow` and `EventMesh server`.
7+
* **Monitoring** : Prometheus product is configured by default to monitor published functions.
8+
* **Portal/CLI** : Used by developers to perform administrative tasks.
9+
* **Kubernetes** : Execute operations on Kubernetes like : deploying / removing functions.
1110

1211
![Big Picture](images/bigpicture1.png)
Lines changed: 19 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,29 @@
11
# Docker
22

3+
An EventMesh server can easily be installed with Kubernetes. There is one deployment file per type of message broker. Following chapters list the different possibilites.
4+
5+
Whatever the deployment file chosen. By default, the EventMesh server is listening on TCP Port `30005` and a UI portal is available [here](http://localhost:30004).
6+
37
## InMemory
48

5-
TODO
9+
An EventMesh server plugged with an InMemory message broker can be deployed like this :
10+
11+
```
12+
kubectl apply -f https://raw.githubusercontent.com/simpleidserver/FaasNet/master/kubernetes/release/eventmeshserver.yml --namespace=faas
13+
```
614

715
## RabbitMQ
816

9-
TODO
17+
An EventMesh server plugged with RabbitMQ can be deployed like this :
18+
19+
```
20+
kubectl apply -f https://raw.githubusercontent.com/simpleidserver/FaasNet/master/kubernetes/release/eventmeshserver.rabbitmq.yml --namespace=faas
21+
```
1022

1123
## Kafka
1224

13-
TODO
25+
An EventMesh server plugged with Apache Kafka can be deployed like this :
26+
27+
```
28+
kubectl apply -f https://raw.githubusercontent.com/simpleidserver/FaasNet/master/kubernetes/release/eventmeshserver.kafka.yml --namespace=faas
29+
```

docs/documentation/functions/create.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ The following files will be created :
1616

1717
* *Startup.cs* and *Program.cs*: the application entry point.
1818
* *HelloWorldConfiguration.cs*: configuration properties of the function.
19-
* *FunctionHandler.cs*: contains the business logic. This class has one function which accepts one parameter and returns a JSON result. The input parameter has two distinct properties :
19+
* *FunctionHandler.cs*: contains the business logic. This class has one function with one parameter and returns a JSON result. The input parameter has two distinct properties :
2020

2121
* Configuration: its value is coming from the gateway, it will be used to configure the behavior of the function for example : `ConnectionString` and `SQL Statement`.
2222
* Input: value passed by caller.
-2.6 KB
Loading
-4.5 KB
Loading
-11.1 KB
Loading
-6.78 KB
Loading

0 commit comments

Comments
 (0)