English 中文(简体)
Can Buildingbot WebStatus被定制,以回收案文/html以外的内容。
原标题:Can Buildbot WebStatus be customized to return content type other than text/html
  • 时间:2012-01-12 08:56:39
  •  标签:
  • buildbot

作为我大楼的最后一个步骤,我已经采取文件上载步骤,将成果上载到主人手中,并利用建筑局网络Status部分,为取得成果服务(本案的原始档案)。 不幸的是,所有档案的网页总收复文本/html内容类型。 是否可能配置网络功能,以便根据这一信息重新确定文件延期和返回内容类型。

最佳回答

Buildingbot use twisted.web.static.File to services content from the public_htmlDirectory. 看看来文方,这使用/etc/mime。 按违约类型分类,获取气象类型信息。 这样做没有直接办法。

问题回答

当然,possible - “建筑商”完全是用斯图尔写成的,因此,你必须做的是把源头或子流放到你的主编中,以压倒适当的方法。

。 如果你 re。 建筑商使用Twisted asynchronous方案规划图书馆。

然而,这并不是网上Status的内在特征,因此,添加了would,涉及书写法,而不仅仅是一个公尺的改动。

正如其他答复所示,没有解决该问题的直接组合。 但是,你可以使用一个简单的子类来改变违约内容类型,这至少会使案文/解释不成为案文/案文/html的延伸内容。

class WebStatusWithTextDefault(html.WebStatus):
    def setupSite(self):
        result = html.WebStatus.setupSite(self)
        self.site.resource.defaultType = "text/plain"
        return result

取代提及html。 您的主.cfg与这一班子的网络,你应当好。

正如其他人所指出的,建筑商的用途如下:twisted.web.static.File。 这份清单从/etc/mime.型号中编制。 你可以简单地从你的主编中扩大这一名单,因为它只是一个静态的口号。

页: 1 确实如此:将猪肉延伸定义为甲状腺包。 你可以像你所希望的那样多加一,或者简单地改变现有的。

  import twisted.web.static
  twisted.web.static.File.contentTypes[ .apk ] =  application/vnd.android.package-archive 




相关问题
buildbot on windows as a service

After following the suggestions outlined on their website on how to set up buildbot on windows, I m left with one last question - I have multiple slaves and one master all set up on one computer (they ...

Buildbot 0.8.1 inactive for 2 minutes before building

My apologies if this has been answered before - I can t seem to find any previous q&a on this. I run buildbot 0.8.1 and use PBChangeSource() to receive changes from svn. Problem is a build will ...

Exceptions from Buildbots PeriodicScheduler intervals?

Buildbots Periodic scheduler triggers builds at fixed intervals (e.g. every 30 minutes). But there are certain times (e.g. at night, during the weekend or while regular maintenance is performed) where ...

run buildbot on Windows XP

I recently stumbled over buildbot and wanted to give it a try. My problem is that I have to run it under Windows because we don t use Linux on workstations or servers in my company. I ve already ...

buildbot: run SVNPoller with --trust-server-cert

I asked this similar question and got a satisfactory answer. However, doing the same with SVNPoller doesn t work. So how can I pass --trust-server-cert as an extra param to SVNPoller in buildbot

buildbot: run svn with --trust-server-cert

I am trying to install buildbot for my project. I always run my svn commands with trust-server-cert option. How can I pass that to SVN thru buildbot? I don t see there is a way for doing that. What ...

热门标签