How to create and manage multiple sites in AnQiCMS to achieve independent content display?

Calendar 👁️ 66

AnQiCMS is an efficient enterprise-level content management system, and its multi-site management function is undoubtedly an important tool for many enterprises and operators to improve efficiency and segment the market.By creating and managing multiple independent sites under an AnQiCMS instance, we can flexibly provide customized content display and services for users of different brands, business lines, or regions.

Understand the core concept of multi-site management in AnQiCMS

AnQiCMS multi-site management is not simply copying multiple systems, but ratherUnder a unified AnQiCMS backend framework, run and manage multiple logically independent websitesThis means that, although you have only installed one set of AnQiCMS program, but through clever configuration, it can intelligently display the independent content, style, and even background management permissions of the corresponding site according to the domain name visited by the user.The core advantage of this model lies in its significant reduction in operation and maintenance costs and repetitive work, while also ensuring a high degree of independence in the presentation of each site on the front end.

Imagine that you might need a corporate website, a product showcase site, and a blog, all serving the same company, but with different content focuses and target audiences.Take advantage of the multi-site feature of AnQiCMS, you can easily meet all these needs on a single platform, each site has its own database, administrator account, content model, and template, and the content between them does not interfere with each other, making management centralized and efficient.

Deployment basis: Allow AnQiCMS instances to support multi-site operation

Implement the independent display of multi-site AnQiCMS, first you need to ensure that your AnQiCMS instance can respond to requests from different domain names. Normally, an AnQiCMS instance will listen on a specific port (such as the default one, 80 or 443).8001To allow different domains to access this AnQiCMS instance and distribute it to their respective logical sites, we need to make use ofReverse Proxytechnology.

Reverse proxy servers (such as Nginx, Apache, etc.) play the role of a "traffic scheduler".It will forward the request to the port listened by the AnQiCMS instance based on the domain name visited by the user.No matter how many site domain names you have, they will all be pointed to by reverse proxyThe same AnQiCMS running portThis means you only need to maintain one AnQiCMS core program, without the need to install a separate one for each site.

For example, if you use Baota panel or 1Panel and other tools to deploy AnQiCMS, you need to set up a reverse proxy for the core service of AnQiCMS so that it can be accessed through such as127.0.0.1:8001This address is accessed. All subsequent newly created site domains will be directed to this through their respective reverse proxy configurations127.0.0.1:8001.

Create a new independent site in the AnQiCMS backend

After the basic deployment is completed, you can officially create a new site in the AnQiCMS backend. This process is intuitive and flexible, simply log in to the backend of the AnQiCMS site you initially installed (usually referred to as the "master site" or "default site"), then:

  1. Find and click in the left navigation menu“Multi-site management”Feature.
  2. Click after entering the multi-site management page“Add new site”button.

At this time, the system will pop up a form, where you need to fill in key information for the new site:

  • Site Name:This is the name used for background management and identification, you can name it according to your business needs, such as "Product Show Site", "Company Blog", etc.
  • Site root directory:This is a very important setting that determines the physical storage path of independent files for the new site (such as cache, uploaded files, etc.). It is recommended that/app/Start (if you are deploying in a Docker environment), followed by replacing the dot with an underscore in the domain name, for example/app/dev_anqicms_com.Make sure that the root directory of each site is unique to avoid data confusion or conflicts.
  • Website address:Enter the complete access URL of the new site, for examplehttp://dev.anqicms.comThis URL must be resolved to the domain name of your server.
  • Admin account password:Set an independent admin account and password for the new site. This means that each sub-site can have an independent administrator team and permissions, achieving fine-grained management.
  • Database name:Similarly, this also reflects the independence of the content data of the new site. It is recommended to use naming conventions similar to the site root directory, for exampledev_anqicms_comEnsure each site has an independent database, with content that does not interfere with each other.
  • Database information reuse: If your database account has sufficient privileges (such as reusing the default root account information when deploying Docker), you can choose to reuse the default database account information to simplify configuration.
  • Select the template to use:You can choose a preset template for the new site, or upload a customized template to give each site a unique visual style and layout.

Fill in and confirm this information, and AnQiCMS will create a brand new, logically independent site for you.

Configure reverse proxy for the new site to enable access

