From f71673b42e64d7258ed9025f0f03882e687e2ca5 Mon Sep 17 00:00:00 2001 From: Stephen Gallagher Date: Wed, 19 Aug 2015 15:02:29 -0400 Subject: [PATCH] Ensure that kube-apiserver starts after etcd If etcd is running on the same system as kube-apiserver and is being started as part of the same series of services (such as with a custom systemd target), we need to ensure that it orders later in startup than etcd or it will fail to find the local service. Note: this does not attempt to start etcd on the local system if it is not already part of the transaction, so it will have no effect if someone calls `systemctl start kube-apiserver.service` directly. --- contrib/init/systemd/kube-apiserver.service | 2 ++ 1 file changed, 2 insertions(+) diff --git a/contrib/init/systemd/kube-apiserver.service b/contrib/init/systemd/kube-apiserver.service index b9a7609b62f..f38085262ae 100644 --- a/contrib/init/systemd/kube-apiserver.service +++ b/contrib/init/systemd/kube-apiserver.service @@ -2,6 +2,8 @@ Description=Kubernetes API Server Documentation=https://github.com/GoogleCloudPlatform/kubernetes +After=etcd.service + [Service] EnvironmentFile=-/etc/kubernetes/config EnvironmentFile=-/etc/kubernetes/apiserver