Should child sites and sub-sites each have a separate key file, and how should the ownership be calculated when pushing?
In scenarios where link push is performed for multi-site or subdomain, whether each host should have a separate key file or can be shared depends on which level of ownership the key file proves: it proves that 'this host is controlled by you', not 'these sites belong to the same brand'. According to the regulations of the public communication channel, each subdomain is considered an independent host and a separate key file needs to be created and managed for each subdomain, so the answer is to have a separate one for each, and sharing one will fail at the ownership verification step.
Which level does the key file prove?
Before submitting the address, the recipient must confirm that the submitter has the right to represent this host. The mechanism of the key file is to place the credentials on the host so that the validator can read it through the public address: the content of the file matches the key identifier submitted, and the ownership is established. This level of determination occurs at the host level, and it has nothing to do with whether the site content is a set of templates or whether the backend is the same instance. In the brand matrix, ten sites share a set of designs, but still belong to ten host identities separate from each other.
The difference between placing it in the root directory and placing it in a subdirectory.
The rule allows two locations: under the root directory of the website, or in a publicly accessible folder on the same host, which can be read without logging in. The difference lies in the address form generated during verification - when placing in a subdirectory, the submitting side must be able to provide the corresponding path; the manifestation of a wrong path is a verification failure rather than the content being invisible. Public accessibility is a strict requirement: directories that require login, have internal network restrictions, or are blocked by exclusion rules do not meet the requirements. Conversely, this file itself does not contain sensitive content; it is just a proof of ownership and does not need to be treated as confidential material.
Why is the subdomain treated as an independent host
Because the subdomain is treated as an independent crawling object: the host names are different, robots and site-level configurations are read separately, and the index attribution is also calculated separately. The same communication channel is followed, resulting in the result of 'the main station has been verified, and the subdomain still needs to be verified separately.' Different directory-type sites under the same host are different; they share the host identity, and one key file can cover the host.
| Scene | Level of attribution determination | Number of key files |
|---|---|---|
| Directory station under the root domain of the main station | The same host | One that can be covered |
| One subdomain for each brand | Each subdomain has an independent host | Each one is placed separately |
| One independent domain name for each brand | The host is different | Place each one separately and submit them separately |
| Multi-language sites are divided by language according to the path | The same host | One copy is enough |
| The host name of the test environment and production environment is the same | The actual public host is the standard | One copy for the production host |
Store credentials according to the site or host in the multi-site background
Intranet multi-site management supports the management of multiple independent sites, suitable for multi-brand, multi-theme scenarios. When it comes to push configuration, it is recommended to store credentials according to the host dimension and perform mapping according to the site dimension: one site binds its actual external service hostname and key file path. When copying the configuration to other sites, do not bring the old host's credentials along. Common error forms are 'one set of credentials assigned to all sites', which manifests as some sites submitting successfully while subdomain sites continuously fail verification; another type of error is that the key file has been placed in a directory with login protection, resulting in failure to read publicly.
The three checks before going online
Step 1, access the address of each host's key file directly using an unlogged session, confirm that it can be read and the content is consistent with the actual submitted value. Step 2, check that this address has not been excluded by the robots configuration or rewritten by the CDN's cache rules. Step 3, submit a small number of addresses once to see if the归属 verification passes, then scale up in batches. After all three steps have passed, queue up, which saves time compared to checking failure reasons after a full batch submission.
Common questions
Question: Can multiple websites on the same server share a single key file?Answer: Check the hostname. Sites under the same hostname can be covered by path distinction; different hostnames are independent and require their own key files.
Question: Should the key file be placed in the background directory for protection?Answer: No, it must be publicly accessible. There is no point in protecting it, what really needs to be controlled is the authorization and exposure range of the background interface.
Question: What should be done after changing the subdomain naming rules?Answer: Place and submit according to the new hostname, and clean up the old hostname configuration that is no longer in use, to avoid mixed addresses that do not pass verification in the push queue.