Giter Club home page Giter Club logo

pip-configure's Introduction

cans.pip-config

Build Status

Ansible Role to setup pip to access private package indices and other Python package sources

Requirements

This role has the requirements of Ansible's template module.

Role Variables

This role variables are namespaced using the pip_config_ prefix.

  • pip_config_dir: the directory in which install pip's configuration file (default: ~/.pip/);
  • pip_config_index_url: the main PyPI index you want pip to look for packages in (default: not defined);
  • pip_config_extra_index_urls: the list of extra PyPI indexes you want pip to look for packages in (default: []);
  • pip_config_file: the name to give to pip configuration file (default: pip.conf);
  • pip_config_find_links_urls: the list of extra web resources pip should scan for links to Python packages (default: []);
  • pip_config_timeout: the duration in seconds pip will wait for any package index to respond before droping the connexion and try with the next (default: 10).

You most likely do not need to modify the value of the pip_config_dir and pip_config_file variables. But since pip supports many locations for its configuration, these allow you to do it if you fancy it.

The pip_config_timeout variable you may want to adjust depending on where are stored the packages you need. The lower the value, the less you wait, but the higher the risk of unexpected failures.

If you want to add one or more PyPI indexes for pip to search in addition to the default one, specify them as a list value for pip_config_extra_index_urls. If you want to override the default PyPI index entirely, specify your own main index as a string value for pip_config_index_url. You can use both variables if you want pip to ignore the default index and search multiple other PyPI indexes.

Dependencies

This role has no dependencies.

Example Playbook

- hosts: servers
  vars:
    pip_config_extra_index_urls:
      - https://my-pypi.domain.com/simple
    pip_config_find_links_urls:
      - https://my.domain.com/packages.html
       
  roles:
     - { role: "cans.pip-config" }

License

The Ansible role pip-config is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License version 2 as published by the Free Software Foundation.

pip-config is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with cans.package-sources. If not, see http://www.gnu.org/licenses/.

Author Information

Copyright © 2017, Nicolas CANIART

pip-configure's People

Contributors

cans avatar stephenjolly avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.