Merge "Allow source-repositories to be disabled completely"
This commit is contained in:
commit
8ba6a26e0a
@ -3,4 +3,8 @@
|
|||||||
set -eu
|
set -eu
|
||||||
set -o pipefail
|
set -o pipefail
|
||||||
|
|
||||||
|
if [ -z "${NO_SOURCE_REPOSITORIES:-}" ]; then
|
||||||
install -m 0755 -o root -g root /opt/stack/lsb-release/lsb_release /usr/local/bin
|
install -m 0755 -o root -g root /opt/stack/lsb-release/lsb_release /usr/local/bin
|
||||||
|
else
|
||||||
|
install-packages redhat-lsb-core
|
||||||
|
fi
|
||||||
|
@ -103,3 +103,7 @@ The base url for all git repositories can be set by use of:
|
|||||||
So setting DIB\_GITREPOBASE=https://github.com/ when the repo location is set
|
So setting DIB\_GITREPOBASE=https://github.com/ when the repo location is set
|
||||||
to http://git.openstack.org/openstack/nova.git will result in use of the
|
to http://git.openstack.org/openstack/nova.git will result in use of the
|
||||||
https://github.com/openstack/nova.git repository.
|
https://github.com/openstack/nova.git repository.
|
||||||
|
|
||||||
|
When doing image builds in environments where external resources are not allowed,
|
||||||
|
it is possible to disable fetching of all source repositories by including an
|
||||||
|
element in the image that sets NO_SOURCE_REPOSITORIES=1 in an environment.d script.
|
||||||
|
@ -3,6 +3,11 @@
|
|||||||
set -eu
|
set -eu
|
||||||
set -o pipefail
|
set -o pipefail
|
||||||
|
|
||||||
|
# Don't provide any source repositories in environments where they are not allowed
|
||||||
|
if [ -n "${NO_SOURCE_REPOSITORIES:-}" ]; then
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
# If the old cache exists, move it to the new name
|
# If the old cache exists, move it to the new name
|
||||||
function make_new_cache(){
|
function make_new_cache(){
|
||||||
local OLD_CACHE_BASE=$1
|
local OLD_CACHE_BASE=$1
|
||||||
|
Loading…
Reference in New Issue
Block a user