nginx.conf file in inf format or any other template based format would have been the easiest thing to do. perhaps future version of nginx can go down this route.<br><br><div class="gmail_quote">On Mon, May 3, 2010 at 9:12 PM, Michael Shadle <span dir="ltr">&lt;<a href="mailto:mike503@gmail.com">mike503@gmail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div bgcolor="#FFFFFF"><div>I have a php command line script that builds separate conf files in one of my servers and does simple string replacement.</div>
<div><br></div><div>Also remember you can use includes so you can leave the main nginx.conf alone and have it include stuff from another directory you write out..</div><div><div></div><div class="h5"><div><br></div><div><br>
On May 3, 2010, at 6:24 AM, Luca De Marinis &lt;<a href="mailto:loop@interact.it" target="_blank">loop@interact.it</a>&gt; wrote:<br><br></div><div></div><blockquote type="cite"><div><div class="gmail_quote">On Mon, May 3, 2010 at 3:07 PM, Ziyad Saeed <span dir="ltr">&lt;<a href="mailto:myschizobuddy@gmail.com" target="_blank"></a><a href="mailto:myschizobuddy@gmail.com" target="_blank">myschizobuddy@gmail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
So I store the configuration in a database or xml file or whatever, and then generate the conf file from it.<div>thank you.</div></blockquote><div><br></div><div>Also, using a templating system with a scripting language (say, erb + ruby or whatever you&#39;re comfortable with) or the good old m4 may be viable, and probably simpler to use and implement. This is very easy and very convenient if you have to generate lots of different configurations (say, for n virtual hosts, or n virtual hosts on n servers) but which all share a limited number of prototype configurations.</div>

<div><br></div><div>Bye</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div><div></div><div><br><br><div class="gmail_quote">On Mon, May 3, 2010 at 3:14 AM, Gabriel Evans <span dir="ltr">&lt;<a href="mailto:me@gabevans.com" target="_blank"></a><a href="mailto:me@gabevans.com" target="_blank">me@gabevans.com</a>&gt;</span> wrote:<br>


<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><font size="2"><font face="verdana,sans-serif">There&#39;s no API that I know of, unless you want to make your own module. You could try having a separate directory for virtual hosts included and use a database to store and generate the configuration. It&#39;d be a lot easier</font></font> than trying to interpret the configuration as well.<br>




<br><div class="gmail_quote"><div>On Sun, May 2, 2010 at 4:21 AM, Ziyad Saeed <span dir="ltr">&lt;<a href="mailto:myschizobuddy@gmail.com" target="_blank"></a><a href="mailto:myschizobuddy@gmail.com" target="_blank">myschizobuddy@gmail.com</a>&gt;</span> wrote:<br>
</div>
<blockquote class="gmail_quote" style="margin:0pt 0pt 0pt 0.8ex;border-left:1px solid rgb(204, 204, 204);padding-left:1ex"><div>

<br><div>Inorder to make a simple UI for editing nginx.conf. I need a way to edit nginx.conf without having to open it up in a text editor. Does nginx have an api that i can use to edit information that is inside nginx.conf. This will help newbies add virtual host information and edit parameters via a UI.</div>





</div></blockquote></div></blockquote></div></div></div></div></blockquote></div><br><div><br></div>
</div></blockquote></div></div><div class="im"><blockquote type="cite"><div><span>_______________________________________________</span><br><span>nginx mailing list</span><br><span><a href="mailto:nginx@nginx.org" target="_blank">nginx@nginx.org</a></span><br>
<span><a href="http://nginx.org/mailman/listinfo/nginx" target="_blank">http://nginx.org/mailman/listinfo/nginx</a></span><br></div></blockquote></div></div><br>_______________________________________________<br>
nginx mailing list<br>
<a href="mailto:nginx@nginx.org">nginx@nginx.org</a><br>
<a href="http://nginx.org/mailman/listinfo/nginx" target="_blank">http://nginx.org/mailman/listinfo/nginx</a><br>
<br></blockquote></div><br>