Work around Synchronizer startup race condition
diff --git a/xos/configurations/common/xos_common_config b/xos/configurations/common/xos_common_config
index df30b54..b06098e 100644
--- a/xos/configurations/common/xos_common_config
+++ b/xos/configurations/common/xos_common_config
@@ -33,7 +33,7 @@
[observer]
pretend=False
-backoff_disabled=False
+backoff_disabled=True
images_directory=/opt/xos/images
dependency_graph=/opt/xos/model-deps
logfile=/var/log/xos_backend.log
diff --git a/xos/configurations/cord/docker-compose.yml b/xos/configurations/cord/docker-compose.yml
index 3483a65..6b42eea 100644
--- a/xos/configurations/cord/docker-compose.yml
+++ b/xos/configurations/cord/docker-compose.yml
@@ -4,7 +4,7 @@
- "5432"
xos_synchronizer_openstack:
- command: python /opt/xos/xos-observer.py
+ command: bash -c "sleep 120 ; python /opt/xos/xos-observer.py"
image: xosproject/xos-synchronizer-openstack
labels:
org.xosproject.kind: synchronizer
@@ -18,19 +18,19 @@
- ./xos_cord_config:/opt/xos/xos_configuration/xos_cord_config:ro
-#xos_synchronizer_onos:
-# image: xosproject/xos-synchronizer-openstack
- #command: /usr/bin/supervisord -c /opt/xos/observers/onos/supervisor/onos-observer.conf
-# command: python /opt/xos/observers/onos/onos-observer.py -C /opt/xos/observers/onos/onos_observer_config
-# labels:
-# org.xosproject.kind: synchronizer
-# org.xosproject.target: onos
-# links:
-# - xos_db
-# extra_hosts:
-# - ctl:${MYIP}
-# volumes:
-# - ../setup/id_rsa:/opt/xos/observers/onos/onos_key:ro # private key
+xos_synchronizer_onos:
+ image: xosproject/xos-synchronizer-openstack
+ #command: /usr/bin/supervisord -c /opt/xos/observers/onos/supervisor/onos-observer.conf
+ command: bash -c "sleep 120 ; python /opt/xos/observers/onos/onos-observer.py -C /opt/xos/observers/onos/onos_observer_config"
+ labels:
+ org.xosproject.kind: synchronizer
+ org.xosproject.target: onos
+ links:
+ - xos_db
+ extra_hosts:
+ - ctl:${MYIP}
+ volumes:
+ - ../setup/id_rsa:/opt/xos/observers/onos/onos_key:ro # private key
#xos_synchronizer_vcpe:
# image: xosproject/xos-synchronizer-openstack
@@ -46,17 +46,17 @@
# volumes:
# - ../setup/id_rsa:/opt/xos/observers/vcpe/vcpe_private_key:ro # private key
-#xos_synchronizer_vbng:
-# image: xosproject/xos-synchronizer-openstack
+xos_synchronizer_vbng:
+ image: xosproject/xos-synchronizer-openstack
#command: /usr/bin/supervisord -c /opt/xos/observers/vbng/supervisor/vbng-observer.conf
-# command: python /opt/xos/observers/vbng/vbng-observer.py -C /opt/xos/observers/vbng/vbng_observer_config
-# labels:
-# org.xosproject.kind: synchronizer
-# org.xosproject.target: vbng
-# links:
-# - xos_db
-# extra_hosts:
-# - ctl:${MYIP}
+ command: bash -c "sleep 120 ; python /opt/xos/observers/vbng/vbng-observer.py -C /opt/xos/observers/vbng/vbng_observer_config"
+ labels:
+ org.xosproject.kind: synchronizer
+ org.xosproject.target: vbng
+ links:
+ - xos_db
+ extra_hosts:
+ - ctl:${MYIP}
#xos_synchronizer_monitoring_channel:
# image: xosproject/xos-synchronizer-openstack
diff --git a/xos/configurations/devel/docker-compose.yml b/xos/configurations/devel/docker-compose.yml
index 0602a66..66f6702 100644
--- a/xos/configurations/devel/docker-compose.yml
+++ b/xos/configurations/devel/docker-compose.yml
@@ -5,7 +5,7 @@
xos_synchronizer_openstack:
image: xosproject/xos-synchronizer-openstack
- command: python /opt/xos/xos-observer.py
+ command: bash -c "sleep 120; python /opt/xos/xos-observer.py"
labels:
org.xosproject.kind: synchronizer
org.xosproject.target: openstack