Self-hosted deployment
Deploy on Google Cloud Platform
Generate and manage your reports inside your own Google Cloud Platform infrastructure.
Quickstart
One of the best ways to deploy Carbone on your GCP environment is to use Google Cloud Run. Setting up a Carbone instance is very simple.
To use Carbone Enterprise Edition on Cloud Run, you need a Carbone license. Talk to us to find out more.
To set up Carbone, simply create a storage space, configure the license and launch the container on Google Cloud Run.
Create bucket to store template and renders
- First step is to create service account to enable Carbone to use a bucket in S3-compatible mode.
Go to Service account section in Google IAM Console.
Create new service account. In this example, new user is carbone-s3-access
and grant Storage Admin
and Secret Manager Secret Accessor
access :
- Next, you must generate a key for this user
Go to Storage Setting, in Interoperability tab.
Clic on "Create a key for a service account":
And create key for your service account:
Retrieve the identifiers and keep them aside for the secret storage stage:
- Finally you should create 2 storages buckets
One storage space will be used to store templates
, and the second for renders
.
If the CloudRun configuration is limited to a single instance, renders
storage is not required.
Go to Cloud Storage Console:
Create one bucket to store template and second one for renders. Just remember to use the right region.
Storing Carbone licence and Service User key
We then recommend that you store all sensitive data in Secret Manager.
Create secret to store your Carbone License:
Create secret to store S3-compatible Access Key ID
Create secret to store S3-compatible Access Key Secret
Create Cloud run instance
And finally, the very last step is to create the Carbone service on Google Cloud Run.
Go to the Google Cloud Run console and deploy a new
Service
:Configure the following items:
Container image URL
Authentication. For this simple setup we use "Allow unauthenticated invocations"
Container port:
Configure memory. Carbone need at least 1Go.
And finally following Variables and Secrets:
AWS_REGION
,AWS_ENDPOINT_URL
,BUCKET_TEMPLATES
,BUCKET_RENDERS
,CARBONE_EE_LICENSE
,AWS_ACCESS_KEY_ID
andAWS_SECRET_ACCESS_KEY
Et voilà 🎉. Your Carbone instance is available and you can check it by going to the URL of your Service. The Carbone version should then be displayed.
You can then use the API directly.
Configuration
The Carbone instance can be configured by setting environment variables: full documentation.
Enable Studio
The most popular option is to activate the Studio. To do this, simply set the CARBONE_EE_STUDIO
variable to true
.
Performance
Cold boot
By default, Google Cloud Run allows you to switch off the Carbone instance if there is no usage. In this case, consider that the first Carbone call will take a little longer.
For your information, the cold startup time is around 3s for the full Carbone image.
Scalabily
The strength of Google Cloud Run is that it supports Carbone scallability by default. You can therefore configure the minimum and maximum number of instances in the console.