首页
留言
Search
1
在Centos7下搭建Socks5代理服务器
1,036 阅读
2
在windows11通过Zip安装Mysql5.7
574 阅读
3
Mysql5.7开放远程登录
482 阅读
4
数据库
469 阅读
5
mysql5.7基本命令
377 阅读
综合
正则表达式
git
系统
centos7
ubuntu
kali
Debian
网络
socks5
wireguard
运维
docker
hadoop
kubernetes
hive
openstack
ElasticSearch
ansible
前端
三剑客
Python
Python3
selenium
Flask
PHP
PHP基础
ThinkPHP
游戏
我的世界
算法
递归
排序
查找
软件
ide
Xshell
vim
PicGo
Typora
云盘
安全
靶场
reverse
Java
JavaSE
Spring
MyBatis
C++
QT
数据库
mysql
登录
Search
标签搜索
java
centos7
linux
centos
html5
JavaScript
php
css3
mysql
spring
mysql5.7
linux全栈
ubuntu
BeanFactory
SpringBean
python
python3
ApplicationContext
kali
mysql8.0
我亏一点
累计撰写
139
篇文章
累计收到
8
条评论
首页
栏目
综合
正则表达式
git
系统
centos7
ubuntu
kali
Debian
网络
socks5
wireguard
运维
docker
hadoop
kubernetes
hive
openstack
ElasticSearch
ansible
前端
三剑客
Python
Python3
selenium
Flask
PHP
PHP基础
ThinkPHP
游戏
我的世界
算法
递归
排序
查找
软件
ide
Xshell
vim
PicGo
Typora
云盘
安全
靶场
reverse
Java
JavaSE
Spring
MyBatis
C++
QT
数据库
mysql
页面
留言
搜索到
2
篇与
httpd
的结果
2023-03-20
CentOS7 搭建http的yum源
CentOS7 搭建http的yum源1. 环境准备永久关闭防火墙[root@yum ~]# systemctl stop firewalld && systemctl disable firewalld Removed symlink /etc/systemd/system/multi-user.target.wants/firewalld.service. Removed symlink /etc/systemd/system/dbus-org.fedoraproject.FirewallD1.service.永久关闭selinux[root@yum ~]# setenforce 0 [root@yum ~]# sed -i 's/enforcing/disabled/g' /etc/selinux/config [root@yum ~]# cat /etc/selinux/config | grep = # SELINUX= can take one of these three values: SELINUX=disabled # SELINUXTYPE= can take one of three values: SELINUXTYPE=targeted 挂载系统镜像源[root@yum ~]# mount -o loop /dev/cdrom /mnt/ [root@yum ~]# mkdir /opt/centos [root@yum ~]# cp -rf /mnt/* /opt/centos/ [root@yum ~]# umount /mnt/备份原有yum源[root@yum ~]# mkdir yumbackup [root@yum ~]# mv /etc/yum.repos.d/* yumbackup/配置centos系统镜像源[root@yum ~]# cat << EOF > /etc/yum.repos.d/yum.repo > [centos] > name=centos > baseurl=file:///opt/centos > gpgcheck=0 > enable=1 > EOF [root@yum ~]# cat /etc/yum.repos.d/yum.repo [centos] name=centos baseurl=file:///opt/centos gpgcheck=0 enable=1 [root@yum ~]# yum clean all Loaded plugins: fastestmirror Cleaning repos: centos [root@yum ~]# yum repolist Loaded plugins: fastestmirror Determining fastest mirrors centos | 3.6 kB 00:00:00 (1/2): centos/group_gz | 153 kB 00:00:00 (2/2): centos/primary_db | 3.3 MB 00:00:00 repo id repo name status centos centos 4,070 repolist: 4,070安装工具yum install -y vim net-tools2.配置http源安装httpyum install -y httpd systemctl restart httpd systemctl enable httpd创建软连接指向源路径[root@yum html]# ln -s /opt/* /var/www/html/删除httpd默认页内容echo "" > /etc/httpd/conf.d/welcome.conf重启httpd服务systemctl restart httpd
2023年03月20日
238 阅读
0 评论
0 点赞
2022-03-04
docker-compose部署LAMP环境(centos7+httpd+mysql5.7+php7.0)
docker-compose部署LAMP环境(centos7+httpd+mysql5.7+php7.0)Dockerfilecentos7+httpd(apache)+php7.0FROM centos:centos7.5.1804 MAINTAINER dao #配置yum源 centos源 RUN rm -rf /etc/yum.repos.d/* && curl -o /etc/yum.repos.d/CentOS-Base.repo https://mirrors.aliyun.com/repo/Centos-7.repo && yum clean all && yum install -y wget vim net-tools #安装Apache和扩展包 RUN yum -y install httpd httpd-manual mod_ssl mod_perl mod_auth_mysql #安装php RUN yum install -y \ https://repo.ius.io/ius-release-el7.rpm \ https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm && \ rpm -Uvh https://mirror.webtatic.com/yum/el7/webtatic-release.rpm --force --nodeps && yum -y install php70w-devel php70w.x86_64 php70w-cli.x86_64 php70w-common.x86_64 php70w-gd.x86_64 php70w-ldap.x86_64 php70w-mbstring.x86_64 php70w-mcrypt.x86_64 php70w-pdo.x86_64 php70w-mysqlnd php70w-fpm php70w-opcache php70w-pecl-redis php70w-pecl-mongodb #编写启动脚本 RUN echo "#!/bin/bash" >> /start.sh && echo "php-fpm -R" >> /start.sh && echo "/usr/sbin/httpd -D FOREGROUND " >> /start.sh && \ chmod 777 /start.sh CMD ["sh", "-c", "source /start.sh"]镜像构建命令docker build -t 镜像名:镜像标签 .docker-compose.yaml文件version: '3.3' services: mariadb: image: mariadb:latest ports: - "3306:3306" restart: always environment: MYSQL_ROOT_PASSWORD: "root" #mysql的root密码 user: root php7.0: build: ./ # 也可以改成 image: 镜像名:镜像标签 user: root restart: always ports: - '80:80' - '443:443' - '9000:9000' - '8888:8888'容器启动命令docker-compose up -d打开服务器ip浏览即可
2022年03月04日
256 阅读
0 评论
1 点赞