Ready to install the Tenant SDK? This article will guide you through the process.
The following Azure resources are created during the installation:
A Resource group containing:
- A Storage account
- A SQL Server instance
- A SQL Database
- An App Service Plan
- An App Service (web site)
If you configure the Tenant SDK to use a custom domain, these resources will also be created:
- A DNS Zone
- A Certificate
The following changes will be made to the subscription:
- Registration of the following resource providers:
Microsoft.Web, Microsoft.Sql, Microsoft.Storage
- A service principal will be created with contributor access to the subscription, which will be userd by the Tenant SDK to manage your tenants and other resources.
The SQL Server and App Service Plan that are created will also contain the Web apps and SQL databases for the Weavy tenants you deploy using the Tenant SDK (until the total number of resources reaches a threshold, which will trigger the creation of a new App Service plan and SQL Server).
It is recommended that you configure the backup retention policy by specifying the Azure SQL Backup Settings when you install the Tenant SDK.
Soft delete for Azure Storage Accounts is controlled by configuring the
There are a few steps that needs to be taken before installing the Tenant SDK.
You need the specifics of an SMTP server for sending emails from the Tenant Dashboard as well as from your deployed Weavy tenants.
If you currently don’t have a publicly available server, there are plenty of email services to choose
from (Amazon SES , SendGrid etc.).
Obtain the settings you need to send emails using an SMTP server and have have them ready for when you configure the mail settings of the Tenant SDK.
Decide if you want to configure a custom domain for the Weavy tenants you deploy. If you don’t configure a custom domain, the tenant you deploy will be accessible on the
You need to have or purchase a domain for the tenants you deploy, for example company.com. The deployed sites will then be configured as subdomains with hostname <unique-name>.company.com.
If you are using custom domain you need to decide on one of the methods descibed below before moving forward. Otherwise skip this step.
App Service Managed Certificate
Microsoft Azure can create SSL certificats that are managed and maintained by App Service. With this approach it is not necessary to purchase your own certificate.
CustomDomain, but make sure
SslCertificatePassword is blank to use App Servcie Managed Certificates.
Purchased SSL Wildcard Certificate
You need a SSL wildcard certificate for that domain (*.company.com) in the form of an pfx file with a private key.
Name the file
Use the Upload/download functionality of the Azure Cloud Shell to upload the file
custom-domain.pfxto your mounted drive.
You need to Specify both the
CustomDomain and the
SslCertificatePassword for your .pfx file in order to configure the Tenant SDK to use your wildcard certificate.
Before you install, you need to configure some settings. See the configuration documentation for a complete list of the configuration settings and their meaning.
Log in to your Azure Portal and open the Azure Cloud Shell (see screenshot below).
If you have not used the Azure Cloud Shell before, you will be prompted to create a new Azure file share for persisting files.
Maximize the window and select
Bash in the shell language selector.
Execute the following lines in the terminal:
curl https://weavy.blob.core.windows.net/releases/wdm/config.sh > config.sh
This downloads a configuration template file and launches Visual Studio Code.
Referencing the configuration documentation, enter the appropriate values for the settings defined in the configuration file.
The section called resource names lets you configure the names of some of the deployed resources. Do not remove the variable
Prefix when a resource name contains it.
When you are done, save the file ctrl+s and close the editor ctrl+q.
ls command and make sure the following files are listed:
- custom-domain.pfx (if you are using a custom domain)
Execute the following line to set
execute permissions for the
chmod +x ./config.sh
Then execute the script file by issuing:
The deployment will commence after initial validation of the settings you provided. If you encounter any validation errors - go back and update the config file by executing the following command again:
Don’t forget to save the file (as described earlier) before executing the script again.
If the deployment fails, you will get an option to remove the resources. Please make sure you do that before attempting to deploy again.
Post deployment steps
If you opted to use a custom domain, you will see the nameservers you need to configure in your DNS in order to delegate your DNS zone to Azure DNS.
Feel free to manually add a custom domain for your Dashboard. If you do, please update the value for
ApplicationUrl in the
AppSettings for the Dashboard instance.
The configuration settings are saved as
AppSettings on the deployed App Service and can later on be changed by navigating to the Wep App (App Service) in your Azure portal.
Head over to the Builds page and create your first build.