在windows上面 安裝virtualenv 和fabric

來源:互聯網
上載者:User

http://stackoverflow.com/questions/9000380/install-python-fabric-on-windows




fabric installs just fine on Windows, but you will need to either:


    have a compiler installed to build the pycrypto dependency during setup.If you don't have one already, install MinGW or you can use the free version of MSVC.
    install pre-built Windows binaries for pyCrypto here.


I install it in a virtualenv like so:


virtualenv fabenv
fabenv\Scripts\activate.bat
pip install fabric


Another Tip: When you have it up and running you can use pageant to load your ssh keys and avoiding using password-based authentication



Solution using Cygwin:


    Install Cygwin
    Select packages: Python, Gcc, Wget and Openssh
    In Cygwin run: python --version to verify your Python version
    From http://pypi.python.org/pypi/setuptools download the .egg version of setuptools (NOT the Windows .exe), for your version of Python.
    In Cygwin run: sh setuptools-*.egg to install the downloaded setuptools package
    In Cygwin run: easy_install pip (I just like Pip, I think you could the next step with easy_install as well)
    In Cygwin run: pip install fabric
    And now comes the crucial part: if the above step fails with some "could not remap xxx.dll" error, on the install of the Python ssh package then:
    Exit Cygwin
    Start a cmd.exe an in it run: c:\cygwin_path\bin\ash.exe
    In the ash shell run: /bin/rebaseall
    In Cygwin retry: pip install fabric, it should succeed now :)


相關文章

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.