Updated docs for cli flag changes.

This commit is contained in:
Travis Reeder
2017-09-07 15:53:28 -07:00
parent 3d8ca450bb
commit e56d555c3e
17 changed files with 26 additions and 27 deletions

View File

@@ -80,7 +80,7 @@ fn run
# Deploy your functions to the Fn server (default localhost:8080)
# This will create a route to your function as well
fn deploy myapp
fn deploy --app myapp
```
Now you can call your function:

View File

@@ -9,7 +9,7 @@ Creating Lambda functions is not much different than using regular functions, ju
the `lambda-node-4` runtime.
```sh
fn init --runtime lambda-node-4 <DOCKER_HUB_USERNAME>/lambda-node
fn init --runtime lambda-node-4 --name lambda-node
```
Be sure the filename for your main handler is `func.js`.

View File

@@ -52,6 +52,6 @@ by passing `--version <version>.`
You can then deploy the imported lambda as follows:
```
./fn deploy myapp
./fn deploy --app myapp
````
Now the function can be reached via ```http://$HOSTNAME/r/user/my-function```

View File

@@ -81,7 +81,7 @@ Creating Lambda functions is not much different than using regular functions, ju
the `lambda-node` runtime.
```sh
fn init --runtime lambda-node <DOCKER_HUB_USERNAME>/lambda-node
fn init --runtime lambda-node --name lambda-node
```
Be sure the filename for your main handler is `func.js`.

View File

@@ -13,7 +13,7 @@ Now change the code as you desire to do whatever magic you need it to do. Once d
Simply run
```bash
fn init <username>/<funcname>
fn init --name <funcname>
```
This will create the ```func.yaml``` file required by functions, which can be built by running:

View File

@@ -7,7 +7,6 @@ Other than a different runtime, this is no different than any other node example
To use the lambda-nodejs4.3 runtime, use this `fn init` command:
```sh
fn init --runtime lambda-nodejs4.3 <DOCKER_HUB_USERNAME>/lambda-node
fn build
fn init --runtime lambda-nodejs4.3 --name lambda-node
cat payload.json | fn run
```

View File

@@ -4,7 +4,7 @@ This function executes an INSERT or SELECT against a table in a given postgres s
```
# Create your func.yaml file
fn init <YOUR_DOCKERHUB_USERNAME>/func-postgres
fn init --name func-postgres
# Build the function
fn build
# Test it

View File

@@ -4,7 +4,7 @@ This example will show you how to test and deploy a SlackBot command to Oracle F
```sh
# create your func.yaml file
fn init <YOUR_DOCKERHUB_USERNAME>/guppy
fn init
# build the function - install dependencies from json gem
fn build
# test it

View File

@@ -6,7 +6,7 @@ This is an example of an [asynchronous function](/docs/async.md).
```sh
# Initialize your function creating a func.yaml file
fn init --type async <DOCKERHUB_USERNAME>/hello-go-async
fn init --type async --name hello-go-async
# Test your function. This will run inside a container exactly how it will on the server
fn run
@@ -16,7 +16,7 @@ cat sample.payload.json | fn run
# Deploy your functions to the Oracle Functions server (default localhost:8080)
# This will create a route to your function as well
fn deploy myapp
fn deploy --app myapp
```
### Now call your function:

View File

@@ -6,7 +6,7 @@ This example will show you how to test and deploy Go (Golang) code to Oracle Fun
```sh
# Initialize your function creating a func.yaml file
fn init <DOCKERHUB_USERNAME>/hello-go
fn init --name hello-go
# Test your function. This will run inside a container exactly how it will on the server
fn run
@@ -16,7 +16,7 @@ cat sample.payload.json | fn run
# Deploy your functions to the Oracle Functions server (default localhost:8080)
# This will create a route to your function as well
fn deploy myapp
fn deploy --app myapp
```
### Now call your function:

View File

