How to install and manage multiple AnQiCMS sites on the same server?

Calendar 👁️ 57

AnQiCMS is an efficient and flexible content management system, and its multi-site management function is designed to meet the needs of small and medium-sized enterprises, self-media operators, and users with multiple brands or content branches.As a senior website operations manager, I am well aware of the importance of efficiently managing multiple sites on the same server, which not only saves server resources but also simplifies daily maintenance work.Below, I will elaborate on how to install and manage multiple AnQiCMS sites on the same server.

Understanding the multi-site management mechanism of AnQiCMS

The multi-site management feature of AnQiCMS lies in allowing a single AnQiCMS application instance to manage and present multiple independent website contents by distinguishing different domain names.This means you do not need to deploy a complete AnQiCMS code and runtime environment for each site, just run one main AnQiCMS application and add and configure additional sites through its backend interface.Each new site will have an independent database, file storage directory, and management backend, but they share the same performance and features of the AnQiCMS core application.This design greatly improves resource utilization and management efficiency.

Preparation work

Before starting the installation and configuration of multiple AnQiCMS sites, please ensure that your server meets the following basic requirements:

First, prepare the independent domain names for all sites and resolve them correctly to your server IP address.Secondly, ensure that MySQL database is installed on your server and you have sufficient permissions to create new databases and users.If you use Docker for deployment, please make sure that the Docker environment is ready.Finally, you need to deploy a web server such as Nginx or Apache as a reverse proxy for AnQiCMS so that you can access your site through a domain name instead of a port.

Deploy the main AnQiCMS application

The first step in managing multiple sites is to deploy a main AnQiCMS application instance.This instance will carry the core logic of all sites.It is recommended to use Docker for deployment as it has good isolation and is easy to deploy.

For example, using Baota Panel or 1Panel, you can install AnQiCMS in Docker version from the app store.During the installation process, you need to specify a domain name and port (for example, 8001).This main application is deployed, and you will get the first AnQiCMS site.Please record the MySQL root password, as it may be needed when creating new sites later, especially in cases where database information is reused in Docker environments.

If you choose to manually deploy AnQiCMS as a Go project or install it via the command line, the process is similar: download the AnQiCMS Linux installation package, unzip it, configure it to run as a daemon, and make sure Nginx or Apache is configured with reverse proxy, forwarding external domain requests to the port that AnQiCMS is listening on.

Add a new site in AnQiCMS backend

After the main AnQiCMS application runs successfully and is accessible, you can log in to its backend to add a new site.

Log in to the administration backend of your first AnQiCMS site (usually您的主域名/system/)。Find and click the "Multi-site Management" feature in the left menu.Next, click the "Add new site" button, and you will see a configuration form that requires you to fill in the details of the new site.

Here, the 'site name' can be filled in according to your actual needs, used for background distinction; 'Site root directory' is a very critical configuration, it must be unique, used for independent storage of new site cache, uploaded files and other data. For example, if you use Docker, you can fill in/app/新站点域名_com(Replace the dots in the domain name with underscores); If it is a Baota panel environment, it is recommended to create a new website directory, such as/www/wwwroot/newsite.com.

Enter the full domain name of the new site, for examplehttp://newsite.com.“Admin account” and “Admin password” are the independent backend login credentials of the new site.newsite_com.If you are installing in a Docker environment and the main application and the new site share the same MySQL service, you can choose "database information reuse", so you do not need to re-enter the database username and password.Finally, select the template you want to use for your new site and click “OK” to complete the creation of the new site.

Configure Web Server Reverse Proxy

After creating a new site in the AnQiCMS backend, the web server (such as Nginx or Apache) also needs to be properly configured in order to correctly forward new domain requests to the running AnQiCMS application.

For example, using Baota panel, if you are using Docker deployment, you just need to add a reverse proxy site for each new domain in the "Websitehttps://en.anqicms.comPlease note that all new site reverse proxies should point to the same port of the AnQiCMS application instance.

If you are deploying a Go project on the Baota panel instead of Docker, the steps to create a reverse proxy for each new site will be different. You may need to create a "PHP project" and set the root directory of/www/wwwroot/newsite.com/publicThen manually configure the Nginx pseudo-static rules to reverse proxy requests to the port that AnQiCMS is listening on. Specific pseudo-static rule examples are ininstall.mdThe document mentions, usually containsproxy_pass https://en.anqicms.com;Wait for instructions. For Apache servers, you need to configure virtual hosts and forward requests through the proxy module to the AnQiCMS port.

After completing the reverse proxy configuration, you can enter the new site domain in the browser to access and perform the initial setup or directly use the pre-configured site content. Each site will have an independent management backend, through新站点域名/system/Access is available.

Summary

The multi-site management feature of AnQiCMS provides users with an efficient and convenient solution by sharing the core application, independent data storage, and flexible Web server reverse proxy configuration.It greatly simplifies the complexity of multi-site deployment and daily maintenance, allowing you to focus on high-quality content creation and operation, thereby better attracting and retaining users.

