Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion veadk/integrations/ve_faas/ve_faas.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
# limitations under the License.

import json
import os
import time

import requests
Expand Down Expand Up @@ -118,6 +119,7 @@ def _create_function(self, function_name: str, path: str):
runtime="native-python3.10/v1",
request_timeout=1800,
envs=envs,
memory_mb=2048,
)
)

Expand All @@ -141,6 +143,8 @@ def _create_application(
upstream_name: str,
service_name: str,
):
enable_key_auth = os.getenv("VEFAAS_ENABLE_KEY_AUTH", "true").lower() == "true"

response = ve_request(
request_body={
"Name": application_name,
Expand All @@ -152,7 +156,7 @@ def _create_application(
"GatewayName": gateway_name,
"ServiceName": service_name,
"UpstreamName": upstream_name,
"EnableKeyAuth": True,
"EnableKeyAuth": enable_key_auth,
"EnableMcpSession": True,
},
"TemplateId": self.template_id,
Expand Down