Managing Functions - Scaleway Elements Serverless

Serverless Overview

Scaleway Elements Serverless Platform allows you to deploy your Functions (FaaS) and Containerized Applications (CaaS) in a managed infrastructure. Benefit from a constant availability, everywhere.

Scaleway ensures deployment, availability, scalability which allows you to save money and time. You can focus on software development instead of devOps missions.

Requirements

Operation Procedures

Several function operations can be performed on the Serverless Plattform, these include:

Creating a Function

With Function as a Service, you can deploy lightweight units of logics, running on our infrastructure.

1 . In the side menu, click Serverless to enter the corresponding section of the console.

2 . In the list of your Serverless Namespaces, choose the namespace you want to use.

3 . Click on Create a Function. The creation page displays.

4 . Enter the function code. You can either use the inline code editor to edit your code directly from your browser or upload a *.zip archive by choosing the Code entry type from the first drop-down menu.

Choose the desired runtime from the second drop-down menu. Currently, Serverless provides runtimes for node8, node10, python2, python3, and golang.

Set the Handler for your function and edit your code, or upload your *.zip archive.

5 . Choose a name for the function and add an optional description.

6 . Set the resources for the function, depending on its requirements. Resources define the performance characteristics of your function. They are allocated to your function at runtime.

7 . Optionally configure specific environment variables (Database host/credentials, for example), which are safely encrypted and stored in our database. Environment variables defined for a function will be injected into it together with the namespace’s variables.

8 . Set the privacy policies of the function. Privacy Policies define whether a function can be executed anonymously or protected via an authentication mechanism provided by Scaleway.

9 . If required, configure advanced options like triggers. Adding triggers to your function will make it possible for you to handle events coming from other sources, such as CRON (time-based jobs), MQTT queues, and more.

10 . Click Create a function to deploy it.

Managing a Function

1 . In the side menu, click Serverless to enter the corresponding section of the console.

2 . In the list of your Serverless Namespaces, choose the namespace you want to use.

3 . The list of your functions displays, click on the name of the function you want to manage.

4 . Edit the function’s code either by using the inline code editor or choose to upload a *.zip archive by selecting the option from the first drop-down menu. If required, the handle name of the function can be edited.

5 . Assign resources for your function. Resources define the performance characteristics of your function. They are allocated to your function at runtime.

6 . Optionally configure specific environment variables. Environment variables defined for a function will be injected into it together with the namespace’s variables.

7 . Click on Deploy a function.

8 . The function information is available from the Function Information tab. It displays the status, privacy policies, region, endpoint and optionally the description of the function:

Modifying a Functions Privacy Policies

Privacy Policies define whether a function can be executed anonymously, or protected via an authentication mechanism provided by Scaleway.

1 . In the side menu, click Serverless to enter the corresponding section of the console.

2 . In the list of your Serverless Namespaces, choose the namespace you want to use.

3 . The list of your functions displays, click on the name of the function you want to manage.

4 . Click on the Function Settings tab.

5 . Set the privacy policy for the function. It can either be Public or Private.

Deleting a Function

In case a function is no longer needed, it can be deleted from the Scaleway console.

1 . In the side menu, click Serverless to enter the corresponding section of the console.

2 . In the list of your Serverless Namespaces, choose the namespace you want to use.

3 . The list of your functions displays, click on the name of the function you want to manage.

4 . Click on the Function Settings tab.

5 . Click on Delete function to delete the function. Be careful as this is irreversible. All data will be destroyed.

Related documentations

Discover a New Cloud Experience

Deploy SSD Cloud Servers in seconds.