-
Notifications
You must be signed in to change notification settings - Fork 2
Authentication
restaf-server can be used in the following modes:
-
As a web server for static assets with no authentication
-
With authentication
- Implicit flow authentication
- Coming soon: authorization_code authentication
The env and Dockerfile for this scenario is in /env/static directory.
Examples of the env and Dockerfile for this scenario are here
env file: https://github.com/sassoftware/restaf-server/blob/master/env/static/app.env
docker file: https://github.com/sassoftware/restaf-server/blob/master/env/static/Dockerfile
The key values are the EXPOSE for port number and the APPENTRY.
To use this scenario modify these files as follows:
This is primarily used to override the values set in Dockerfile. Setting CLIENTID here is a good practice.
- Set the CLIENTID to your implicit flow clientid
- Set the EXPOSE port to your desired port no.
- Set the following to suit your needs
ENV APPHOST=localhost
ENV APPNAME=viyaapp
ENV APPLOC=./public
ENV APPENTRY=index.html
Assign a meaninful name for your app.
This can be one of the following values:
localhost|*|ipAddress|dns-name-of-server
If set to *, restaf-server will resolve it to the dns name using nodejs function os.hostname.
This is the directory where restaf can find the static assets of your app. This is relative to the root of your application. Typically this is ./public
After a successful logon restaf will redirect to this entry specified via APPLOC.