diff options
author | Marcello Stanisci <stanisci.m@gmail.com> | 2019-04-18 15:28:12 +0200 |
---|---|---|
committer | Marcello Stanisci <stanisci.m@gmail.com> | 2019-04-18 15:28:12 +0200 |
commit | 6a784c6c7327be82a840a0b3f5f6a0be296fc8bb (patch) | |
tree | b412bc232ec957e8e0b82935f8328c618daac63f | |
parent | 58652f7c8db018f5a580955dfebdbcfb0bd150f3 (diff) | |
download | deployment-6a784c6c7327be82a840a0b3f5f6a0be296fc8bb.tar.gz deployment-6a784c6c7327be82a840a0b3f5f6a0be296fc8bb.tar.bz2 deployment-6a784c6c7327be82a840a0b3f5f6a0be296fc8bb.zip |
Make separate sites-building directory.
-rw-r--r-- | buildbot/master.cfg | 93 | ||||
-rw-r--r-- | taler-sitesbuild/Makefile | 15 | ||||
-rwxr-xr-x | taler-sitesbuild/invalidate.sh | 27 | ||||
-rwxr-xr-x | taler-sitesbuild/update_doc_landing.sh (renamed from taler-docbuild/update_doc_landing.sh) | 0 | ||||
-rwxr-xr-x | taler-sitesbuild/update_stage.sh (renamed from taler-docbuild/update_stage.sh) | 0 | ||||
-rwxr-xr-x | taler-sitesbuild/update_www.sh (renamed from taler-docbuild/update_www.sh) | 0 |
6 files changed, 132 insertions, 3 deletions
diff --git a/buildbot/master.cfg b/buildbot/master.cfg index 719b58e..c5f20a6 100644 --- a/buildbot/master.cfg +++ b/buildbot/master.cfg @@ -24,17 +24,68 @@ c["buildbotNetUsageData"] = "basic" # password. The same worker name and password must be configured # on the worker. c["workers"] = [ + + ## + # This worker makes the code coverage and publishes it + # under the "lcov" Website. worker.Worker("lcov-worker", "lcov-pass"), + + ## + # Undone. worker.Worker("selenium-worker", "selenium-pass"), + + ## + # This worker builds manuals / API docs / tutorials. + # worker.Worker("doc-worker", "doc-pass"), + + ## + # This worker builds Websites: www/stage & docs-landing. + # + worker.Worker("sites-worker", "sites-pass"), + + ## + # This worker builds Taler for the 'green' color under + # the 'test' deployment. worker.Worker("builder-worker-green", "green-pass"), + + ## + # This worker builds Taler for the 'blue' color under + # the 'test' deployment. worker.Worker("builder-worker-blue", "blue-pass"), + + ## + # This worker cares about switching the 'socket' symlink + # under /home/test; this way we activate the test or blue + # color. worker.Worker("testswitcher-worker", "testswitcher-pass"), + + ## + # Just a debug worker that responds to pushes made at help.git worker.Worker("debug-worker", "debug-pass"), + + ## + # Undone worker.Worker("lint-worker", "lint-pass"), + + ## + # This worker checks that all the services run under the + # 'demo' deployment are up&running. worker.Worker("demo-worker", "demo-pass"), + + ## + # Undone. worker.Worker("wallet-worker", "wallet-pass"), + + ## + # This worker compiles the auditor reports for the "green" + # deployment. worker.Worker("auditor-worker-green", "auditor-green-pass"), + + + ## + # This worker compiles the auditor reports for the "blue" + # deployment. worker.Worker("auditor-worker-blue", "auditor-blue-pass")] # 'protocols' contains information about protocols which master @@ -64,13 +115,21 @@ c["change_source"] = [ALLCS] # Re-build documentation periodically def doc_filter(change): - _changes = change.asDict() - if _changes.get("project") not in ["exchange", "merchant"]: + changes = change.asDict() + if changes.get("project") in ["api", + "www", + "merchant-frontend-examples", + "docs-landing"]: return True + ## + # All the other cases must involve a "doc" file in the + # changes. files = _changes.get("files") for file in files: if re.search(r"doc[s]?|manual", file.get("name", "")): return True + ## + # Must have been triggered by some change to C or Python. return False NIGHTLY_SCHEDULER = schedulers.Nightly( @@ -88,10 +147,20 @@ DOC_SCHEDULER = schedulers.SingleBranchScheduler( branch="master|stable", filter_fn=doc_filter, project_re="backoffice|api|www|bank|exchange|merchant" - "|help|deployment|merchant-frontend-examples" + "|deployment|merchant-frontend-examples" "|docs-landing"), treeStableTimer=None) + +SITES_SCHEDULER = schedulers.SingleBranchScheduler( + name="sites-scheduler", + builderNames=["sites-builder"], + change_filter=util.ChangeFilter( + branch="master|stable", + project_re="www|docs-landing"), + treeStableTimer=None) + + WALLET_SCHEDULER = schedulers.SingleBranchScheduler( name="wallet-scheduler", change_filter=util.ChangeFilter( @@ -164,6 +233,7 @@ c["schedulers"] = [ TIP_RESERVE_TOPPER_SCHEDULER, DEMO_SERVICES_CHECKER_SCHEDULER, DOC_SCHEDULER, + SITES_SCHEDULER, WALLET_SCHEDULER, ALL_SCHEDULER, TESTSWITCHER_SCHEDULER, @@ -360,6 +430,17 @@ DOC_FACTORY.addStep(ShellCommand( workdir="build/buildbot", haltOnFailure=True)) +SITES_FACTORY = util.BuildFactory() +SITES_FACTORY.addStep(git_step( + "git://git.taler.net/deployment.git")) +SITES_FACTORY.addStep(ShellCommand( + name="build Web sites", + description="Building all the Taler homepages", + descriptionDone="Sites built.", + command=["./build-sites.sh"], + workdir="build/buildbot", + haltOnFailure=True)) + DEMO_SERVICES_CHECKER_FACTORY = util.BuildFactory() DEMO_SERVICES_CHECKER_FACTORY.addStep(git_step( "git://git.taler.net/deployment.git")) @@ -486,6 +567,11 @@ DOC_BUILDER = util.BuilderConfig( workernames=["doc-worker"], factory=DOC_FACTORY) +SITES_BUILDER = util.BuilderConfig( + name="sites-builder", + workernames=["sites-worker"], + factory=SITES_FACTORY) + WALLET_BUILDER = util.BuilderConfig( name="wallet-builder", workernames=["wallet-worker"], @@ -500,6 +586,7 @@ c["builders"] = [ DEMO_SERVICES_CHECKER_BUILDER, SELENIUM_BUILDER, DOC_BUILDER, + SITES_BUILDER, WALLET_BUILDER, DEBUG_BUILDER, LINT_BUILDER] diff --git a/taler-sitesbuild/Makefile b/taler-sitesbuild/Makefile new file mode 100644 index 0000000..c30558d --- /dev/null +++ b/taler-sitesbuild/Makefile @@ -0,0 +1,15 @@ +all: www.taler.net-stamp +all: stage.taler.net-stamp +all: docs.taler.net-stamp + +docs.taler.net-stamp: + ./update_doc_landing.sh + touch $@ + +stage.taler.net-stamp: + ./update_stage.sh + touch $@ + +www.taler.net-stamp: + ./update_www.sh + touch $@ diff --git a/taler-sitesbuild/invalidate.sh b/taler-sitesbuild/invalidate.sh new file mode 100755 index 0000000..3cdf46c --- /dev/null +++ b/taler-sitesbuild/invalidate.sh @@ -0,0 +1,27 @@ +#!/bin/bash + +set -eu + +cd $HOME/www +git fetch + +# First check stable. +git checkout -f stable +if git status -sb | grep behind; then + echo "invalidating www.taler.net" + rm -f $HOME/deployment/taler-sitesbuild/www.taler.net-stamp + +# Then master branch. +git checkout -f master +if git status -sb | grep behind; then + echo "invalidating stage.taler.net" + rm -f $HOME/deployment/taler-sitesbuild/stage.taler.net-stamp + + +# Check docs-landing. +cd $HOME/docs-landing +git fetch +if git status -sb | grep behind; then + echo "invalidating stage.taler.net" + rm -f $HOME/deployment/taler-sitesbuild/docs.taler.net-stamp + diff --git a/taler-docbuild/update_doc_landing.sh b/taler-sitesbuild/update_doc_landing.sh index 6293b6f..6293b6f 100755 --- a/taler-docbuild/update_doc_landing.sh +++ b/taler-sitesbuild/update_doc_landing.sh diff --git a/taler-docbuild/update_stage.sh b/taler-sitesbuild/update_stage.sh index b57d4f0..b57d4f0 100755 --- a/taler-docbuild/update_stage.sh +++ b/taler-sitesbuild/update_stage.sh diff --git a/taler-docbuild/update_www.sh b/taler-sitesbuild/update_www.sh index f63d9a6..f63d9a6 100755 --- a/taler-docbuild/update_www.sh +++ b/taler-sitesbuild/update_www.sh |