gpt4 book ai didi

docker - 无法进入Apache Karaf docker 容器

转载 作者:行者123 更新时间:2023-12-02 18:30:32 25 4
gpt4 key购买 nike

我已经使用基本镜像apache karaf构建了Dockerfile,但是无法进入Apache Karaf docker容器

[root@HNHC9F2 docker_file]# docker exec -it b8586730289b /opt/karaf/bin/karaf

karaf: There is a Root instance already running with name root and pid 132. If you know what you are doing and want to force the run anyway, export CHECK_ROOT_INSTANCE_RUNNING=false and re run the command.

最佳答案

由于错误提示,您需要导出环境变量CHECK_ROOT_INSTANCE_RUNNING:

docker exec -it b8586730289b bash
export CHECK_ROOT_INSTANCE_RUNNING=false
exit
docker exec -it b8586730289b /opt/karaf/bin/karaf

更新:

如果您只想在容器中放入一个 shell ,那么下面就是所有需要的内容:
docker exec -it b8586730289b bash

关于docker - 无法进入Apache Karaf docker 容器,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/47514933/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com