Skip to content

Commit 8aa5ac4

Browse files
authored
Merge pull request #306 from khs1994/master
Release v0.9.0
2 parents c5c8b7d + eb081e5 commit 8aa5ac4

File tree

9 files changed

+53
-49
lines changed

9 files changed

+53
-49
lines changed

.travis/docker-entrypoint.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ cd ../gitbook
1212

1313
main(){
1414
if [ "$1" = build ];then gitbook build; cp -a _book ../gitbook-src; echo $START; date "+%F %T"; exit 0; fi
15-
gitbook serve
15+
exec gitbook serve
1616
exit 0
1717
}
1818

CHANGELOG.md

Lines changed: 17 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,8 @@
11
## 主要修订记录
22

3-
* 0.9: 2017-12-31
3+
* 0.9.0: 2017-12-31
44

5-
* 0.9-rc3: 2017-12-30
6-
7-
* 增加 `私有仓库高级配置`
8-
9-
* 精简示例代码
10-
11-
* 调整目录结构
12-
13-
* 0.9-rc2: 2017-12-10
5+
* 0.9.0-rc2: 2017-12-10
146

157
* 增加 Docker 中文资源链接
168
* 增加介绍基于 Docker 的 CI/CD 工具 `Drone`
@@ -35,7 +27,7 @@
3527
* 修复内容逻辑错误
3628
* 修复`404` 链接
3729

38-
* 0.9-rc1: 2017-11-29
30+
* 0.9.0-rc1: 2017-11-29
3931

4032
* 根据最新版本(v17.09)修订内容
4133

@@ -94,23 +86,23 @@
9486

9587
* 0.3.0: 2014-11-25
9688

97-
* 完成仓库章节
98-
* 重写安全章节
99-
* 修正底层实现章节的架构、命名空间、控制组、文件系统、容器格式等内容
100-
* 添加对常见仓库和镜像的介绍
101-
* 添加 Dockerfile 的介绍
102-
* 重新校订中英文混排格式
103-
* 修订文字表达
104-
* 发布繁体版本分支:zh-Hant
89+
* 完成仓库章节
90+
* 重写安全章节
91+
* 修正底层实现章节的架构、命名空间、控制组、文件系统、容器格式等内容
92+
* 添加对常见仓库和镜像的介绍
93+
* 添加 Dockerfile 的介绍
94+
* 重新校订中英文混排格式
95+
* 修订文字表达
96+
* 发布繁体版本分支:zh-Hant
10597

10698
* 0.2.0: 2014-09-18
10799

108-
* 对照官方文档重写介绍、基本概念、安装、镜像、容器、仓库、数据管理、网络等章节
109-
* 添加底层实现章节
110-
* 添加命令查询和资源链接章节
111-
* 其它修正
100+
* 对照官方文档重写介绍、基本概念、安装、镜像、容器、仓库、数据管理、网络等章节
101+
* 添加底层实现章节
102+
* 添加命令查询和资源链接章节
103+
* 其它修正
112104

113105
* 0.1.0: 2014-09-05
114106

115-
* 添加基本内容;
116-
* 修正错别字和表达不通顺的地方
107+
* 添加基本内容
108+
* 修正错别字和表达不通顺的地方

CONTRIBUTING.md

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,17 +6,19 @@
66

77
```bash
88
$ git clone [email protected]:docker_user/docker_practice.git
9+
910
$ cd docker_practice
10-
$ git config user.name "yourname"
11-
$ git config user.email "your email"
1211
```
1312

1413
修改代码后提交,并推送到自己的仓库,注意修改提交消息为对应 Issue 号和描述。
1514

1615
```bash
1716
# Update the content
17+
1818
$ git commit -a -s
19+
1920
# In commit msg dialog, add content like "Fix issue #235: describe ur change"
21+
2022
$ git push
2123
```
2224

@@ -26,9 +28,11 @@ $ git push
2628

2729
```bash
2830
$ git remote add upstream https://github.com/yeasy/docker_practice
31+
2932
$ git fetch upstream
30-
$ git checkout master
33+
3134
$ git rebase upstream/master
35+
3236
$ git push -f origin master
3337
```
3438

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22

