Giter Club home page Giter Club logo

chef-python-build's Introduction

python-build Cookbook

This cookbook build and install several python versions from official source. Python-2.4, 2.5, 2.6, 2.7, 3.0, 3.1, 3.2, 3.3. however 3.0 is limited work with 'packages' attribute.

Requirements

cookbook

  • build-essential - building python needs gcc and related headers.

Attributes

python-build::default

Key Type Description Default
["python_build"]["archive_url_base"] string Python source file location. python official site is default. nil
["python_build"]["configure_options"] array configure options ['--enable-shared']
["python_build"]["install_prefix"] string Install path prefix "/usr/local"
["python_build"]["versions"] string Install versions list. If you want to specify default version of python then it place last of the list. for example: `"versions": ["2.5.6", "3.3.1", "2.7.3"]` []
["python_build"]["packages"] string Install python 3rd-party package list. "setuptools" will install by default. BTW setuptools did not support Python-3.0 then this feature did not work when specify '3.0.x' in versions. []
["python_build"]["owner"] string Install file/directory owner. "root"
["python_build"]["group"] string Install file/directory group. "root"
["python_build"]["find_links"] string list of package urls for easy_install -f []

Usage

python-build::default

Include python-build in your node's run_list and specify python_build attributes:

{
  "name":"my_node",
  "run_list": [
    "recipe[python-build]"
  ],
  "override_attributes" : {
    "python_build": {
      "versions" : ["2.6.8", "2.7.3", "3.2.3", "3.3.0"],
      "packages" : ["pip", "tox", "virtualenv"]
    }
  }
}

Contributing

  1. Fork the repository on Github
  2. Create a named feature branch (like add_component_x)
  3. Write you change
  4. Write tests for your change (if applicable)
  5. Run the tests, ensuring they all pass
  6. Submit a Pull Request using Github

License and Authors

Authors: Takayuki Shimizukawa License: Apache 2.0

chef-python-build's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

chef-python-build's Issues

Old Pip Version installed

Using chef-python-build to install Pip as a package in the configuration installs pip 6.0.8. The current stable version is 7.1.0. Why doesn't this install the latest version, and is there a configuration option to change that?

Thanks!

Older Python versions can not be built

I could build these versions on Ubuntu 12.10:

  "versions" : [  "3.0.1","3.1.5", "3.2.4", "3.3.1",  "2.6.8", "2.7.4"],

But I got build errors with older versions:

  "versions" : [  "2.5.6"],

More versions fail if I set "packages"

"packages" : ["pip", "tox", "virtualenv"]

error while loading shared libraries: libpython2.7.so.1.0

I have tried to use the cookbook to install python 2.7.3 with pip and virtualenv on centos 6.5,
got the following error :

Error executing action run on resource 'execute[install easy_install-2.7]'
================================================================================

       Mixlib::ShellOut::ShellCommandFailed
       ------------------------------------
       Expected process to exit with [0], but received '127'
       ---- Begin output of /usr/local/bin/python2.7 ez_setup.py ----
       STDOUT:
       STDERR: /usr/local/bin/python2.7: error while loading shared libraries: libpython2.7.so.1.0: cannot open shared object file: No such file or directory
       ---- End output of /usr/local/bin/python2.7 ez_setup.py ----
       Ran /usr/local/bin/python2.7 ez_setup.py returned 127

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.