<div dir="auto">Don't forget to reply to the ML too :-)<div dir="auto"><br></div><div dir="auto">No need to return hash, because you already returned synthetic in that case.</div><div dir="auto"><br></div><div dir="auto">By the way, Dridi told me that vcl actually support "else if", "elsif" and "elif", so you can disregard my remark about it.</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mar 16, 2017 15:28, "Rodney Bizzell" <<a href="mailto:rbizzell@measinc.com">rbizzell@measinc.com</a>> wrote:<br type="attribution"><blockquote class="quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div lang="EN-US" link="blue" vlink="purple">
<div class="m_7190240714567929762WordSection1">
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d">Appreciate your help. One question the else {<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"> <wbr> <wbr> Return(synth(404));<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"> <wbr> <wbr> }<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d">Do I add the return hash underneath it<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d">}<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d">}<u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri",sans-serif;color:#1f497d"><u></u> <u></u></span></p>
<p class="MsoNormal"><b><span style="font-size:11.0pt;font-family:"Calibri",sans-serif">From:</span></b><span style="font-size:11.0pt;font-family:"Calibri",sans-serif"> Guillaume Quintard [mailto:<a href="mailto:guillaume@varnish-software.com" target="_blank">guillaume@varnish-<wbr>software.com</a>]
<br>
<b>Sent:</b> Thursday, March 16, 2017 4:16 AM<br>
<b>To:</b> Rodney Bizzell <<a href="mailto:rbizzell@measinc.com" target="_blank">rbizzell@measinc.com</a>><br>
<b>Cc:</b> <a href="mailto:varnish-misc@varnish-cache.org" target="_blank">varnish-misc@varnish-cache.org</a><br>
<b>Subject:</b> Re: Redirecting traffic to Varnish Cache Server<u></u><u></u></span></p><div class="elided-text">
<p class="MsoNormal"><u></u> <u></u></p>
<div>
<p class="MsoNormal">Hi,<u></u><u></u></p>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<p class="MsoNormal">"elsif" needs to be "else if", and I would add:<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<p class="MsoNormal">else {<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"> return(synth(404));<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal">}<u></u><u></u></p>
</div>
<div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<div>
<p class="MsoNormal">at the end to make sure you only serve content from these two domains.<u></u><u></u></p>
</div>
</div>
<div>
<p class="MsoNormal"><br clear="all">
<u></u><u></u></p>
<div>
<div>
<div>
<div>
<p class="MsoNormal">-- <u></u><u></u></p>
</div>
<p class="MsoNormal">Guillaume Quintard<u></u><u></u></p>
</div>
</div>
</div>
<p class="MsoNormal"><u></u> <u></u></p>
<div>
<p class="MsoNormal">On Tue, Mar 14, 2017 at 9:46 PM, Rodney Bizzell <<a href="mailto:rbizzell@measinc.com" target="_blank">rbizzell@measinc.com</a>> wrote:<u></u><u></u></p>
<blockquote style="border:none;border-left:solid #cccccc 1.0pt;padding:0in 0in 0in 6.0pt;margin-left:4.8pt;margin-right:0in">
<div>
<div>
<p class="MsoNormal">So I have setup a basic default.vcl and my question how do I get the Varnish server to answer web request before going to the backend drupal servers not sure if I am stating this
correctly. Our DNS admin point the urls to Varnish server but I am getting page not found. Am I missing a config in the default.vcl? Thanks! I researched and I am not seeing any good information.<u></u><u></u></p>
<p class="MsoNormal"> <u></u><u></u></p>
<p class="MsoNormal">backend drupal {<u></u><u></u></p>
<p class="MsoNormal"> .host = "<a href="http://drupal.miat.co" target="_blank">drupal.miat.co</a>";<u></u><u></u></p>
<p class="MsoNormal"> .port = "80";<u></u><u></u></p>
<p class="MsoNormal"> .connect_timeout = 6000s;<u></u><u></u></p>
<p class="MsoNormal"> .first_byte_timeout = 6000s;<u></u><u></u></p>
<p class="MsoNormal"> .between_bytes_timeout = 6000s;<u></u><u></u></p>
<p class="MsoNormal">}<u></u><u></u></p>
<p class="MsoNormal"> <u></u><u></u></p>
<p class="MsoNormal">backend ncwrite {<u></u><u></u></p>
<p class="MsoNormal"> .host = "<a href="http://ncwrite.miat.co" target="_blank">ncwrite.miat.co</a>";<u></u><u></u></p>
<p class="MsoNormal"> .port = "80";<u></u><u></u></p>
<p class="MsoNormal"> .connect_timeout = 6000s;<u></u><u></u></p>
<p class="MsoNormal"> .first_byte_timeout = 6000s;<u></u><u></u></p>
<p class="MsoNormal"> .between_bytes_timeout = 6000s;<u></u><u></u></p>
<p class="MsoNormal">}<u></u><u></u></p>
<p class="MsoNormal"> <u></u><u></u></p>
<p class="MsoNormal">sub vcl_recv {<u></u><u></u></p>
<p class="MsoNormal"> if (req.http.host == "<a href="http://drupal.miat.co" target="_blank">drupal.miat.co</a>"){<u></u><u></u></p>
<p class="MsoNormal"> set req.backend_hint = drupal;<u></u><u></u></p>
<p class="MsoNormal"> } elsif (req.http.host == "<a href="http://ncwrite.miat.co" target="_blank">ncwrite.miat.co</a>"){<u></u><u></u></p>
<p class="MsoNormal"> set req.backend_hint = ncwrite;<u></u><u></u></p>
<p class="MsoNormal"> return (hash);<u></u><u></u></p>
<p class="MsoNormal"> }<u></u><u></u></p>
<p class="MsoNormal">}<u></u><u></u></p>
<p class="MsoNormal"> <u></u><u></u></p>
</div>
<p class="MsoNormal"><br>
<span style="font-size:10.0pt;font-family:"Arial",sans-serif;color:gray"><br>
This email (including any attachments) may contain confidential information intended solely for acknowledged recipients. If you think you have received this information in error, please reply to the sender and delete all copies from your system. Please note
that unauthorized use, disclosure, or further distribution of this information is prohibited by the sender. Note also that we may monitor email directed to or originating from our network. Thank you for your consideration and assistance. |</span><u></u><u></u></p>
</div>
<p class="MsoNormal"><br>
______________________________<wbr>_________________<br>
varnish-misc mailing list<br>
<a href="mailto:varnish-misc@varnish-cache.org" target="_blank">varnish-misc@varnish-cache.org</a><br>
<a href="https://www.varnish-cache.org/lists/mailman/listinfo/varnish-misc" target="_blank">https://www.varnish-cache.org/<wbr>lists/mailman/listinfo/<wbr>varnish-misc</a><u></u><u></u></p>
</blockquote>
</div>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
</div></div>
</div>
</blockquote></div><br></div>