Merge "Make the script run on RedHat-like OS"
This commit is contained in:
commit
ec2b65a1bc
@ -64,6 +64,7 @@ if is_service_enabled kuryr; then
|
|||||||
else
|
else
|
||||||
echo -n "${KURYR_CONFIG} and the default config missing. Auto generating and copying one... "
|
echo -n "${KURYR_CONFIG} and the default config missing. Auto generating and copying one... "
|
||||||
cd ${KURYR_HOME}
|
cd ${KURYR_HOME}
|
||||||
|
pip_install tox
|
||||||
tox -egenconfig
|
tox -egenconfig
|
||||||
sudo cp ${KURYR_DEFAULT_CONFIG}.sample ${KURYR_DEFAULT_CONFIG}
|
sudo cp ${KURYR_DEFAULT_CONFIG}.sample ${KURYR_DEFAULT_CONFIG}
|
||||||
sudo cp ${KURYR_DEFAULT_CONFIG} ${KURYR_CONFIG}
|
sudo cp ${KURYR_DEFAULT_CONFIG} ${KURYR_CONFIG}
|
||||||
@ -79,7 +80,11 @@ if is_service_enabled kuryr; then
|
|||||||
sudo sh install_docker.sh
|
sudo sh install_docker.sh
|
||||||
sudo rm install_docker.sh
|
sudo rm install_docker.sh
|
||||||
|
|
||||||
sudo killall docker
|
# CentOS/RedHat distros don't start the services just after the package
|
||||||
|
# is installed if it is not explicitily set. So the script fails on
|
||||||
|
# them in this killall because there is nothing to kill.
|
||||||
|
# TODO(devvesa): use a `is_running service` or a more elegant approach
|
||||||
|
sudo killall docker || true
|
||||||
run_process docker-engine "sudo /usr/bin/docker daemon --cluster-store etcd://localhost:4001"
|
run_process docker-engine "sudo /usr/bin/docker daemon --cluster-store etcd://localhost:4001"
|
||||||
run_process kuryr "sudo PYTHONPATH=$PYTHONPATH:$DEST/kuryr SERVICE_USER=admin SERVICE_PASSWORD=$SERVICE_PASSWORD SERVICE_TENANT_NAME=admin SERVICE_TOKEN=$SERVICE_TOKEN IDENTITY_URL=http://127.0.0.1:5000/v2.0 python $DEST/kuryr/scripts/run_server.py --config-file /etc/kuryr/kuryr.conf"
|
run_process kuryr "sudo PYTHONPATH=$PYTHONPATH:$DEST/kuryr SERVICE_USER=admin SERVICE_PASSWORD=$SERVICE_PASSWORD SERVICE_TENANT_NAME=admin SERVICE_TOKEN=$SERVICE_TOKEN IDENTITY_URL=http://127.0.0.1:5000/v2.0 python $DEST/kuryr/scripts/run_server.py --config-file /etc/kuryr/kuryr.conf"
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user