Skip to main content

Staging and production

A staging or acceptance copy of a live site, with a cloned database, brings along more of the live site than you might expect: the licence, the saved settings, the idea groups and the schedule. This page lists what to change on a copy, and what to set per environment.

Switch off the monthly idea job on a copy​

The monthly ideas job runs wherever the licence allows it, and that includes a copy with a cloned database. On the copy it writes pages too, and, when the copy has an OpenAI key, makes real AI calls. Switch off Monthly idea job on in the group Idea generator on every copy that is not the live site. The Auto generate button keeps working, because someone presses it on purpose. The steps are under Staging and test copies.

A value saved on the Settings tab is stored in the database and wins over your configuration. A cloned database therefore also brings the value from the live site. Check the Settings tab of the copy after each clone, even when you switched the job off with an environment variable.

Give each environment its own settings​

  • Public URL. In the setup wizard, the field Public URL is the address Aivie reports to the licence server when it renews the licence. Use the real address of each environment. On a live site it must not be localhost or another address of the machine itself: the licence is then not renewed, and it runs out after 35 days. A copy that runs in the ASP.NET Development environment does not renew the licence at all. See Required fields.
  • OpenAI key. The wizard writes the key to appsettings.{Environment}.json, a file per environment name. A copy that runs under another environment name reads another file, so run the wizard there, or set the key as an environment variable. We recommend a separate OpenAI key, or a separate project at OpenAI, for each environment, so that the costs and limits of the copy do not mix with those of the live site. See What the wizard writes to appsettings.
  • Data Protection keys. We recommend pinning Data Protection on every environment, each with a key folder of its own that is part of that environment's backups. A cloned database holds values that were encrypted with the key ring of the live site, and a copy with another key ring cannot read them. That affects a key you typed into an Umbraco.AI connection yourself; the key the wizard wrote is not affected. On the copy, type such a key in again, and do not press Save on a value that shows as unreadable. See Pin Data Protection and API key unreadable after a move.

The licence is tied to the domain​

Aivie checks the licence key against the host name you use. A copy on another domain than the one on the licence gets the status Different domain and is read-only for the people who open it. The box Registered licences on the licence screen lists the licensed domains. If you need to work in Aivie on a staging domain, that domain must be among them. See Licence statuses.

The trial is meant for your own machine only. It runs on a local host name when the request comes from the same machine, without a reverse proxy. A staging site on a .test name that you open from another computer gets no trial. See Trial on local hosts.

Checklist for a new copy​

  1. Switch off Monthly idea job on on the copy, and check the Settings tab afterwards.
  2. Set the public URL of the copy to its own address.
  3. Give the copy its own OpenAI key, and its own Data Protection key folder.
  4. Check which domain the licence covers.
  5. Open the licence screen on the copy and check its status.