@@ -9,7 +9,7 @@ This example will show you how to test and deploy Go (Golang) code with vendored
glide install -v #Or what ever vendor tool you want. We have a glide.yaml for you here already.
# Initialize your function creating a func.yaml file
fn init <DOCKERHUB_USERNAME>/hello-go
fn init --name hello-go
# Test your function. This will run inside a container exactly how it will on the server
fn run
@@ -19,7 +19,7 @@ cat sample.payload.json | fn run
# Deploy your functions to the Oracle Functions server (default localhost:8080)
# This will create a route to your function as well
fn deploy myapp
fn deploy --app myapp
```
### Now call your function:

View File

@@ -5,7 +5,7 @@ This example will show you how to test and deploy Java code to Oracle Functions.
```sh
# Initialize your function creating a func.yaml file
fn init hello-java --runtime java
fn init --name hello-java --runtime java
# Test your function. This will run inside a container exactly how it will on the server
fn run
@@ -15,7 +15,7 @@ echo "Michael FassBender" | fn run
# Deploy your functions to the Oracle Functions server (default localhost:8080)
# This will create a route to your function as well
fn deploy myapp
fn deploy --app myapp
```
### Now call your function:

View File

@@ -6,7 +6,7 @@ This example will show you how to test and deploy Node code to Oracle Functions.
```sh
# Initialize your function creating a func.yaml file
fn init <DOCKERHUB_USERNAME>/hello-node
fn init --name hello-node
# Test your function.
# This will run inside a container exactly how it will on the server. It will also install and vendor dependencies from Gemfile
@@ -17,7 +17,7 @@ cat sample.payload.json | fn run
# Deploy your functions to the Oracle Functions server (default localhost:8080)
# This will create a route to your function as well
fn deploy myapp
fn deploy --app myapp
```
### Now call your function:

View File

@@ -6,7 +6,7 @@ This example will show you how to test and deploy PHP code to Oracle Functions.
```sh
# Initialize your function creating a func.yaml file
fn init <DOCKERHUB_USERNAME>/hello-php
fn init --name hello-php
# Test your function.
# This will run inside a container exactly how it will on the server. It will also install and vendor dependencies from Gemfile
@@ -17,7 +17,7 @@ cat sample.payload.json | fn run
# Deploy your functions to the Oracle Functions server (default localhost:8080)
# This will create a route to your function as well
fn deploy myapp
fn deploy --app myapp
```
### Now call your function:

View File

@@ -6,7 +6,7 @@ This example will show you how to test and deploy Python code to Oracle Function
```sh
# Initialize your function creating a func.yaml file
fn init <DOCKERHUB_USERNAME>/hello-python
fn init --name hello-python
# Test your function.
# This will run inside a container exactly how it will on the server. It will also install and vendor dependencies from Gemfile
@@ -17,7 +17,7 @@ cat sample.payload.json | fn run
# Deploy your functions to the Oracle Functions server (default localhost:8080)
# This will create a route to your function as well
fn deploy myapp
fn deploy --app myapp
```
### Now call your function:

View File

@@ -6,7 +6,7 @@ This example will show you how to test and deploy Ruby code to Oracle Functions.
```sh
# Initialize your function creating a func.yaml file
fn init <DOCKERHUB_USERNAME>/hello-ruby
fn init --name hello-ruby
# Test your function.
# This will run inside a container exactly how it will on the server. It will also install and vendor dependencies from Gemfile
@@ -17,7 +17,7 @@ cat sample.payload.json | fn run
# Deploy your functions to the Oracle Functions server (default localhost:8080)
# This will create a route to your function as well
fn deploy myapp
fn deploy --app myapp
```
### Now call your function:

View File

@@ -34,7 +34,7 @@ fn main() {
```sh
# Initialize your function creating a func.yaml file
fn init <DOCKERHUB_USERNAME>/hello-rust
fn init --name hello-rust
# Test your function. This will run inside a container exactly how it will on the server
fn run
@@ -44,7 +44,7 @@ cat sample.payload.json | fn run
# Deploy your functions to the Oracle Functions server (default localhost:8080)
# This will create a route to your function as well
fn deploy myapp
fn deploy --app myapp
```
### Now call your function: