如何从Proxy后面更新Ruby Gems(ISA-NTLM) [英] How do I update Ruby Gems from behind a Proxy (ISA-NTLM)

查看:109
本文介绍了如何从Proxy后面更新Ruby Gems(ISA-NTLM)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我所支持的防火墙是以仅限NTLM的模式运行Microsoft ISA服务器。哈希任何人都可以通过Ruby SSPI gem或其他方法成功获取他们的Ruby宝石来安装/更新?



...或者我只是懒惰吗?



注意:rubysspi-1.2.4不起作用。

这也适用于IronRuby项目的一部分igem / p>

解决方案

我无法从命令行切换到我的工作,但我只能通过设置我的 HTTP_PROXY 环境变量。 (请注意,这种情况似乎很重要)。我有一个批处理文件,里面有这样一行:

  SET HTTP_PROXY = http://%USER%:% PASSWORD%@%SERVER%:%PORT%

在设置这四个引用变量之前,很明显。作为一个例子,如果我的用户名是wolfbyte,我的密码是秘密,我的代理被称为pigsy,并在端口8080上运行:

  SET HTTP_PROXY = http:// wolfbyte:secret @ pigsy:8080 

想要小心如何管理它,因为它在机器会话中以纯文本形式存储密码,但我认为这不应该是太多问题。


The firewall I'm behind is running Microsoft ISA server in NTLM-only mode. Hash anyone have success getting their Ruby gems to install/update via Ruby SSPI gem or other method?

... or am I just being lazy?

Note: rubysspi-1.2.4 does not work.

This also works for "igem", part of the IronRuby project

解决方案

I wasn't able to get mine working from the command-line switch but I have been able to do it just by setting my HTTP_PROXY environment variable. (Note that case seems to be important). I have a batch file that has a line like this in it:

SET HTTP_PROXY=http://%USER%:%PASSWORD%@%SERVER%:%PORT%

I set the four referenced variables before I get to this line obviously. As an example if my username is "wolfbyte", my password is "secret" and my proxy is called "pigsy" and operates on port 8080:

SET HTTP_PROXY=http://wolfbyte:secret@pigsy:8080

You might want to be careful how you manage that because it stores your password in plain text in the machine's session but I don't think it should be too much of an issue.

这篇关于如何从Proxy后面更新Ruby Gems(ISA-NTLM)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