https://www.cnblogs.com/shwee/p/9084535.html
摘要:https://www.cnblogs.com/shwee/p/9084535.html
阅读全文
posted @
2019-09-28 21:31
Ruthless
阅读(563)
推荐(0) 编辑
springboot+mybatis实现动态切换数据源
摘要:目前有个需求,需要使用不同的数据源,例如某业务要用A数据源,另一个业务要用B数据源。 如何在spring框架中解决多数据源的问题 使用springboot 整合多数据源 遇到的坑 1、添加依赖 2、application.properties配置文件 3、禁用springboot默认加载数据源配置
阅读全文
posted @
2019-09-27 14:45
Ruthless
阅读(13819)
推荐(0) 编辑
docker-machine命令安装
摘要:$ base=https://github.com/docker/machine/releases/download/v0.16.0 && curl -L $base/docker-machine-$(uname -s)-$(uname -m) >/tmp/docker-machine && sudo mv /tmp/docker-machine /usr/local/bin/docke...
阅读全文
posted @
2019-09-26 15:54
Ruthless
阅读(3625)
推荐(0) 编辑
Docker 安装 RabbitMq
摘要:安装环境 Linux :CentOS Linux release 7.6.1810 (Core) Docker :Server Version: 18.09.6 需求 docker.io/rabbitmq:management 步骤 1、拉取镜像 $ docker pull docker.io/rabbitmq:management 2、创建和启动容器 $ docker run -d ...
阅读全文
posted @
2019-09-26 15:33
Ruthless
阅读(1036)
推荐(0) 编辑
yum 找不到程序,yum更换国内阿里源
摘要:使用百度云服务器,发现百度yum源非常不稳定,果断采用阿里源,操作步骤如下: 一、备份 $ cd /etc/yum.repos.d/ $ mv baidu-bcm.repo baidu-bcm.repo.backup $ mv CentOS-Base.repo CentOS-Base.repo.ba
阅读全文
posted @
2019-09-21 21:59
Ruthless
阅读(1152)
推荐(0) 编辑
CentOS安装etcd和flannel实现Docker跨物理机通信
摘要:1、安装etcd 查看etcd是否启动成功,etcd默认端口为2379$ lsof -i:2379 测试etcd可用性$ etcd --version $ etcdctl mkdir /test$ etcdctl ls / 2、安装flannel$ wget https://github.com/c
阅读全文
posted @
2019-09-19 14:28
Ruthless
阅读(2033)
推荐(1) 编辑
nginx dockerfile安装第三方模块
摘要:# nginx Dockerfile # Version 1.0 # author fendo # Base images 基础镜像 FROM centos:centos7 #FROM hub.c.163.com/netease_comb/centos:7 #安装相关依赖 RUN yum -y update RUN yum -y install gcc gcc-c++ autoconf...
阅读全文
posted @
2019-09-12 17:14
Ruthless
阅读(6400)
推荐(0) 编辑
nginx添加第三方模块,以及启用nginx本身支持的模块
摘要:nginx添加第三方模块,以及启用nginx本身支持的模块 Nginx添加第三方模块
阅读全文
posted @
2019-09-12 17:04
Ruthless
阅读(1393)
推荐(0) 编辑
aa
摘要:gzip on;gzip_min_length 1k;gzip_buffers 4 16k;gzip_http_version 1.0;gzip_comp_level 6;gzip_types text/plain application/javascript application/x-javas
阅读全文
posted @
2019-09-12 16:54
Ruthless
阅读(315)
推荐(0) 编辑
ECS上搭建Docker(CentOS7)
摘要:ECS上搭建Docker(阿里云CentOS7) centos下 yum快速安装maven ## 安装jdk8 yum install -y java-1.8.0-openjdk* ## 安装mavenwget http://repos.fedorapeople.org/repos/dchen/ap
阅读全文
posted @
2019-09-11 11:35
Ruthless
阅读(458)
推荐(0) 编辑
mysql时间戳转日期
摘要:-- 日期字符串转时间戳,10位,数据库存储的是13位 select UNIX_TIMESTAMP('2019-09-01 00:00:00'); -- 时间戳转日期 select FROM_UNIXTIME(1567267200,'%Y-%m-%d %H:%i:%s')
阅读全文
posted @
2019-09-06 16:48
Ruthless
阅读(74395)
推荐(1) 编辑
rsync用法
摘要:前提条件:本机和172.16.93.0配置ssh,进行免密登录 1、基于ssh的rsync远程同步数据(推) 把xinya_web-0.0.1-SNAPSHOT.jar拷贝到172.16.93.0对应的/data/java/jar/xinyar-web目录下 参数说明:-e 'ssh -p 3306
阅读全文
posted @
2019-09-05 17:50
Ruthless
阅读(1282)
推荐(0) 编辑
docker安装mysql8
摘要:docker run --restart=always -d -v /opt/data/conf.d/:/etc/mysql/conf.d/ -v /opt/data/mysql/:/var/lib/mysql -p 3306:3306 --name test-mysql -e MYSQL_ROOT_PASSWORD=xinyar mysql 在/opt/data/conf.d/目录下新建my...
阅读全文
posted @
2019-09-05 17:05
Ruthless
阅读(833)
推荐(0) 编辑
使用Docker安装mysql,挂载外部配置和数据
摘要:1、挂载外部配置和数据安装 mkdir /opt mkdir /opt/mysql mkdir /opt/mysql/conf.d mkdir /opt/mysql/data/ 创建my.cnf配置文件 touch /opt/mysql/my.cnf my.cnf添加如下内容: [mysqld] user=mysql character-set-server=utf8 default_au...
阅读全文
posted @
2019-09-05 14:31
Ruthless
阅读(16283)
推荐(3) 编辑
Centos7通过yum安装jdk8
摘要:1、Centos7通过yum安装jdk8 2、Centos7通过yum安装jdk8
阅读全文
posted @
2019-09-04 15:44
Ruthless
阅读(5664)
推荐(0) 编辑
maven添加本地包命令mvn install:install-file
摘要:mvn install:install-file -DgroupId=com.xinyartech -DartifactId=easyexcel -Dversion=1.1.1 -Dpackaging=jar -Dfile=/root/shell/easyexcel-1.1.1.jar -Dfile:要注册的jar,绝对路径
阅读全文
posted @
2019-09-02 17:58
Ruthless
阅读(44937)
推荐(0) 编辑
Mysql——查看数据库,表占用磁盘大小
摘要:1、查询所有数据库占用磁盘空间大小 select TABLE_SCHEMA, concat(truncate(sum(data_length)/1024/1024,2),' MB') as data_size, concat(truncate(sum(index_length)/1024/1024,2),'MB') as index_size from information_schema.tab
阅读全文
posted @
2019-09-02 15:26
Ruthless
阅读(10621)
推荐(0) 编辑