For detailed information about creating API keys, refer to the how to create API keys documentation.
Deploying Open WebUI with Scaleway's Generative APIs
- open-webui
- docker
- scaleway
- generative-apis
Integrating Scaleway’s Generative APIs with Open WebUI allows you to leverage powerful AI models in a user-friendly, self-hosted interface. Open WebUI is an open-source frontend that simplifies interactions with AI models, providing an intuitive alternative to proprietary AI interfaces.
This tutorial will guide you through:
- Configuring Generative APIs on Scaleway
- Installing Open WebUI locally
- Deploying Open WebUI using Scaleway’s Serverless Containers
By the end, you will have a fully functional AI-powered setup.
Before you startLink to this anchor
To complete the actions presented below, you must have:
PrerequisitesLink to this anchor
- A Scaleway account logged into the console
- Owner status or appropriate IAM permissions
- Docker installed on your system
Configuring Generative APIs on ScalewayLink to this anchor
Scaleway’s Generative APIs provide access to advanced AI models via simple API calls. Follow the instructions below to set up Generative APIs
Creating an API keyLink to this anchor
- Log in to the Scaleway console.
- Click on your Organization name in the top right corner of the console to display the menu.
- Click API keys in the pop-up menu.
- Click Generate a New API Key, provide a name, and store the key securely.
Identifying the API endpointLink to this anchor
Scaleway assigns a unique endpoint for your Generative API access. This can be found in the Generative APIs section of the console. The format typically follows:
https://api.scaleway.ai/<YOUR_PROJECT_ID>/v1
If you have not created a dedicated Project and are using the default
Project created with your Scaleway account, you can use the following URL: https://api.scaleway.ai/v1
.
You can also find the exact URL snippet including your project_id
by visiting the Generative API Playground and clicking View Code.
Refer to our dedicated documentation to retrieve your Project ID.
Installing Open WebUI locallyLink to this anchor
Open WebUI provides an easy-to-use interface for interacting with AI models. The recommended installation method is via Docker.
Running Open WebUI with Scaleway integrationLink to this anchor
-
Pull and run the Docker container:
docker run -p 3000:8080 \-e OPENAI_API_BASE_URL=https://api.scaleway.ai/<YOUR_PROJECT_ID>/v1 \-e OPENAI_API_KEY=<YOUR_API_KEY> \-v open-webui:/app/backend/data \--name open-webui \--restart always \ghcr.io/open-webui/open-webui:mainNoteReplace
<YOUR_PROJECT_ID>
and<YOUR_API_KEY>
with your actual values. -
Navigate to
http://localhost:3000
in your browser to access the Open WebUI interface. -
Click Sign Up to create an administrator account.
-
Select a model from the available Scaleway AI models and start interacting.
For more details, refer to the Open WebUI Quick Start Guide.
Deploying Open WebUI using Scaleway’s Serverless Containers (Optional)Link to this anchor
For cloud-based deployment, Scaleway’s Serverless Containers offer a scalable solution.
Deploying on Scaleway via the consoleLink to this anchor
- In the Scaleway console, navigate to Serverless > Containers.
- Click Deploy Container to display the container creation wizard.
- Select an external registry and use the
ghcr.io/open-webui/open-webui:main
image.
The default port 8080
is used by the ghcr.io/open-webui/open-webui:main
image, so no further configuration is needed.
-
Enter a name for your container and configure its resources.
-
Click Advanced options and configure secrets:
- Set
OPENAI_API_BASE_URL
andOPENAI_API_KEY
with your specific values.
- Set
-
Click Deploy container to launch deployment. Once deployed, note the provided endpoint to access Open WebUI.
NoteSince the Open WebUI default image is around 5 GB size, deployment can take a couple of minutes before being ready.
Deploying on Scaleway using the ClILink to this anchor
Ensure you have a Scaleway Serverless Containers namespace
Scaleway Serverless Containers are deployed inside a namespace. Run the following command to create a namespace:
scw container namespace create name=openwebui-ns region=fr-par
Run the following command to retrieve the namespace ID:
scw container namespace list
Create the Serverless ContainerLink to this anchor
Run the following command to create the container with your Docker image and secret injection:
$ scw container container create name=open-webui \namespace-id=<YOUR_NAMESPACE_ID> \registry-image="ghcr.io/open-webui/open-webui:main" \environment-variables.OPENAI_API_BASE_URL="https://api.scaleway.ai/<YOUR_PROJECT_ID>/v1" \secret-environment-variables.0.key="OPENAI_API_KEY" \secret-environment-variables.0.value="<YOUR_SECRET_KEY>" \region=fr-par
Replace <YOUR_PROJECT_ID>
and <YOUR_API_KEY>
with your actual values.
For more information, refer to Scaleway’s Serverless Containers documentation.