Generic Oslo Config Generation
This commit is contained in:
parent
48b76c3e5c
commit
edc5b93d66
@ -23,7 +23,8 @@ RUN set -x \
|
|||||||
&& rm get-pip.py \
|
&& rm get-pip.py \
|
||||||
&& pip install \
|
&& pip install \
|
||||||
oslo.config \
|
oslo.config \
|
||||||
tox
|
tox \
|
||||||
|
crudini
|
||||||
|
|
||||||
COPY generate.py /opt/gen-oslo-openstack-helm/generate.py
|
COPY generate.py /opt/gen-oslo-openstack-helm/generate.py
|
||||||
COPY entrypoint.sh /entrypoint.sh
|
COPY entrypoint.sh /entrypoint.sh
|
||||||
|
@ -3,11 +3,19 @@ set -xe
|
|||||||
|
|
||||||
git clone --depth 1 --branch ${PROJECT_BRANCH} ${PROJECT_REPO} /tmp/${PROJECT}
|
git clone --depth 1 --branch ${PROJECT_BRANCH} ${PROJECT_REPO} /tmp/${PROJECT}
|
||||||
cd /tmp/${PROJECT}
|
cd /tmp/${PROJECT}
|
||||||
|
|
||||||
|
|
||||||
|
TOX_VENV_DIR=$(crudini --get tox.ini testenv:genconfig envdir | sed 's|^{toxworkdir}|.tox|')
|
||||||
|
if [ -z "$TOX_VENV_DIR" ]
|
||||||
|
then
|
||||||
|
TOX_VENV_DIR=".tox/genconfig"
|
||||||
|
fi
|
||||||
|
GENCONFIG_FLAGS=$(crudini --get tox.ini testenv:genconfig commands | sed 's/^oslo-config-generator//')
|
||||||
|
|
||||||
tox -egenconfig
|
tox -egenconfig
|
||||||
|
|
||||||
source .tox/genconfig/bin/activate
|
source ${TOX_VENV_DIR}/bin/activate
|
||||||
|
|
||||||
python /opt/gen-oslo-openstack-helm/generate.py \
|
python /opt/gen-oslo-openstack-helm/generate.py ${GENCONFIG_FLAGS} \
|
||||||
--config-file config-generator/${PROJECT}.conf \
|
--helm_chart ${PROJECT} \
|
||||||
--helm_chart ${PROJECT} \
|
--helm_namespace ${PROJECT}
|
||||||
--helm_namespace ${PROJECT}
|
|
||||||
|
Loading…
Reference in New Issue
Block a user