Allow setting custom ec2api port to listen to
The README mentions that install.sh allows setting custom port(other than 8788 default) to start ec2api on but upon looking, there wasnt any option. This patch adds the option to allow user to set a different port prior to installation using install.sh script. also the options defined in devstack plugin but it isnt being set in ec2api.conf. Change-Id: I440b69fafb5555a7a9f4d1e27b1f811d2a3ecc29
This commit is contained in:
parent
d83bd7313b
commit
d9d47550c2
|
@ -180,6 +180,9 @@ function configure_ec2api {
|
|||
iniset $EC2API_CONF_FILE DEFAULT keystone_url "http://${KEYSTONE_AUTH_HOST}:35357/v2.0"
|
||||
iniset $EC2API_CONF_FILE DEFAULT region_list "$REGION_NAME"
|
||||
|
||||
iniset $EC2API_CONF_FILE DEFAULT ec2api_listen_port "$EC2API_SERVICE_PORT"
|
||||
iniset $EC2API_CONF_FILE DEFAULT ec2_port "$EC2API_SERVICE_PORT"
|
||||
|
||||
if is_service_enabled swift3; then
|
||||
iniset $EC2API_CONF_FILE DEFAULT s3_port "$S3_SERVICE_PORT"
|
||||
else
|
||||
|
|
|
@ -4,6 +4,7 @@
|
|||
SERVICE_USERNAME=ec2api
|
||||
SERVICE_PASSWORD=ec2api
|
||||
SERVICE_TENANT=service
|
||||
EC2API_PORT=8788
|
||||
CONNECTION="mysql://ec2api:ec2api@127.0.0.1/ec2api?charset=utf8"
|
||||
LOG_DIR=/var/log/ec2api
|
||||
CONF_DIR=/etc/ec2api
|
||||
|
@ -263,9 +264,11 @@ AUTH_PORT=`openstack catalog show identity -f value|grep adminURL|awk '{print $2
|
|||
AUTH_PORT=${AUTH_PORT##*:}
|
||||
AUTH_PORT=${AUTH_PORT%%/*}
|
||||
AUTH_PROTO=${OS_AUTH_URL%%:*}
|
||||
PUBLIC_URL=${OS_AUTH_URL%:*}:8788/
|
||||
PUBLIC_URL=${OS_AUTH_URL%:*}:"$EC2API_PORT"/
|
||||
|
||||
#update default config with some values
|
||||
iniset $CONF_FILE DEFAULT ec2api_listen_port "$EC2API_PORT"
|
||||
iniset $CONF_FILE DEFAULT ec2_port "$EC2API_PORT"
|
||||
iniset $CONF_FILE DEFAULT api_paste_config $APIPASTE_FILE
|
||||
iniset $CONF_FILE DEFAULT logging_context_format_string "%(asctime)s.%(msecs)03d %(levelname)s %(name)s [%(request_id)s %(user_name)s %(project_name)s] %(instance)s%(message)s"
|
||||
iniset $CONF_FILE DEFAULT log_dir "$LOG_DIR"
|
||||
|
|
Loading…
Reference in New Issue