Files
cookbook-openstack-common/recipes/client.rb
Jens Rosenboom 3d06aeabbf Install openstackclient into virtualenv
There may be issues caused by updated OpenStack python libraries being
picked up by other services when we install python-openstackclient
globally. So instead install it into its own virtualenv and create a
symlink to the resulting binary.

Change-Id: I43d9baf13dda20d39d3c52faf1f2322eee4884a3
Partial-Bug: 1661708
2017-02-09 14:56:20 +01:00

36 lines
966 B
Ruby

# encoding: UTF-8
#
# Cookbook Name:: openstack-common
# Recipe:: client
#
# Copyright 2014, IBM Corp.
# Copyright 2017, cloudbau GmbH
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
python_runtime '2'
python_virtualenv '/opt/osc' do
system_site_packages true
end
python_package 'python-openstackclient' do
version node['openstack']['common']['client_version']
virtualenv '/opt/osc'
end
link '/usr/local/bin/openstack' do
to '/opt/osc/bin/openstack'
end