Amazon web services AWS-docker和jenkins
我正在安排詹金斯去检查docker。但似乎遇到了障碍 通过CLI登录验证是否安装了docker和jenkins映像Amazon web services AWS-docker和jenkins,amazon-web-services,docker,jenkins,Amazon Web Services,Docker,Jenkins,我正在安排詹金斯去检查docker。但似乎遇到了障碍 通过CLI登录验证是否安装了docker和jenkins映像 docker images REPOSITORY TAG IMAGE ID CREATED SIZE hello-world latest fce289e99eb9 8 weeks ago 1.84kB jenkin
docker images
REPOSITORY TAG IMAGE ID CREATED SIZE
hello-world latest fce289e99eb9 8 weeks ago 1.84kB
jenkins latest cd14cecfdb3a 7 months ago 696MB
设置端口
docker run -d -p 49001:8080 -v $PWD/jenkins:/var/jenkins_home:z -t jenkins
已验证容器是否正在运行:
docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
ff1f21312230 jenkins "/bin/tini -- /usr/l…" About an hour ago Up About an hour 50000/tcp, 0.0.0.0:49001->8080/tcp nostalgic_mestorf
已检查主机是否可在本地访问
curl localhost:49001
<html><head><meta http-equiv='refresh' content='1;url=/login?from=%2F'/><script>window.location.replace('/login?from=%2F');</script></head><body style='background-color:white; color:white;'>
Authentication required
<!--
You are authenticated as: anonymous
Groups that you are in:
Permission you need to have (but didn't): hudson.model.Hudson.Administer
-->
</body></html>
在AWS上运行Red Hat Enterprise Linux Server 7.6版Maipo
我如何允许访问以便Jenkins加载?我做错了什么?任何帮助都将不胜感激 您将端口49001转发到Docker容器的端口8080。这就是你接触詹金斯的方式。看起来您对curl localhost:49001的响应是正确的。它要求你登录 还请注意,jenkins图像已被弃用。你应该改用jenkins/jenkins:lts
curl localhost:8080
curl: (7) Failed connect to localhost:8080; Connection refused