2

I am trying to migrate my local dev environment to a staging site, but am receiving You’re running Craft Pro with a Craft Personal license.

Initially I tried access the admin at http://project.staging.company.com/ where I received the upgrade message. After emptying all caches, I then tried accessing from http://staging.project.company.com and still get the upgrade message.

Looking at this answer I assumed Craft would recognise this as a "dev-sounding" domain.

Is this still the case? What do I need to go to get this working on staging?

At this stage I am not sure what will be the final domain, so I was hoping not to purchase the licence until we were ready to go live.

5

As Luke referenced in his answer, you're mixing up two separate (but related) concepts.

Craft License

Your license key is stored in your craft/config/license.key file. This file is automatically generated the first time you run Craft, and should always remain a part of your website. If you're using version control, make sure that it's included in your repo.

Craft Edition

The "edition" of your website refers to which version you're using: Free, Client, or Pro.

Whichever edition you are currently using will be stored in your database for immediate reference... However, your site will frequently ping Pixel & Tonic's servers to ensure that it's using the correct edition. While your license key does not directly contain which edition you should be using, it let's P&T's servers know which website is performing the request, and replies back with the proper edition information.

How it relates to your situation...

Using a "dev-sounding" domain name only does one thing:

  1. You can share the same license key file between domains without getting a warning message at the top of each page.

The P&T servers will associate your license with only the non-dev-sounding domain... any dev-sounding domains will not be recording with your license key data. So if you try to use the same license key file on multiple non-dev-sounding domains, all but one will display this message:

The license located at config/license.key belongs to [OTHER DOMAIN]. Transfer it to this domain?

In regards to your edition... As long as they're sharing the same license, every environment for your site will share the same edition.

As Luke mentioned, when developing a site in your local environment, you can set the local path to end with craft.dev. This is considered a very special circumstance... Craft will recognize this special domain and allow you to upgrade your edition for free!

Of course, since that special domain is only available locally, you'll be expected to properly purchase your edition when you move your site to any other domain name (regardless of whether it's "dev-sounding").

Again, Luke's solution is correct... Purchase the license now, and don't worry about what the final domain will be. It's not relevant. Switching your license to the correct domain is incredibly easy and painless, and happens with a single click.

UPDATE:

It's now possible to try Craft Pro from any non-public domain:

http://pixelandtonic.com/blog/test-craft-client-pro-from-any-non-public-domain

| improve this answer | |
3

The only way to stop the message appearing is using a domain ending in craft.dev

As long as your client doesn't mind seeing the message it is not a big issue.

Also, licences can easily be moved to a different domain when you go live. Purchase the licence now and when you access the cp from the live domain in production, simple click the 'transfer licence to this domain' button at the top.

| improve this answer | |
  • If I have a pro license, does this allow access to a staging url and a live url simultaneously? – ifunk Mar 23 '15 at 11:18
  • As long as you have the licence key file in both locations yes - you will just get a message at the top. – Luke Holder Mar 23 '15 at 11:59
2

Found your question while troubleshooting a similar issue (setting up a dev subdomain after getting the pro license for a live site). We share a codebase across multiple domains, each with their own license key, so the keys are ignored in version control.

mysite.com was used to generate /craft/config/license.key. As noted in the other answers, you could also generate this key on another domain and transfer it later.

Without the license.key if you visit the admin control panel on your dev sounding subdomains (or local installs), a personal license will be generated and (if you've got pro features) the modal will pop up and lock you out of the cp.

After copying the pro license.key file from the live site, I still had to clear out /craft/storage/runtime/cache/ before clicking the "check for updates" link in the cp footer to force a call to craft's web services.

Back in business.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.