2 篇文章带有标签 “apache”

基于Apt-Mirror创建私有Ubuntu存储库

服务端

apt-mirror下载软件包

  1. 安装apt-mirror
sudo apt-get install apt-mirror -y
#修复FAQ1
sudo curl -fsSL https://raw.githubusercontent.com/Stifler6996/apt-mirror/master/apt-mirror > apt-mirror

配置mirror.list sudo nano /etc/apt/mirror.list ############# config ################## set base_path /data/apt-mirror #set mirror_path $base_path/mirror #set skel_path $base_path/skel #set var_path $base_path/var #set cleanscript $var_path/clean.sh #set defaultarch <running host architecture> #set postmirror_script $var_path/postmirror.

Apache HTTP Server实践

修改端口号

  • /etc/apache2/ports.conf
sudo nano /etc/apache2/ports.conf
# If you just change the port or add more ports here, you will likely also
# have to change the VirtualHost statement in
# /etc/apache2/sites-enabled/000-default.conf

Listen 8081
......
......
  • /etc/apache2/sites-enabled/000-default.conf
sudo nano /etc/apache2/sites-enabled/000-default.conf
<VirtualHost *:8081>
......
......
</VirtualHost>
  • 重启服务
sudo systemctl restart apache2

参考资料