After the new site is created successfully in the AnQiCMS background, although the content and database have been independent, users cannot access it directly through the domain name. This requires going back to your server management panel (such as Baota panel, 1Panel, etc.) to configure the domain name for the new siteReverse Proxy:

  1. Create a new website in the panel, enter the domain you set for the new sitewebsite addressfor exampledev.anqicms.com)

  2. For panels like Baota that need to be specifiedRunning directoryPlease set the run directory to the root directory specified when the site was created./publicfolder (for example/www/wwwroot/dev.anqicms.com/public), and save the configuration. This step ensures that static resources can be accessed correctly.

  3. ConfigurationReverse proxy rulesThis is the most critical step, you need to forward all requests to the new domain name through reverse proxy to the unified port that the AnQiCMS instance is listening to (for examplehttps://en.anqicms.com)。An example of a specific Nginx configuration might look like this:

    location @AnqiCMS {
        proxy_pass https://en.anqicms.com;
        proxy_set_header   Host             $host;
        proxy_set_header   X-Real-IP        $remote_addr;
        proxy_set_header   X-Forwarded-For  $proxy_add_x_forwarded_for;
    }
    error_page 404 =200  @AnqiCMS;
    location / {
       try_files $uri $uri/index.html @AnqiCMS;
    }
    

    This configuration will try to find static files first, and if not found, it will proxy the request to the AnQiCMS instance。

Configure reverse proxy and restart your web server (Nginx/Apache) and then you can access the new domain from the front end and manage the new site. Each site will have an independent backend login entry (such ashttp://dev.anqicms.com/system/)

Related articles

What template file types and organization modes does AnQiCMS support to control the display of the page?

## AnQiCMS template files and organization methods: The secret to flexible control of page display In the digital age, the visual presentation and content layout of a website are the core of attracting users and conveying information.An excellent content management system should also provide highly flexible page display control capabilities, in addition to powerful content management functions.AnQiCMS is designed based on such an idea, it not only makes content publishing efficient, but also gives users the powerful ability to customize the appearance of the website at will through its unique template file type and organizational mode.

2025-11-07

How to use AnQiCMS template tags to flexibly display different types of content?

AnQiCMS as an efficient and flexible content management system, its template tag system is the key to our website content operation and display.It provides a set of intuitive and powerful tools that allow us to present the content of the backend management in various styles according to different scenarios and needs, thereby greatly enhancing the flexibility and user experience of the website.

2025-11-07

How to customize the display layout of the website page in AnQiCMS?

AnQiCMS provides very flexible and powerful custom layout capabilities for website pages.Whether you want to quickly build a corporate website with a unique style or need to finely operate multi-site content, AnQiCMS can give you complete control over the 'skeleton' to 'flesh' of the website.### Core Concept: Comprehensive Control from Skeleton to Detail The customization ability of AnQiCMS is mainly reflected in the use of the Django template engine syntax, which is natural and smooth, easy to learn, even if you are not a professional backend developer

2025-11-07

How to use the timed publishing feature in AnQiCMS to accurately

Today, in the increasingly refined field of content marketing, both the quality of the content and the timing of its dissemination are equally important.A well-crafted content, if released at an inappropriate time, may not achieve the expected communication effect.AnQiCMS is an efficient management system designed specifically for content operators, deeply understanding this field, and its built-in scheduling publication function is the key tool to help us accurately grasp the 'golden moment' of content marketing.The core concept of the scheduled publishing function is to make content going online no longer limited by manual operation time.

2025-11-07

How does AnQiCMS handle images in document content to optimize front-end display (e.g., Webp, compression)?

Images are an indispensable part of website content, they can make the page more attractive and convey richer information.However, if images are not optimized, the large file size often leads to slow website loading, severely affecting user experience and search engine rankings.AnQiCMS provides a series of powerful optimization functions when processing images in document content, helping us easily cope with these challenges to ensure that the front-end display is both beautiful and efficient.

2025-11-07

How to set up independent display templates for AnQiCMS documents or categories?

In website operation, we often encounter such needs: some documents need a unique display method, the article list of a certain category needs a special layout, or a single page needs a unique design.AnQiCMS knows the importance of this personalized demand and provides flexible template settings to easily set independent display templates for documents, categories, and even single pages.This can not only help you better meet the diversity of content display, but also greatly enhance the user experience and the brand image of the website.Why do we need an independent display template?

2025-11-07

How does AnQiCMS optimize the URL structure through pseudo-static rules to improve search engine results display?

In today's digital marketing environment, a website's URL structure is not just an access address, but also a key element for user experience and search engine optimization (SEO).A clear and meaningful URL can enhance user trust and help search engines better understand the content of the page, thereby improving the display and ranking of the website in search results.AnQiCMS (AnQi Content Management System) fully understands this, and therefore its design in the field of pseudostatic rules provides powerful tools for website operators to optimize URL structure and stand out in search engines.

2025-11-07

How to ensure that AnQiCMS multilingual content switches and displays correctly on the front end?

Today, making a website support multilingual switching and display has become an important link for many enterprises to expand into the international market.AnQiCMS with its flexible architecture provides an efficient way to achieve this goal.This article will deeply explore how to configure and manage multilingual content in AnQiCMS, ensuring that they can be correctly switched and displayed on the front-end website, thus providing a high-quality browsing experience for users of different languages.

2025-11-07