Store your templates and generated documents into Azure Blob Storage.
Install Node 18 Create 2 Azure Blob Storage containers to store templates and renders (generated documents). Create an Azure Storage account and obtain the access keys.
Create a plugin directory in the same directory as the carbone-ee binary.
mkdir pluginEnter into the plugin directory
cd pluginClone the repository
git clone https://github.com/carboneio/carbone-ee-plugin-azure-blob-storage.gitInstall Npm Packages
npm installProvide Azure Blob Storage configurations, as environment variables:
Authorization with Shared Key (for local developpemen not recommended for Container app production deployement)
AZURE_STORAGE_ACCOUNT=STORAGE_ACCOUNT_NAME
AZURE_STORAGE_KEY=STORAGE_ACCOUNT_KEY
CONTAINER_TEMPLATES=STORAGE_CONTAINER_TEMPLATES
CONTAINER_RENDERS=STORAGE_RENDERS_CONTAINERAZURE_STORAGE_ACCOUNT=STORAGE_ACCOUNT_NAME
CONTAINER_TEMPLATES=STORAGE_CONTAINER_TEMPLATES
CONTAINER_RENDERS=STORAGE_RENDERS_CONTAINERAZURE_STORAGE_ACCOUNT=STORAGE_ACCOUNT_NAME
AZURE_MANAGED_IDENTITY_CLIENT_ID="Client ID of user_assigned_identity
CONTAINER_TEMPLATES=STORAGE_CONTAINER_TEMPLATES
CONTAINER_RENDERS=STORAGE_RENDERS_CONTAINERIf you are using Carbone Docker, you have to mount the plugin directory as a volume into the container, and you have to define environment variables for Azure Blob Storage credentials
Command for Docker CLI:
docker run --name carbone -p 4000:4000 -e LANG=C.UTF-8 -v ./plugin:/app/plugin -e AZURE_STORAGE_ACCOUNT=<STORAGE_ACCOUNT_NAME> -e AZURE_STORAGE_KEY=<STORAGE_ACCOUNT_KEY> -e CONTAINER_TEMPLATES='templates' -e CONTAINER_RENDERS='renders' carbone/carbone-eeFile for Docker-compose:
version: "3.9"
services:
carbone:
image: carbone/carbone-ee:latest
platform: linux/amd64
ports:
- "4000:4000"
volumes:
- ./plugin:/app/plugin
environment:
- LANG=C.UTF-8
- AZURE_STORAGE_ACCOUNT=STORAGE_ACCOUNT_NAME
- AZURE_STORAGE_KEY=STORAGE_ACCOUNT_KEY
- CONTAINER_TEMPLATES=STORAGE_CONTAINER_TEMPLATES
- CONTAINER_RENDERS=STORAGE_RENDERS_CONTAINERFinally start the Carbone Server, and the following logs will appear. If the connection fails or something goes wrong, an error message will be logged.