33
[![](https://img.shields.io/github/stars/yeasy/docker_practice.svg?style=social&label=Stars)](https://github.com/yeasy/docker_practice) [![](https://img.shields.io/docker/pulls/yeasy/docker_practice.svg)](https://store.docker.com/community/images/yeasy/docker_practice) [![](https://travis-ci.org/yeasy/docker_practice.svg?branch=master)](https://travis-ci.org/yeasy/docker_practice) [![](https://img.shields.io/github/release/yeasy/docker_practice/all.svg)](https://github.com/yeasy/docker_practice/releases) [![](https://badges.gitter.im/docker_practice/Lobby.svg)](https://gitter.im/docker_practice/Lobby?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
44

5-
0.9-rc2(2017-12-09)
5+
0.9.0(2017-12-31)
66

7-
*修订说明:本书内容将基于 Docker CE v17.MM 进行重新修订,计划 2017 年底发布 0.9.0 版本。旧版本(Docker 1.13-)内容,请阅读 [docker-legacy](https://github.com/yeasy/docker_practice/tree/docker-legacy) 分支的内容。*
7+
*修订说明:本书内容已基于 Docker CE v17.MM 进行了重新修订,2017 年底发布了 0.9.0 版本。旧版本(Docker 1.13-)内容,请阅读 [docker-legacy](https://github.com/yeasy/docker_practice/tree/docker-legacy) 分支的内容。*
88

99
[Docker](http://www.docker.com) 是个划时代的开源项目,它彻底释放了计算虚拟化的威力,极大提高了应用的运行效率,降低了云计算资源供应的成本!使用 Docker,可以让应用的部署、测试和分发都变得前所未有的高效和轻松!
1010

appendix/best_practices.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ RUN apt-get update && apt-get install -y \
6464

6565
### FROM
6666

67-
尽可能使用当前官方仓库作为你构建镜像的基础。推荐使用 [Debian](https://hub.docker.com/_/debian/) 镜像,因为它被严格控制并保持最小尺寸(目前小于 150 mb),但它仍然是一个完整的发行版。
67+
尽可能使用当前官方仓库作为你构建镜像的基础。推荐使用 [Alpine](https://hub.docker.com/_/alpine/) 镜像,因为它被严格控制并保持最小尺寸(目前小于 5 MB),但它仍然是一个完整的发行版。
6868

6969
### LABEL
7070

appendix/faq/README.md

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -96,17 +96,6 @@ $ docker run --network=my-net --ip=172.25.3.3 -itd --name=my-container busybox
9696

9797
注册服务器是存放实际的镜像文件的地方。注册索引则负责维护用户的账号、权限、搜索、标签等的管理。因此,注册服务器利用注册索引来实现认证等管理。
9898

99-
### 从非官方仓库(例如 non-official-repo.com)下载镜像时候,有时候会提示“Error: Invalid registry endpoint https://non-official-repo.com/v1/……”?
100-
101-
答:Docker 自 1.3.0 版本往后,加强了对镜像安全性的验证,需要添加私有仓库证书,或者手动添加对非官方仓库的信任。
102-
103-
编辑 Docker 配置文件,在其中添加:
104-
105-
```sh
106-
DOCKER_OPTS="--insecure-registry non-official-repo"
107-
```
108-
之后,重启 Docker 服务即可。
109-
11099
## 配置相关
111100

112101
### Docker 的配置文件放在哪里,如何修改配置?

appendix/repo/wordpress.md

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,11 @@
1414
$ docker run --name some-wordpress --link some-mysql:mysql -d wordpress
1515
```
1616

17-
启动 WordPress 容器时可以指定的一些环境参数包括
17+
启动 WordPress 容器时可以指定的一些环境变量包括
1818

19-
* `-e WORDPRESS_DB_USER=...` 缺省为 “root”
20-
* `-e WORDPRESS_DB_PASSWORD=...` 缺省为连接 mysql 容器的环境变量 `MYSQL_ROOT_PASSWORD` 的值
21-
* `-e WORDPRESS_DB_NAME=...` 缺省为 “wordpress”
22-
* `-e WORDPRESS_AUTH_KEY=...`, `-e WORDPRESS_SECURE_AUTH_KEY=...`, `-e WORDPRESS_LOGGED_IN_KEY=...`, `-e WORDPRESS_NONCE_KEY=...`, `-e WORDPRESS_AUTH_SALT=...`, `-e WORDPRESS_SECURE_AUTH_SALT=...`, `-e WORDPRESS_LOGGED_IN_SALT=...`, `-e WORDPRESS_NONCE_SALT=...` 缺省为随机 sha1 串
19+
* `WORDPRESS_DB_USER` 缺省为 `root`
20+
* `WORDPRESS_DB_PASSWORD` 缺省为连接 mysql 容器的环境变量 `MYSQL_ROOT_PASSWORD` 的值
21+
* `WORDPRESS_DB_NAME` 缺省为 `wordpress`
2322

2423
### Dockerfile
2524

bin/offline

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
#!/bin/bash
2+
3+
if [ -f offline ];then echo "请在项目根目录执行 $0"; exit 1; fi
4+
5+
command -v docker-compose > /dev/null 2>&1
6+
7+
if [ $? != 0 ];then echo "请安装 docker-compose"; exit 1; fi
8+
9+
if [ "$1" = update ];then
10+
status=`git status -s`
11+
if [ -z "$status" ];then
12+
git fetch --depth=1 origin master
13+
git reset --hard origin/master
14+
else
15+
echo "您已修改项目,请提交或恢复原状!"
16+
exit 1
17+
fi
18+
fi
19+
20+
docker-compose up server

kubernetes/concepts.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ Kubernetes 校验节点可用依赖于 ID。在当前的版本中,有两个接
6767
## 容器组
6868

6969
在 Kubernetes 中,使用的最小单位是容器组,容器组是创建,调度,管理的最小单位。
70-
一个容器组使用相同的 Dokcer 容器并共享卷(挂载点)。一个容器组是一个特定运用的打包集合,包含一个或多个容器。
70+
一个容器组使用相同的 Docker 容器并共享卷(挂载点)。一个容器组是一个特定运用的打包集合,包含一个或多个容器。
7171

7272
和运行的容器类似,一个容器组被认为只有很短的运行周期。容器组被调度到一组节点运行,知道容器的生命周期结束或者其被删除。如果节点死掉,运行在其上的容器组将会被删除而不是重新调度。(也许在将来的版本中会添加容器组的移动)。
7373

0 commit comments

Comments
 (0)