随笔分类 -  Docker

anything about docker
Docker in Docker版本Gitlab CI Runner配置
摘要:1.构建新的gitlab-runner image,使用如下Dockerfile(ubuntu版本): 2.改变宿主机(centos) /var/run/docker.sock的用户组为root:root 3.启动gitlab-ci-runner 4.将新启动的容器中的gitlab-runner用户 阅读全文

posted @ 2016-12-16 15:23 傻子才悲伤 阅读(3454) 评论(0) 推荐(0)

CentOS 7 修改时间时区
摘要:参考链接 https://chrisjean.com/change-timezone-in-centos/ First, make a backup of the existing localtime file. It’s always good practice to make backups o 阅读全文

posted @ 2016-11-08 11:01 傻子才悲伤 阅读(922) 评论(0) 推荐(0)

Kubernetes Nginx Service发现并访问
摘要:启动nginx service: 查看service状态: 发现只有kubernets service: kubernetes 10.254.0.1 <none> 443/TCP 1d 使用如下命令暴露nginx: 再次查看service状态: 发现nginx service: 参考链接:http: 阅读全文

posted @ 2016-11-03 12:20 傻子才悲伤 阅读(1513) 评论(0) 推荐(0)

Kubernetes Cluster Error Accessing gcr.io
摘要:使用 后查看: 发现处于creating状态,并且报错: (unable to ping registry endpoint https://gcr.io/v0/\nv2 ping attempt failed with error: Get https://gcr.io/v2/:... 原因:gc 阅读全文

posted @ 2016-11-03 12:16 傻子才悲伤 阅读(419) 评论(0) 推荐(0)

ELK远程日志log监控
摘要:Master机器运行命令: Slave中只开启lagstash并将相关log指向主ELK服务器: 启动后logstash会报错,因为默认指向本地的elasticsearch服务,登录到docker更改配置文件: 此时slave的logstash可以正常运行。 添加监控文件: 使用以下命令启动logs 阅读全文

posted @ 2016-10-28 18:28 傻子才悲伤 阅读(1531) 评论(0) 推荐(0)

查看指定docker container的启动命令
摘要:使用开源的runlike工具: $ pip install runlike # run the ubuntu image $ docker run -ti ubuntu bash $ docker ps -a # suppose you get the container ID 1dfff2ba02 阅读全文

posted @ 2016-10-19 14:57 傻子才悲伤 阅读(2645) 评论(0) 推荐(0)

docker0: iptables: No chain/target/match by that name
摘要:在CentOS 7下使用类似nginx之类的web server,启动docker时有时会报以下错误: docker0: iptables: No chain/target/match by that name. 解决方法: service docker restart 重启docker后: ipt 阅读全文

posted @ 2016-09-29 13:49 傻子才悲伤 阅读(10650) 评论(0) 推荐(0)

Gitlab CE Docker Image Too Large to Push
摘要:客户端上传时候显示错误: unauthorized: authentication required 显示错误为: Sep 28 22:12:55 docker4 dockerd: time="2016-09-28T22:12:55.510621993+08:00" level=error msg= 阅读全文

posted @ 2016-09-28 22:40 傻子才悲伤 阅读(767) 评论(0) 推荐(0)

dockerhub unauthorized: authentication required
摘要:上传image时出现错误信息: dockerhub unauthorized: authentication required docker login hub.docker.com 不可以, 需要使用https模式登录: docker login https://hub.docker.com或者直 阅读全文

posted @ 2016-09-26 18:50 傻子才悲伤 阅读(11873) 评论(0) 推荐(0)

CentOS 7安装升级最新版本docker-engine
摘要:注意: 要安装的是docker-engine,不是docker。 下载https://github.com/flasheryu/mirrors 此repo里面的yum.repos.d目录并代替CentOS系统的/etc/yum.repos.d目录。 注意备份原/etc/yum.repos.d目录到/ 阅读全文

posted @ 2016-09-06 18:04 傻子才悲伤 阅读(713) 评论(0) 推荐(0)

Java MongoDB Driver Client 和 MongoDB的 docker compose版本
摘要:见代码库: https://github.com/flasheryu/docker-java-mongodb-driver-compose 使用步骤: docker-compose build docker-compose up 阅读全文

posted @ 2016-08-23 17:11 傻子才悲伤 阅读(244) 评论(0) 推荐(0)

Docker版本Omnibus Gitlab 加Lets Encrypt免费SSL一键搭建
摘要:首先使用下列文件gitlab_run.sh生成LetsEncrypt的certificate。 来源: https://github.com/flasheryu/docker-letsencrypt-nginx-proxy-companion-examples https://github.com/ 阅读全文

posted @ 2016-08-16 18:49 傻子才悲伤 阅读(1406) 评论(0) 推荐(0)

Centos 7 Docker配置secure remote api
摘要:log查看: 证书生成参考: https://docs.docker.com/engine/security/https/ 运行命令重启docker: 客户端访问方法: 阅读全文

posted @ 2016-08-08 17:50 傻子才悲伤 阅读(890) 评论(0) 推荐(0)

Omnibus Gitlab安装container registry报错
摘要:按照http://docs.gitlab.com/ce/administration/container_registry.html#container-registry-domain-configuration 官方文档配置gitlab.rb,结果报错: Recipe: gitlab::defau 阅读全文

posted @ 2016-08-08 13:28 傻子才悲伤 阅读(2790) 评论(0) 推荐(0)

Omnibus Gitlab CentOS 7使用Let's Encrypt配置免费ssl
摘要:首先安装omnibus gitlab,参照 https://about.gitlab.com/downloads/ 参照以下两篇文章结合配置: https://certbot.eff.org/#centosrhel7-nginx https://webnugget.de/setting-up-git 阅读全文

posted @ 2016-08-05 12:39 傻子才悲伤 阅读(832) 评论(0) 推荐(0)

配置CentOS 7 DOCKER_HOST到0.0.0.0:2375
摘要:CentOS 7的配置文件位置略不同: 具体参见 https://www.daocloud.io/mirror#accelerator-doc中set_mirror脚本。 vi /usr/lib/systemd/system/docker.service [Unit]Description=Dock 阅读全文

posted @ 2016-08-02 11:38 傻子才悲伤 阅读(4831) 评论(0) 推荐(0)

Docker 写log到宿主机命令
摘要:以jmeter为例,写log到宿主机的/log目录下: docker run -v /log:/tmp flasheryu/jmeter flasheryu/jmeter中的命令: /opt/jmeter/bin/jmeter -n -t /jmeter/hello-baidu.jmx -l /tm 阅读全文

posted @ 2016-08-02 11:37 傻子才悲伤 阅读(1613) 评论(0) 推荐(0)

Docker 命令的坑
摘要:1. docker build -t abcDef . 会出错,原因是-t命令打tag时候不能有大写字母。 阅读全文

posted @ 2016-08-02 11:36 傻子才悲伤 阅读(288) 评论(0) 推荐(0)

jenkins docker容器的备份和复用
摘要:jenkins配置文件备份: docker cp focused_bhaskara:/var/jekins_home ./jenkins_home 其中focused_bhaskara为当前运行的jenkins容器名字,通过docker ps查看names即可得到。 docker create -v 阅读全文

posted @ 2016-08-02 11:35 傻子才悲伤 阅读(1190) 评论(0) 推荐(0)

使用jenkins docker容器的坑
摘要:1.项目使用maven的时候,首先在Global Tool Configuration里面添加自动安装maven,然后在项目的构建中增加Invoke top-level Maven targets中的Maven Version里面选中刚刚添加的Maven ID,否则会报以下错误: 2.巨坑: 在上图 阅读全文

posted @ 2016-08-02 11:34 傻子才悲伤 阅读(2632) 评论(0) 推荐(0)

导航