diff --git a/docker.neutron.conf b/docker.neutron.conf index c2aedf7..86ffbab 100644 --- a/docker.neutron.conf +++ b/docker.neutron.conf @@ -19,7 +19,7 @@ max_overflow = 500 [QUARK] public_net_id=00000000-0000-0000-0000-000000000000 net_driver=quark.drivers.unmanaged.UnmanagedDriver -default_net_strategy='{"00000000-0000-0000-0000-000000000000": {"bridge": "publicnet"}, "11111111-1111-1111-1111-111111111111": {"bridge": "servicenet"}}' +default_net_strategy='{"00000000-0000-0000-0000-000000000000": {"bridge": "publicnet", "subnets": {"4": "00000000-0000-0000-0000-000000000000", "6": "11111111-1111-1111-1111-111111111111"}}, "11111111-1111-1111-1111-111111111111": {"bridge": "servicenet", "subnets": {"4": "22222222-2222-2222-2222-222222222222", "6": "333333333-3333-3333-3333-333333333333"}}}' default_network_type=UNMANAGED # IPAM recycling interval, in seconds ipam_reuse_after= 300 @@ -28,7 +28,10 @@ show_subnet_ip_policy_id = False show_allocation_pools = True pessimistic_connection_pooling = True environment_capabilities = "" +redis_sentinel_hosts = docker-redis-sentinel:6380 +redis_sentinel_master = mymaster +redis_min_other_sentinels = 0 [oslo_messaging_notifications] driver = messaging -transport_url = 'rabbit://admin:password@docker-rabbitmq:5672/' \ No newline at end of file +transport_url = 'rabbit://admin:password@docker-rabbitmq:5672/' diff --git a/docker_reload.sh b/docker_reload.sh index 9b1219b..8efe53f 100755 --- a/docker_reload.sh +++ b/docker_reload.sh @@ -9,4 +9,17 @@ echo " " echo "Neutron/Quark: Starting Container..." docker run -d -v $(pwd):/opt/quark -v ~/neutron:/opt/configs -p 9696:9696 --link mysql:docker-mysql --link kibana:docker-kibana --link rabbitmq:docker-rabbitmq --link redis-sentinel:docker-redis-sentinel --name quark stajkowski/quark -echo "Neutron/Quark - Complete - http://localhost:9696" \ No newline at end of file +echo "Neutron/Quark: Waiting for Neutron to Start..." +# Need to wait for DB to standup +sleep 5 +check_count=0 +while [ $check_count -lt 175 ]; do + check=`curl -s http://localhost:9696/v2.0/networks | grep "networks" | wc -l` + if [ "$check" -gt 0 ]; then + echo "Seems to be alive!" + break + fi + sleep 1 + check_count=$((check_count+1)) +done +echo "Neutron/Quark - Complete - http://localhost:9696" diff --git a/docker_up.sh b/docker_up.sh index 257ccb5..52ebf58 100755 --- a/docker_up.sh +++ b/docker_up.sh @@ -47,7 +47,17 @@ docker run -d -v $(pwd):/opt/quark -v ~/neutron:/opt/configs -p 9696:9696 --link # docker run --entrypoint /bin/bash -v $(pwd):/opt/quark -v ~/neutron:/opt/configs -p 9696:9696 --link mysql:docker-mysql --link kibana:docker-kibana --link rabbitmq:docker-rabbitmq --link redis-sentinel:docker-redis-sentinel --name quark stajkowski/quark echo "Neutron/Quark: Waiting for Neutron to Start..." # Need to wait for DB to standup -sleep 180 +sleep 5 +check_count=0 +while [ $check_count -lt 175 ]; do + check=`curl -s http://localhost:9696/v2.0/networks | grep "networks" | wc -l` + if [ "$check" -gt 0 ]; then + echo "Seems to be alive!" + break + fi + sleep 1 + check_count=$((check_count+1)) +done echo "Neutron/Quark: Complete - http://localhost:9696" echo "------------------------------------------" echo " " @@ -82,4 +92,4 @@ echo " CIDR: 10.3.0.0/16 SEGMENT_ID: blah TENANT_ID: derp" echo " CIDR: 10.4.0.0/16 SEGMENT_ID: blah TENANT_ID: derp" echo "------------------------------------------" echo " COMPLETE!!" -echo "------------------------------------------" \ No newline at end of file +echo "------------------------------------------"