<div dir="ltr"><div>Alright, then I'll use Twisted's built-in! But I still have my same question: Should I write a separate file containing all the resources and another file with the server? To deploy a content server on the RPi, do I need to wrap all the files within a .tac file?<br>
<br></div>Joelle<br></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Wed, Jun 19, 2013 at 8:24 PM, Glyph <span dir="ltr"><<a href="mailto:glyph@twistedmatrix.com" target="_blank">glyph@twistedmatrix.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word"><div class="im"><br><div><div>On Jun 19, 2013, at 2:21 PM, Jo as Queeniebee <<a href="mailto:joasqueeniebee@gmail.com" target="_blank">joasqueeniebee@gmail.com</a>> wrote:</div>
<br><blockquote type="cite"><div style="font-family:Menlo-Regular;font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px">
This is great, thanks.<br><br></div><span style="font-family:Menlo-Regular;font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;float:none;display:inline!important">I want to deploy a content server on my Raspberry Pi, do I need to write a separate file for the server/reactor that imports views.py and config.py?</span><br style="font-family:Menlo-Regular;font-size:12px;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px">
</blockquote></div><br></div><div>Given that on a raspberry pi you might be somewhat resource-constrained and concerned about overhead of code resources, have you considered using Twisted's built-in template engine?</div>
<div><br></div><div><<a href="http://twistedmatrix.com/documents/current/web/howto/twisted-templates.html" target="_blank">http://twistedmatrix.com/documents/current/web/howto/twisted-templates.html</a>></div><div><br>
</div><div>You can certainly use Jinja2 with Twisted, but given that Twisted might load this to render some of its own internal content (like directory listings) it might be worthwhile to give it a try.</div><span class="HOEnZb"><font color="#888888"><div>
<br></div><div>-glyph</div></font></span></div><br>_______________________________________________<br>
Twisted-web mailing list<br>
<a href="mailto:Twisted-web@twistedmatrix.com">Twisted-web@twistedmatrix.com</a><br>
<a href="http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-web" target="_blank">http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-web</a><br>
<br></blockquote></div><br></div>