简体   繁体   English

当我通过 EC2 访问 Jenkins 时出现错误

[英]When I access Jenkins trough an EC2 I get an error

I got an issue.我有一个问题。 I created a Jenkins AMI that i snapshoted it and created an image from a running ec2 instance with an already configured Jenkins Master on port 8443 with an https certificate.我创建了一个 Jenkins AMI,我对其进行了快照,并从一个正在运行的 ec2 实例创建了一个映像,该实例在端口 8443 上已经配置了 Jenkins Master,并带有 https 证书。 But when I curl to the jenkins instance i get the following: [1]: https://i.stack.imgur.com/K2tz0.png但是当我 curl 到 jenkins 实例时,我得到以下信息:[1]: https://i.stack.imgur.com/K2tz0.png

I checked Jenkins logs and everything was normal.我检查了 Jenkins 日志,一切正常。 And my Elatic Load balancer is healthy which means the security groups and other things are working just fine.我的 Elatic 负载均衡器很健康,这意味着安全组和其他东西运行良好。 Does anybody have a clue why is it giving a 403 Forbidden?有人知道为什么它会给出 403 Forbidden 吗? Another point is that I can even access the GUI另一点是我什至可以访问 GUI

By using curl you're making your life harder but look at some of what comes back:通过使用curl ,您的生活变得更加艰难,但看看一些返回的内容:

<meta http-equiv='refresh' content='1;url=/login?from=%2F'/>

If you've done HTML programming, this is one way of having the browser execute a redirect.如果您已经完成 HTML 编程,这是让浏览器执行重定向的一种方法。 Why Jenkins doesn't do some sort of HTTP redirect I don't know but the code is telling you that, after 1 second, redirect to the url /login .为什么 Jenkins 不做某种 HTTP 重定向我不知道,但代码告诉你,1 秒后,重定向到 url /login

curl isn't going to interpret the HTML for you, unlike the browser.与浏览器不同, curl不会为您解释 HTML。 Jenkins is working fine - you just need to follow what the HTML and JavaScript code is telling you to do through curl. Jenkins 工作正常 - 您只需按照 HTML 和 JavaScript 代码告诉您通过 ZF6E57C9DE709E535480 执行的操作即可。

The 403 error is the Jenkins application specifically saying your current user is not allowed access to the current action. 403 错误是 Jenkins 应用程序特别指出您的当前用户不允许访问当前操作。

It appears you're not logged in so your action is treated as an anonymous user.您似乎没有登录,因此您的操作被视为匿名用户。 If the anonymous user should have the permissions to access this action you will need to add them.如果匿名用户应该有权访问此操作,您将需要添加它们。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 尝试从EC2访问AWS S3时为什么会出现403错误 - Why do I get a 403 error when attempting to access AWS S3 from EC2 我在EC2上运行Node.js时出错 - error when i run nodejs on EC2 当我为 AWS EC2 安装 jenkins 运行 yum update 时,如何解决错误 Public key for jenkins-2.238-1.1.noarch.rpm is not installed - How do I solve the error Public key for jenkins-2.238-1.1.noarch.rpm is not installed when I run yum update for jenkins installation for the AWS EC2 我的 EC2 实例何时收费? - When will I get charged on my EC2 instance? AWS EC2:当我访问网站的 / 时,它工作正常,但是当我直接访问 /signin 时,它返回 NOT FOUND - AWS EC2: When i access the / of the website, it works fine, but when I access directly /signin, it returns NOT FOUND 我如何从特定的 ec2 实例获得对 s3 的 putobject 访问权限 - How can i get putobject access to s3 from specific ec2 instance 为什么当我在EC2实例上启动SSM代理时,我得到“单位被屏蔽”。 - Why when I start the SSM agent on my EC2 instance I get “Unit is masked.”? 如何访问我的开发人员创建的 EC2? - How do I get access to the EC2 my developer has created? 为什么我在创建 ec2 实例时收到此权限被拒绝错误? - Why am I getting this permission denied error when I created the ec2 instance? 无法修复 404 NOT FOUND 错误,因为我无法查看和访问 Elastic beanstalk 创建的 ec2 中的文件 - Unable to fix 404 NOT FOUND error because I cannot see and access the files in ec2 created by Elastic beanstalk
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM