Signed-off-by: Li Ping 1477412247@qq.com --- container/updaterepo/start | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100755 container/updaterepo/start
diff --git a/container/updaterepo/start b/container/updaterepo/start new file mode 100755 index 0000000..46e3ad6 --- /dev/null +++ b/container/updaterepo/start @@ -0,0 +1,24 @@ +#!/usr/bin/env ruby +# SPDX-License-Identifier: MulanPSL-2.0+ +# Copyright (c) 2020 Huawei Technologies Co., Ltd. All rights reserved. +# frozen_string_literal: true + +require_relative '../defconfig.rb' + +docker_rm "update-repo" + +cmd = %W[ + docker run + --restart=always + --name update-repo + -u 1090:1090 + -p 8132:8132 + -d + -v /srv/rpm/:/srv/rpm/ + -v /etc/localtime:/etc/localtime:ro + update-repo +] + +cmd += ['sh', '-c', 'umask 002 && ./updaterepo'] + +system(*cmd)
On Mon, Mar 29, 2021 at 04:08:14PM +0800, Li Ping wrote:
Signed-off-by: Li Ping 1477412247@qq.com
container/updaterepo/start | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100755 container/updaterepo/start
diff --git a/container/updaterepo/start b/container/updaterepo/start new file mode 100755 index 0000000..46e3ad6 --- /dev/null +++ b/container/updaterepo/start @@ -0,0 +1,24 @@ +#!/usr/bin/env ruby +# SPDX-License-Identifier: MulanPSL-2.0+ +# Copyright (c) 2020 Huawei Technologies Co., Ltd. All rights reserved. +# frozen_string_literal: true
+require_relative '../defconfig.rb'
+docker_rm "update-repo"
+cmd = %W[
- docker run
- --restart=always
- --name update-repo
- -u 1090:1090
- -p 8132:8132
The port better set in sparrow and use the between 10000 and 20000 value.
Thanks, Xueliang
- -d
- -v /srv/rpm/:/srv/rpm/
- -v /etc/localtime:/etc/localtime:ro
- update-repo
+]
+cmd += ['sh', '-c', 'umask 002 && ./updaterepo']
+system(*cmd)
2.23.0
On Tue, Mar 30, 2021 at 02:20:49PM +0800, Cao Xueliang wrote:
On Mon, Mar 29, 2021 at 04:08:14PM +0800, Li Ping wrote:
Signed-off-by: Li Ping 1477412247@qq.com
container/updaterepo/start | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100755 container/updaterepo/start
diff --git a/container/updaterepo/start b/container/updaterepo/start new file mode 100755 index 0000000..46e3ad6 --- /dev/null +++ b/container/updaterepo/start @@ -0,0 +1,24 @@ +#!/usr/bin/env ruby +# SPDX-License-Identifier: MulanPSL-2.0+ +# Copyright (c) 2020 Huawei Technologies Co., Ltd. All rights reserved. +# frozen_string_literal: true
+require_relative '../defconfig.rb'
+docker_rm "update-repo"
+cmd = %W[
- docker run
- --restart=always
- --name update-repo
- -u 1090:1090
- -p 8132:8132
The port better set in sparrow and use the between 10000 and 20000 value.
ok, i got it.
Thanks, Ping
Thanks, Xueliang
- -d
- -v /srv/rpm/:/srv/rpm/
- -v /etc/localtime:/etc/localtime:ro
- update-repo
+]
+cmd += ['sh', '-c', 'umask 002 && ./updaterepo']
+system(*cmd)
2.23.0