How to quickly view the root directory path of the current AnQiCMS installation?
As an experienced website operations expert, I know that clearly understanding the file structure and key paths of the AnQiCMS website is very important when managing and maintaining it.Especially when adjusting configurations, modifying templates, troubleshooting, or managing multiple sites, quickly locating the installation root directory path of AnQiCMS can greatly improve our work efficiency.
AnQiCMS is a modern content management system developed based on the Go language, with flexible and diverse deployment methods, ranging from running directly on the server, to managing through panels such as Baota, 1Panel, and even containerized deployment, the strategies for finding the root directory path under each method are different.Next, I will give you a detailed explanation of how to quickly and accurately view the installation root directory path of AnQiCMS according to different deployment environments.
The environment for direct installation and operation (Linux/Windows/macOS)
If you are downloading the AnQiCMS installation package directly to the server or local machine and extracting it to run, then finding the root directory path will be relatively straightforward.
In this case, the root directory of AnQiCMS installation is usually the folder where you extracted the installation package.In this folder, you will see some iconic files and directories that together constitute the core of AnQiCMS.The core identifier is the executable file of AnQiCMS itself (usually on Linux or macOS)anqicmsIn Windows it isanqicms.exe)
In addition, you will find several important files and directories:
config.jsonThis is the AnQiCMS configuration file, which includes port, database, and other key settings.template/Directory: stores website template files.public/Directory: stores static resources such as CSS, JS, images, etc.start.shandstop.sh(Linux/macOS): Used to start and stop the AnQiCMS service script file, these scripts often clearly define the AnQiCMS runtime path (BINPATH)
Therefore, if your AnQiCMS is installed directly on/www/wwwroot/anqicms.com/Under the directory, this directory is the installation root directory of AnQiCMS. You just need to navigate to the directory containing these files through the file manager or command line.
Through Baota/1Panel and other panels managed environment
For users who deploy AnQiCMS through integrated management tools such as Baota panel or 1Panel, locating the root directory path requires the use of the panel's management interface.
If you have installed AnQiCMS through the 'Go project' or 'General project' in the Baota panel:You can log in to the Baota panel, click the 'Website' menu on the left, and then select 'Go Project' (or 'Other Project').Here, you will see the list of AnQiCMS projects you have deployed.Click on the 'Settings' or 'Details' of the corresponding item, it will usually display the path of the 'project executable file', for example/www/wwwroot/yourdomain.com/anqicmsThe directory where the executable file is located, i.e./www/wwwroot/yourdomain.com/It is the root directory path of AnQiCMS. It is often directly pointed out when executing commands.
If you are deploying AnQiCMS via Docker on Baota Panel or 1Panel:This situation is a bit complicated because it involves container isolation.Under Docker deployment, the AnQiCMS application itself runs inside the container, and the root directory path is fixed inside the container.According to the AnQiCMS Docker deployment document, the default root directory inside the container is/app/.
For example, if you create a new site in the multi-site management of AnQiCMS, the recommended format for the "site root directory" is/app/your_domain_underscored. This means inside the Docker container,anqicmsThe executable file and its related configuration files and directories are located/app/below.
To view the actual path mapped by the Docker container on the host machine, you may need to log in to the host machine and usedocker inspect <容器ID或名称>command to view the container details, especially itsMounts(Mount point) part, to determine which path on the host machine is mapped to the container's/apppath. However, for daily operations, it is important to understand the internal structure of the container's/appAs the root directory of its application is usually sufficient.
3. General troubleshooting and verification methods
If the above methods still cannot determine, or if you want to further verify, you can try the following general troubleshooting techniques:
- Search
config.jsonFile:No matter how AnQiCMS is deployed,config.jsonfiles usually exist in the root directory of their application. Log in to your server using SSH tofind / -name "config.json"Command (it may take some time) to search for the file. Once found,config.jsonthe directory where it is located is the installation root directory of AnQiCMS. - Check the startup script or runtime log:If you have permission to access the server, you can view the script file to start AnQiCMS (such as
start.sh)or its generated log files. These files often contain path information at program startup. For example,“start.shdefined inBINPATHA variable explicitly indicates the path of the executable file, which is the root directory. - Check the running process:On a Linux server, you can use
ps -ef | grep anqicmsThe command to view the running process of the AnQiCMS program. The process information usually displays the full path of the executable file, for example/www/wwwroot/anqicms.com/anqicmsThis directly reveals its root directory.
Define the root directory path of AnQiCMS, which is the foundation for your efficient website management.This core information is indispensable for modifying configurations, debugging templates, or troubleshooting.Hope these detailed instructions can help you in