简体   繁体   English

无法使用Intellij [OpenshiftException]连接到Openshift

[英]Cannot connect to Openshift using Intellij [OpenshiftException]

I use the Github login credentials to enter to the Openshift Web Console (Next Gen) but I cannot using Intellij for deploy my application as the only way to login is using a token and the oc commands in the prompt. 我使用Github登录凭据输入Openshift Web控制台(下一代),但我无法使用Intellij部署我的应用程序,因为登录的唯一方法是在提示中使用令牌和oc命令。 Is there a way to use my token to deploy using IDEA? 有没有办法使用我的令牌通过IDEA进行部署?

I am not sure about the Idea integration, but if I understand correctly you can provide a token. 我不确定Idea的集成方式,但是如果我理解正确,可以提供一个令牌。 So why can you not do something like 那你为什么不能做这样的事情

oc login --token=<your-token> --server=https://api.preview.openshift.com/oapi/v1/users/~

So token you can retrieve from the developer preview website under the help menu. 因此,您可以从开发人员预览网站的帮助菜单下检索令牌。

As far as I'm aware of, there is no integration available between IntelliJ and OpenShift. 据我所知,IntelliJ和OpenShift之间没有集成。 The easiest form of deployment is a Github webhook which will automatically deploy upon commit. 最简单的部署方式是Github Webhook ,它会在提交后自动进行部署。 However, you can also easily deploy a local application by using oc new-app /path/to/app/directory , and you can even set up a service to push local webhooks to OpenShift 但是,您还可以使用oc new-app /path/to/app/directory轻松部署本地应用程序,甚至可以设置服务以将本地webhooks推送到OpenShift

With IntelliJ IDEA 2018.3 there will be an option for this, via "Build, Execution, Deployment > OpenShift": 对于IntelliJ IDEA 2018.3,将有一个选项,通过“构建,执行,部署> OpenShift”进行:

带令牌的OpenShift

Related Bugticket: https://youtrack.jetbrains.com/issue/IDEA-176760 相关Bugticket: https ://youtrack.jetbrains.com/issue/IDEA-176760

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

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM