Skip to content
This repository has been archived by the owner on Jan 18, 2023. It is now read-only.

how to build cmk docker image. #215

Open
shunianyin opened this issue Oct 30, 2018 · 6 comments
Open

how to build cmk docker image. #215

shunianyin opened this issue Oct 30, 2018 · 6 comments

Comments

@shunianyin
Copy link

Hi guys, how to build cmk docker image ? from the code path -/CODE/Dockerfile? thanks.

@lmdaly
Copy link
Contributor

lmdaly commented Oct 30, 2018

hey @shunianyin, you can run "make" from the root CMK directory which will build the docker image.

@shunianyin
Copy link
Author

but I get an Error when I building the docker image.
The Error like
"ERROR: InvocationError: '/cmk/.tox/integration/bin/py.test -v --cov --cov-report=annotate --cov-append tests/integration'".

@lmdaly
Copy link
Contributor

lmdaly commented Oct 31, 2018

Could you let us know what version of CMK you are using and what version of K8s?
Also if there is more to the error logs could you attach those as well.

@shunianyin
Copy link
Author

shunianyin commented Oct 31, 2018

OK, i want to know whether the docker image of CMK must be bulit in the k8s. But now K8s is not installed in host environment(docker 17.12.1-ce、Python 3.4.6 、cmk 1.3.0), which may cause the above problem.

I also have another question to ask you. Does CMK support allocating CPU with the corresponding policies when i create Pod container which uses a new option (the num of cpus)? thanks .

@shunianyin
Copy link
Author

@lmdaly
I have now successfully bulit the docker image of CMK.
But configuration directory initialization failed through the subcommand of cmk init.
Example:
$ docker run -it cmk:v1.3.0 --volume=/etc/cmk:/etc/cmk:rw
cmk init --conf-dir=/etc/cmk --num-exclusive-cores=4 --num-shared-cores=1
After executing the above command,the corresponding container did not start up.
How to correctly use the cmk command-line tool?
thanks.

@lmdaly
Copy link
Contributor

lmdaly commented Nov 5, 2018

Hey, there is a mistake in the documentation for the docker runs for CMK.

Here is the correct command to run the init command with CMK -
docker run -it --volume=/etc/cmk:/etc/cmk:rw --env CMK_PROC_FS=/proc cmk:v1.3.0 init --conf-dir=/etc/cmk --num-exclusive-cores=4 --num-shared-cores=1

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants