[PATCH compass-ci] sparrow/3-code: add centos in os file

[Why] when run dev-env in centos system, error like this: ./dev-env:line 41: ./os/centos: No such file or directory. Signed-off-by: Zhang Yale <zhangyale3@huawei.com> --- sparrow/3-code/os/centos | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 sparrow/3-code/os/centos diff --git a/sparrow/3-code/os/centos b/sparrow/3-code/os/centos new file mode 100644 index 0000000..efb4fcb --- /dev/null +++ b/sparrow/3-code/os/centos @@ -0,0 +1,6 @@ +#!/bin/bash +cat >> /etc/default/docker <<EOF +DOCKER_OPTS="--dns 114.114.114.114" +EOF + +systemctl restart docker -- 2.23.0

On Wed, Oct 28, 2020 at 10:21:46AM +0800, Zhang Yale wrote:
[Why] when run dev-env in centos system, error like this: ./dev-env:line 41: ./os/centos: No such file or directory.
Signed-off-by: Zhang Yale <zhangyale3@huawei.com> --- sparrow/3-code/os/centos | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 sparrow/3-code/os/centos
diff --git a/sparrow/3-code/os/centos b/sparrow/3-code/os/centos new file mode 100644 index 0000000..efb4fcb --- /dev/null +++ b/sparrow/3-code/os/centos @@ -0,0 +1,6 @@ +#!/bin/bash
add license ?
+cat >> /etc/default/docker <<EOF
^---add space?
+DOCKER_OPTS="--dns 114.114.114.114" +EOF
you should change like this, docker file just append onec. cat > /etc/default/docker << EOF .... EOF Thanks, Liushaofei
+systemctl restart docker -- 2.23.0

On Wed, Oct 28, 2020 at 12:02:18PM +0800, Liu Shaofei wrote:
On Wed, Oct 28, 2020 at 10:21:46AM +0800, Zhang Yale wrote:
[Why] when run dev-env in centos system, error like this: ./dev-env:line 41: ./os/centos: No such file or directory.
Signed-off-by: Zhang Yale <zhangyale3@huawei.com> --- sparrow/3-code/os/centos | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 sparrow/3-code/os/centos
diff --git a/sparrow/3-code/os/centos b/sparrow/3-code/os/centos new file mode 100644 index 0000000..efb4fcb --- /dev/null +++ b/sparrow/3-code/os/centos @@ -0,0 +1,6 @@ +#!/bin/bash
add license ?
+cat >> /etc/default/docker <<EOF
^---add space?
+DOCKER_OPTS="--dns 114.114.114.114" +EOF
you should change like this, docker file just append once.
cat > /etc/default/docker << EOF .... EOF
Thanks, Liushaofei
+systemctl restart docker -- 2.23.0

On Wed, Oct 28, 2020 at 12:03:18PM +0800, Liu Shaofei wrote:
On Wed, Oct 28, 2020 at 12:02:18PM +0800, Liu Shaofei wrote:
On Wed, Oct 28, 2020 at 10:21:46AM +0800, Zhang Yale wrote:
[Why] when run dev-env in centos system, error like this: ./dev-env:line 41: ./os/centos: No such file or directory.
Signed-off-by: Zhang Yale <zhangyale3@huawei.com> --- sparrow/3-code/os/centos | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 sparrow/3-code/os/centos
diff --git a/sparrow/3-code/os/centos b/sparrow/3-code/os/centos new file mode 100644 index 0000000..efb4fcb --- /dev/null +++ b/sparrow/3-code/os/centos @@ -0,0 +1,6 @@ +#!/bin/bash
add license ?
If this your first open source code, add your own license and copyright notice. Thanks, Baijing
+cat >> /etc/default/docker <<EOF
^---add space?
+DOCKER_OPTS="--dns 114.114.114.114" +EOF
you should change like this, docker file just append once.
cat > /etc/default/docker << EOF .... EOF
Thanks, Liushaofei
+systemctl restart docker -- 2.23.0

On Wed, Oct 28, 2020 at 12:02:18PM +0800, Liu Shaofei wrote:
On Wed, Oct 28, 2020 at 10:21:46AM +0800, Zhang Yale wrote:
[Why] when run dev-env in centos system, error like this: ./dev-env:line 41: ./os/centos: No such file or directory.
Signed-off-by: Zhang Yale <zhangyale3@huawei.com> --- sparrow/3-code/os/centos | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 sparrow/3-code/os/centos
diff --git a/sparrow/3-code/os/centos b/sparrow/3-code/os/centos new file mode 100644 index 0000000..efb4fcb --- /dev/null +++ b/sparrow/3-code/os/centos @@ -0,0 +1,6 @@ +#!/bin/bash
add license ?
Ok, I'll add license in next version.
+cat >> /etc/default/docker <<EOF
^---add space?
+DOCKER_OPTS="--dns 114.114.114.114" +EOF
you should change like this, docker file just append onec.
cat > /etc/default/docker << EOF .... EOF
Thanks, Liushaofei
Good! Thanks, Yale
+systemctl restart docker -- 2.23.0

On Wed, Oct 28, 2020 at 10:21:46AM +0800, Zhang Yale wrote:
[Why] when run dev-env in centos system, error like this: ./dev-env:line 41: ./os/centos: No such file or directory.
Signed-off-by: Zhang Yale <zhangyale3@huawei.com> --- sparrow/3-code/os/centos | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 sparrow/3-code/os/centos
diff --git a/sparrow/3-code/os/centos b/sparrow/3-code/os/centos new file mode 100644 index 0000000..efb4fcb --- /dev/null +++ b/sparrow/3-code/os/centos @@ -0,0 +1,6 @@ +#!/bin/bash +cat >> /etc/default/docker <<EOF +DOCKER_OPTS="--dns 114.114.114.114" +EOF + +systemctl restart docker
use a function to wapper the code block. Thanks, Xueliang
-- 2.23.0

On Wed, Oct 28, 2020 at 02:14:57PM +0800, Cao Xueliang wrote:
On Wed, Oct 28, 2020 at 10:21:46AM +0800, Zhang Yale wrote:
[Why] when run dev-env in centos system, error like this: ./dev-env:line 41: ./os/centos: No such file or directory.
Signed-off-by: Zhang Yale <zhangyale3@huawei.com> --- sparrow/3-code/os/centos | 6 ++++++ 1 file changed, 6 insertions(+) create mode 100644 sparrow/3-code/os/centos
diff --git a/sparrow/3-code/os/centos b/sparrow/3-code/os/centos new file mode 100644 index 0000000..efb4fcb --- /dev/null +++ b/sparrow/3-code/os/centos @@ -0,0 +1,6 @@ +#!/bin/bash +cat >> /etc/default/docker <<EOF +DOCKER_OPTS="--dns 114.114.114.114" +EOF + +systemctl restart docker
use a function to wapper the code block.
Thanks, Xueliang
Ok, I got it. Thanks, Yale
-- 2.23.0
participants (4)
-
Bai Jing
-
Cao Xueliang
-
Liu Shaofei
-
Zhang Yale