November Happy Hour will be moved to Thursday December 5th.

Cannot set LicenseFilePath Epi 12

Vote:
 

Hi,

I'm trying set the path to the license in 12.2.1

I've tried via code:

...

services.Configure<EPiServerFrameworkSection>(options =>
                {
                    options.Licensing.LicenseFilePath = $"./License.Staging.config";
                });

....

I've tried via appSettings.json:

  ...
  "AllowedHosts": "*",
  "EPiServer": {
    "Framework": {
      "licensing": {
        "licenseFilePath": "./License.Staging.config"
      }
 ...

However, the app is still looking at ./License.config

Am I missing anything here?

Thanks in advance

Dan

#269241
Edited, Dec 31, 2021 2:04
Vote:
 

Hi,

Is the relative path you are defined is correct?

Try once again with an absolute path.

#269356
Jan 03, 2022 10:13
Vote:
 

Hi Ravindra,

Thanks for the reply.

I have tried setting an absolute path but I still get the exact same error.

Note, per the error in the image from my original post, it is looking for a file named 'License.config' even though I have configured it to look for a file named 'License.Staging.config'.

So, to me, it looks like I have not configured this correctly or the setting is not being obeyed. 

Can anyone confirm if I am setting this value correctly?

Thanks

Dan

#269401
Jan 03, 2022 23:55
Vote:
 

Seems like you may be using the wrong settings - try this

"EPiServer": {
    "CMS": {
      "LicensePath": {
        "Path": "./License.Staging.config"

#269414
Jan 04, 2022 12:15
Vote:
 

^ That works.

Thanks Muhammad! 

#269426
Jan 04, 2022 21:54
This topic was created over six months ago and has been resolved. If you have a similar question, please create a new topic and refer to this one.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.