Here is the error:
Job started: Index_Update_IndexName=Coveo_web_index|#Exception: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> Coveo.Framework.Utils.Rest.HttpClientException: Failed to obtain resource located at 'http://DOMAIN.com/coveo/rest?indexName=Coveo_web_index'.
[BEGIN RESPONSE BODY]<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"/>
<title>502 - Web server received an invalid response while acting as a gateway or proxy server.</title>
<style type="text/css">
<!--
body{margin:0;font-size:.7em;font-family:Verdana, Arial, Helvetica, sans-serif;background:#EEEEEE;}
fieldset{padding:0 15px 10px 15px;}
h1{font-size:2.4em;margin:0;color:#FFF;}
h2{font-size:1.7em;margin:0;color:#CC0000;}
h3{font-size:1.2em;margin:10px 0 0 0;color:#000000;}
#header{width:96%;margin:0 0 0 0;padding:6px 2% 6px 2%;font-family:"trebuchet MS", Verdana, sans-serif;color:#FFF;
background-color:#555555;}
#content{margin:0 0 0 2%;position:relative;}
.content-container{background:#FFF;width:96%;margin-top:8px;padding:10px;position:relative;}
-->
</style>
</head>
<body>
<div id="header"><h1>Server Error</h1></div>
<div id="content">
<div class="content-container"><fieldset>
<h2>502 - Web server received an invalid response while acting as a gateway or proxy server.</h2>
<h3>There is a problem with the page you are looking for, and it cannot be displayed. When the Web server (while acting as a gateway or proxy) contacted the upstream content server, it received an invalid response from the content server.</h3>
</fieldset></div>
</div>
</body>
</html>
[END RESPONSE BODY] ---> System.Net.WebException: The remote server returned an error: (502) Bad Gateway.
at System.Net.HttpWebRequest.GetResponse()
at Coveo.Framework.Utils.Rest.HttpClient.ExecuteRequest(String p_Url, HttpWebRequest p_Request, Int64 p_CallId)
--- End of inner exception stack trace ---
at Coveo.Framework.Utils.Rest.HttpClient.ExecuteRequest(String p_Url, HttpWebRequest p_Request, Int64 p_CallId)
at Coveo.Framework.Utils.Rest.HttpClient.PostRaw(String p_Url, String p_Body)
at Coveo.Framework.Utils.Rest.HttpClient.Post(String p_Url, String p_Body)
at Coveo.SearchServiceProvider.Rest.ClientSessionWrapper.ExecuteQuery(QueryParams p_QueryParams)
at Coveo.AbstractLayer.Communication.CES.CESCommunication.<>c__DisplayClass3b.<CreateDeletedDocumentsPoller>b__3a()
at Coveo.Framework.Synchronization.Poller.WaitUntilComplete()
at Coveo.AbstractLayer.Communication.CES.CESCommunication.StopRebuild(RebuildContext p_Context)
at Coveo.SearchProvider.ProviderIndexBase.PerformRebuild(IProviderUpdateContext p_Context, Action`1 p_CrawlerAction)
at Coveo.SearchProvider.ProviderIndexBase.Rebuild(IndexingOptions p_IndexingOptions, IProviderUpdateContext p_Context, Action`1 p_CrawlerAction)
at Coveo.SearchProvider.ProviderIndex.TryPerformIndexingOperation(IndexingOptions p_IndexingOptions, Action p_Action)
at Coveo.SearchProvider.ProviderIndex.Rebuild()
--- End of inner exception stack trace ---
at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor)
at System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments)
at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
at Sitecore.Reflection.ReflectionUtil.InvokeMethod(MethodInfo method, Object[] parameters, Object obj)
at Sitecore.Jobs.JobRunner.RunMethod(JobArgs args)
at (Object , Object[] )
at Sitecore.Pipelines.CorePipeline.Run(PipelineArgs args)
at Sitecore.Jobs.Job.ThreadEntry(Object state)