Frequently Asked Questions (FAQ)

1. Why are the 'Site Root Directory' and 'Database Name' different in multi-site management?

The site root directory is used to store independent file resources for each site, such as cache, uploaded images, attachments, etc.Ensure each site has an independent root directory to prevent file conflicts and facilitate independent backup or migration of sites.The database name is used to store all the data for each site, including articles, categories, users, etc.Different database names can ensure that data at each site does not interfere with each other, improving data security and management independence.

2. Can I run multiple completely independent AnQiCMS applications on a single server?

Yes, this is technically feasible. You can copy the codebase and configure different ports for each copy (for example, inconfig.jsonModify the port field and set up an independent startup script and reverse proxy for each replica.In this way, each AnQiCMS application is an independent instance with no association between them.

Related articles

How to configure Nginx rewrite rules when installing AnQiCMS on the Baota panel?

The AnQiCMS content management system is increasingly becoming the preferred tool for small and medium-sized enterprises and content operation teams due to its efficient features based on the Go language and its SEO-friendly design concept.As an old veteran who has been deeply involved in website operation for many years, I fully understand the importance of high-quality content and excellent user experience, and the elegant URL structure is the key to improving these experiences.The built-in pseudo-static feature of AnQiCMS is exactly what is needed to achieve this goal.

2025-11-06

How to use Baota panel to install AnQiCMS on a Linux server?

As an experienced security CMS website operator, I know that the deployment of the content management system is the foundation of successful operation.AnQiCMS with its high performance, security, and ease of use based on the Go language, has become the ideal choice for many small and medium-sized enterprises and content operation teams.Install AnQiCMS on a Linux server using the Baota panel can greatly simplify the deployment process, allowing you to quickly get involved in content creation and operation.This article will introduce you in detail how to easily install and configure AnQiCMS on a Linux server using the Docker feature of Baota panel

2025-11-06

What website adaptation modes does AnQiCMS support (Adaptive, Code Adaptation, PC+Mobile)?

As an experienced website operator who understands the operation of AnQiCMS, I know the importance of content presentation in attracting and retaining users.AnQiCMS offers a variety of flexible options in website adaptation mode to help operators build efficient and user-friendly websites according to the target audience and business needs.Below, I will elaborate on the several main website adaptation modes supported by AnQiCMS.AnQiCMS provides adaptive, code adaptation, and PC+Mobile independent site three core modes when handling website visits on different devices

2025-11-06

Does AnQiCMS template engine support syntax similar to Django or Blade?

As an experienced website operator who deeply understands the operation of AnQiCMS, I know the importance of template engines in content presentation and website customization.A highly efficient and easy-to-use template syntax that can greatly enhance the efficiency of content publishing and site optimization.In response to your question about whether AnQiCMS template engine supports syntax similar to Django or Blade, I will give you a detailed explanation.

2025-11-06

How to test and run AnQiCMS program under Windows environment?

As an experienced CMS website operator, I am well aware of the importance of efficiently testing and running CMS programs in a local environment, especially on Windows systems, for content creation and optimization processes.AnQiCMS is a system developed based on the Go language, with its lightweight and efficient characteristics, the deployment and testing in the Windows environment are also relatively convenient.Below, I will explain in detail how to test and run the AnQiCMS program in the Windows environment

2025-11-06

How to solve the error 'Port is already in use' when deploying AnQiCMS?

As an experienced CMS website operation personnel, I know that technical details often determine whether the operation is smooth or not.Among them, 'Port occupied' is a common initial problem when deploying applications like AnQiCMS that run based on a specific port.But please be assured, this is not a difficult problem to solve. Just understand its principles and follow the steps, and you can easily resolve it.### Understanding Port Occupation Error If the system prompts the error message "Port is already in use" when you try to start the AnQiCMS service

2025-11-06

What are the core function modules provided by the AnQiCMS backend?

As an experienced website operator, I have a deep understanding and practical experience of the powerful functions of AnQiCMS.This is an enterprise-level content management system developed based on the Go language, which provides a comprehensive solution for small and medium-sized enterprises, self-media operators, and multi-site management users with its efficient, customizable, and scalable features.It not only simplifies the content management process, but also helps the website stand out in the highly competitive digital environment through a series of refined functions.The core functional module of AnQiCMS backend, aiming to cover all aspects of website operation, from content creation to publishing

2025-11-06

How to set global functions, content, and contact information in the AnQiCMS background?

As an experienced CMS website operation person in the security industry, I am fully aware that the background settings are crucial for the overall operation efficiency and user experience of the website.Efficiently manage global functions, content processing, and external communication methods, which is the foundation to ensure the stable operation of the website, high-quality presentation of content, and effective engagement with users.Below, I will give you a detailed explanation of how to perform these key settings in the AnQiCMS backend.### Website Global Function Settings Global function settings are the 'master switch' of the AnQiCMS website, affecting every aspect of the site, from brand identity to access status, to multilingual support

2025-11-06