Merge "Install packages necessary to build Python wheels"

This commit is contained in:
Jenkins 2016-03-16 17:13:59 +00:00 committed by Gerrit Code Review
commit 852de167a6
5 changed files with 78 additions and 9 deletions

View File

@ -26,6 +26,29 @@ repo_build_pool_dir: "/var/www/repo/pools"
repo_build_release_tag: "untagged"
## APT Cache options
cache_timeout: 600
repo_build_apt_packages:
- build-essential
- cmake
- git
- liberasurecode-dev # required to build pyeclib
- libffi-dev # required to build xattr
- libjpeg-dev # required to build pillow
- libkrb5-dev # required to build pykerberos
- libldap2-dev # required to build python-ldap
- libmariadbclient-dev # required to build MySQL-python
- libpq-dev # required to build psycopg2
- libsasl2-dev # required to build python-ldap
- libsqlite3-dev # required to build pysqlite
- libssl-dev # required to build cryptography
- libvirt-dev # required to build libvirt-python
- libxslt1-dev # required to build lxml
- lxc-dev # required to build lxc-python2
- python-dev
- swig
repo_build_pip_default_index: "https://pypi.python.org/simple"
repo_build_pip_extra_indexes:
- "https://pypi.python.org/simple"

View File

@ -14,8 +14,8 @@
# limitations under the License.
# Wheel building
- include: repo_clone_git.yml
- include: repo_build_install.yml
- include: repo_clone_git.yml
- include: repo_set_facts.yml
- include: repo_pre_build.yml
- include: repo_build.yml

View File

@ -13,17 +13,41 @@
# See the License for the specific language governing permissions and
# limitations under the License.
- name: Drop lxc-net override file
template:
src: manual-init.override.j2
dest: /etc/init/lxc-net.override
owner: root
group: root
mode: 0644
tags:
- repo-build-apt-packages
- name: Install pip packages
pip:
name: "{{ item }}"
#TODO(evrardjp): Replace the next 2 tasks by a standard apt with cache
#when https://github.com/ansible/ansible-modules-core/pull/1517 is merged
#in 1.9.x or we move to 2.0 (if tested working)
- name: Check apt last update file
stat:
path: /var/cache/apt
register: apt_cache_stat
tags:
- repo-build-apt-packages
- name: Update apt if needed
apt:
update_cache: yes
when: "ansible_date_time.epoch|float - apt_cache_stat.stat.mtime > {{cache_timeout}}"
tags:
- repo-build-apt-packages
- name: Install apt packages
apt:
pkg: "{{ item }}"
state: present
extra_args: "--constraint {{ repo_build_git_dir }}/requirements/upper-constraints.txt {{ pip_install_options|default('') }}"
register: install_packages
until: install_packages|success
retries: 5
delay: 5
with_items: repo_pip_packages
delay: 2
with_items: repo_build_apt_packages
tags:
- repo-pip-packages
- repo-build-apt-packages

View File

@ -13,6 +13,19 @@
# See the License for the specific language governing permissions and
# limitations under the License.
- name: Install pip packages
pip:
name: "{{ item }}"
state: present
extra_args: "--constraint {{ repo_build_git_dir }}/requirements/upper-constraints.txt {{ pip_install_options|default('') }}"
register: install_packages
until: install_packages|success
retries: 5
delay: 5
with_items: repo_pip_packages
tags:
- repo-pip-packages
- name: Ensure workspace files are cleaned up
file:
path: "{{ item }}"

View File

@ -0,0 +1,9 @@
# {{ ansible_managed }}
pre-start script
echo "pass"
end script
post-stop script
echo "pass"
end script