-
Deploy
OpenfaaS
from the application catalog. -
Install the
OpenFaaS
cli locally:curl -sSL https://cli.openfaas.com | sudo sh
-
Log into your OpenFaaS gateway (get the gateway URL from Okteto Cloud)
echo $PASSWORD | faas login -g $GATEWAY_URL --password-stdin
-
Update
stack.yaml
so the image name uses your namespace instead ofrberrelleza
-
docker login registry.cloud.okteto.net
-
Build and launch your image
faas-cli up
-
Verify that everything works fine:
faas-cli invoke hello
-
Go to the
hello
folder and launch your development environment.okteto.yml
is already configured with everything you need to develop your function:cd hello okteto up
-
To start your function, just call the
fwatchdog
process in your remote development environment:$ fwatchdog
-
Your changes will be automatically synchronized. Just stop and start the watchdog to see them applied.
TODO:
- Update
okteto.yaml
to usenodemon
for automatic reload instead of starting and stoppingfwatchdog