A foreword on security
These instructions are for a development environment. If you plan to expose OpenFaaS on the public Internet you need to enable basic authentication with a proxy such as Kong or Traefik at a minimum. TLS is also highly recomended and freely available with LetsEncrypt.org.
OpenFaaS is Kubernetes native and you can follow the deployment guide here.
You can follow the deployment guide for Docker Swarm or use the Docker Playground below if you don't have direct access to Docker.
You can quickly start OpenFaaS on Docker Swarm online using the community-run Docker playground: play-with-docker.com (PWD) by clicking the button below: