web - ubuntu下apache2.4配置多站點(diǎn)問(wèn)題
問(wèn)題描述
在apache2.4下配置了如下代碼文件但是apache報(bào)錯(cuò)(另外網(wǎng)上教程說(shuō)綁定host文件,我并不知道這是什么東西。。)
配置部分代碼如下apache2.confInclude the virtual host configurations:IncludeOptional sites-enabled/*.confNameVirtualHost smilencer.me<VirtualHost 138.68.12.160:80>
ServerName www.smilencer.meDocumentRoot '/var/www/wordpress' <Directory '/var/www/wordpress'> Options FollowSymLinks AllowOverride All Require all granted
</Directory> </VirtualHost> <VirtualHost 138.68.12.160:80>
ServerName www.whatare.meDocumentRoot '/var/www/What_Are_You_Doing/map'
<Directory '/var/www/What_Are_You_Doing/map'>
Options FollowSymLinks AllowOverride All Require all granted
</Directory> </VirtualHost>
NameVirtualHost whatare.me
mytest.conf
問(wèn)題解答
回答1:這里給你一個(gè)參考,你可以用你自己的域名替換掉[YOUR_DOMAIN_NAME]
<VirtualHost *:80> ServerAdmin admin@[YOUR_DOMAIN_NAME].com DocumentRoot '/var/www/dev/doc' ServerName [YOUR_DOMAIN_NAME].com ServerAlias [YOUR_DOMAIN_NAME].com ErrorLog logs/[YOUR_DOMAIN_NAME].com-error_log</VirtualHost>
相關(guān)文章:
1. boot2docker無(wú)法啟動(dòng)2. docker-compose中volumes的問(wèn)題3. 關(guān)docker hub上有些鏡像的tag被標(biāo)記““This image has vulnerabilities””4. java - SSH框架中寫分頁(yè)時(shí)service層中不能注入分頁(yè)類5. nignx - docker內(nèi)nginx 80端口被占用6. docker安裝后出現(xiàn)Cannot connect to the Docker daemon.7. javascript - mock.js可以存儲(chǔ)數(shù)據(jù)嗎8. docker api 開(kāi)發(fā)的端口怎么獲取?9. docker images顯示的鏡像過(guò)多,狗眼被亮瞎了,怎么辦?10. golang - 用IDE看docker源碼時(shí)的小問(wèn)題

網(wǎng)公網(wǎng)安備