Closed Bug 324893 Opened 20 years ago Closed 20 years ago

make www.bugzilla.org site static

Categories

(mozilla.org Graveyard :: Server Operations: Projects, task, P2)

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: spam, Assigned: justdave)

References

()

Details

Attachments

(6 files, 3 obsolete files)

<justdave> that's what I really want to do is get bugzilla.org using the same build system that mozilla.com is using right now actually this is done on www.bugzilla.jp already ;-)
Attached file ttree.cfg example —
installation-list/ needs copy(and let page.cgi process it) but i couldn't do this.. it may the filename(only installation-list/index.html.tmpl) change needed below line means that filename itself copy = index.tmpl$
Attached patch patch for installation-list/ (obsolete) — — Splinter Review
changes for installation-list/index.html.tmpl are all escapeing TT start tags. I didn't test about .htaccess though, all files other than the file are static, so the change means to process only installation-list/index.html.tmpl
Severity: normal → enhancement
Moving to Server Ops since this is going to require script changes on the production webserver. (In reply to comment #4) > Created an attachment (id=213246) [edit] > make download/index easy-care Can we move this patch to a new bug? It really has very little to do with fixing up the site build scripts.
Assignee: justdave → justdave
Component: bugzilla.org → Server Operations
Priority: -- → P3
Product: Bugzilla → mozilla.org
QA Contact: default-qa → justin
Version: 2.18 → other
Component: Server Operations → Server Operations Projects
Priority: P3 → P2
OK, I got some server-side stuff done in support of this... I've created a new top-level module on cvs-www called "bugzilla-org". In it, I've imported a stub copy of the build system in use on mozilla.com. This build system is already template-toolkit based, but builds the templates into html ahead of time so the webserver is only serving static pages. Converting our existing templates to build with it should be pretty trivial. Here's what needs to happen now: I need a list compiled of files from the existing bugzilla-org cvs that need to be moved. See the format of existing bugs in the CVS Copies component of the mozilla.org product for examples. Not all of the files will need to be moved. Someone's going to have to convert the templates first to see which ones work. The filenames given in the move/copy script will need to include the leading mozilla-org/ or bugzilla-org in the pathnames. When you figure out this list, please file a bug in mozilla.org/CVS Copies and attach the script, and make it block this bug. Things to keep in mind for the build system: Docs build: Our new docs build system needs a copy of the Bugzilla source from the same branch to pull dependencies from. We'll probably have to include a specific checkout to a temp directory (or create one within the build directory) in our build script, check out the entirety of the bugzilla source instead of just the docs directory, then copy the final built docs to the correct place in dest/ after it's built. I'd suggest something like: bzsource/2.20/ bzsource/2.22/ bzsource/tip/ etc. Note this directory shouldn't get checked into the website cvs, it should just be checked out/updated and built by the build scripts.
<justdave> we just need to make sure installation-list/index.html gets listed as having installation-list.txt as a dependency in the dep config <justdave> so that way a change to installation-list.txt will trigger the html file to get rebuilt this file can be updated every time site update runs using this: ttree -f etc/ttree.cfg -a installation-list/index.html.tmpl # -a flag forces rebuild regardless of whether the original file updated or not. [% USE thefile = File("installation-list/installation-list.txt") %] line may need to be changed though, files that require to be changed are for inc/* and ttree.cfg. other content files don't require to be changed at all to build current site, and most of the files currently in the cvs are NOT required. or, do you want some other stuff?
Summary: make www.bugzilla.org site (almost)static → make www.bugzilla.org site static
(In reply to comment #6) > Docs build: Our new docs build system needs a copy of the Bugzilla source from > the same branch to pull dependencies from. We'll probably have to include a > specific checkout to a temp directory (or create one within the build > directory) in our build script, check out the entirety of the bugzilla source > instead of just the docs directory, then copy the final built docs to the > correct place in dest/ after it's built. We also now general our POD docs from the source, so it definetly needs the full source code. I'm guessing anything about our XML API will also be built from the source...
(In reply to comment #7) \> this file can be updated every time site update runs using this: > ttree -f etc/ttree.cfg -a installation-list/index.html.tmpl > # -a flag forces rebuild regardless of whether the original file updated or > not. There's also a dependency tree in etc/ttree.dep that you can add it to so it only gets updated when it's changed.
Depends on: 354776
ok, cvs copies are done, so the content is there. Note that you may need to nuke your index.html and favicon.ico files (or you may not) since I had to replace the RCS files that were there with the ones we were moving. Now to make it build. :)
Should things like the checkout of the source code etc. be within the new Website Module building code?
this requires src changes, process directive must be nuked from src html.
Attachment #209799 - Attachment is obsolete: true
Attachment #209836 - Attachment is obsolete: true
+ <a href="[% c.url ? c.url : docroot %]">[% crumb.title %]</a> [% "&#187;" UNLESS loop.last() %] s/c.url/c_url/g;
(In reply to comment #11) > Should things like the checkout of the source code etc. be within the new > Website Module building code? yes.
just remove (INCLUDE|PROCESS) inc/* lines this is minimum changes to use wrapper. now the build system can extract title from sitemap.xml and each of the file (order: title element defined in the file itself -> title attribute defined in sitemap.xml -> filename(extension will be stripped) ), so TT directive top of each files can be replaced with normal html headers if you prefer.
Comment on attachment 240631 [details] [diff] [review] lib/ part patch for new bugzilla-org repos ok, do we have a script somewhere that generates sitemap.xml from the files that are actually present? Otherwise that looks like a PITA to maintain... just from the inconsistancy in the status update titles I suspect you used a script to make this one. :)
> ok, do we have a script somewhere that generates sitemap.xml from the files > that are actually present? Otherwise that looks like a PITA to maintain... > just from the inconsistancy in the status update titles I suspect you used a > script to make this one. :) no, sitemap.xml was wrote by copy&paste'd. so there's a typo on 'installation-...' ;-) writing entire structure is needed only the first. and later, adding some files is only a few work. and when there's no entry, defect is only lack of navigation links, such as ' Home » Release Information » Bugzilla 2.18 ' under header. # and it can have different structure from real, like wmc ;-)y
Attached patch build-docs.pl (obsolete) — — Splinter Review
Here's the build-docs.pl script that will build the docs and put them in the appropriate place in the web site.
Here's a bugzilla/ directory that you could put on the live site, for build-docs.pl. It goes in the root of build space, at the same level as bin/, src/, etc: http://landfill.bugzilla.org/bugzilla.tar.bz2
Oh, and I forgot to mention: You have to do --force the first time you run the script. That makes it build the docs even though there haven't been any cvs updates.
Attached patch build-docs.pl v2 — — Splinter Review
Okay, reed pointed out a few errors in the script, and this version fixes them.
Attachment #241242 - Attachment is obsolete: true
OK, I just flipped the config over in CVS. I made some major changes to the build script, and committed. made a config file to list the bugzilla versions and branches to pull instead of having to unpack a starter tarball, and had the script just check it out from scratch if it wasn't there. Also imported the build_full script from mozilla-com to rebuild the site from scratch daily in order to handle deletes (since ttree won't delete things from the destination). A full site build from scratch with --force and so forth takes about 10 minutes.
Status: NEW → RESOLVED
Closed: 20 years ago
Resolution: --- → FIXED
if you don't plan to use special structure such as moz-com does, and only 'real' structure, no need to use sitemap and xml module.
Product: mozilla.org → mozilla.org Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: