bug 1244781 - stop running purge_builds in mozharness. r=jlund

This commit is contained in:
Aki Sasaki 2016-02-02 10:03:36 -05:00
parent bea50c52e8
commit 9ad1daaaa2
63 changed files with 2 additions and 436 deletions

View File

@ -26,8 +26,6 @@ config = {
"buildbot": "/tools/buildbot/bin/buildbot",
},
'app_ini_path': '%(obj_dir)s/dist/bin/application.ini',
'purge_skip': ['info', 'rel-*:10d', 'tb-rel-*:10d'],
'purge_basedirs': ["/mock/users/cltbld/home/cltbld/build"],
# mock shtuff
'mock_mozilla_dir': '/builds/mock_mozilla',
'mock_target': 'mozilla-centos6-x86_64',
@ -85,7 +83,6 @@ config = {
'UPLOAD_SSH_KEY': '/home/mock_mozilla/.ssh/%(stage_ssh_key)s',
'UPLOAD_TO_TEMP': '1',
},
'purge_minsize': 14,
'mock_packages': [
'autoconf213', 'python', 'mozilla-python27', 'zip', 'mozilla-python27-mercurial',
'git', 'ccache', 'perl-Test-Simple', 'perl-Config-General',

View File

@ -23,8 +23,6 @@ config = {
"buildbot": "/tools/buildbot/bin/buildbot",
},
'app_ini_path': '%(obj_dir)s/dist/bin/application.ini',
'purge_skip': ['info', 'rel-*:10d', 'tb-rel-*:10d'],
'purge_basedirs': [],
'enable_ccache': True,
'vcs_share_base': '/builds/hg-shared',
'objdir': 'obj-firefox',
@ -72,7 +70,6 @@ config = {
'MINIDUMP_STACKWALK': '%(abs_tools_dir)s/breakpad/osx64/minidump_stackwalk',
'MINIDUMP_SAVE_PATH': '%(base_work_dir)s/minidumps',
},
'purge_minsize': 12,
'src_mozconfig': 'b2g/config/mozconfigs/macosx64_gecko/nightly',
'tooltool_manifest_src': 'b2g/config/tooltool-manifests/macosx64/releng.manifest',
#########################################################################

View File

@ -49,8 +49,6 @@ config = {
],
},
'app_ini_path': '%(obj_dir)s/dist/bin/application.ini',
'purge_skip': ['info', 'rel-*:10d', 'tb-rel-*:10d'],
'purge_basedirs': [],
'enable_ccache': False,
'vcs_share_base': 'C:\\builds\\hg-shared',
'objdir': 'obj-firefox',
@ -94,7 +92,6 @@ config = {
'MINIDUMP_SAVE_PATH': '%(base_work_dir)s/minidumps',
},
'enable_pymake': True,
'purge_minsize': 12,
'src_mozconfig': 'b2g/config/mozconfigs/win32_gecko/nightly',
'tooltool_manifest_src': "b2g/config/tooltool-manifests/win32/releng.manifest",
#########################################################################

View File

@ -70,7 +70,6 @@ config = {
"WGET_OPTS": "-c -q",
"PATH": "/tools/python27/bin:%(PATH)s",
},
"purge_minsize": 20,
"clobberer_url": "https://api.pub.build.mozilla.org/clobberer/lastclobber",
"is_automation": True,
"repo_mirror_dir": "/builds/git-shared/repo",

View File

@ -73,7 +73,6 @@ config = {
"PATH": "/tools/python27/bin:%(PATH)s",
"B2G_UPDATE_CHANNEL": "default",
},
"purge_minsize": 15,
"clobberer_url": "https://api.pub.build.mozilla.org/clobberer/lastclobber",
"is_automation": True,
"variant": "eng",

View File

@ -69,7 +69,6 @@ config = {
"WGET_OPTS": "-c -q",
"PATH": "/tools/python27/bin:%(PATH)s",
},
"purge_minsize": 15,
"clobberer_url": "https://api.pub.build.mozilla.org/clobberer/lastclobber",
"is_automation": True,
"repo_mirror_dir": "/builds/git-shared/repo",

View File

@ -73,7 +73,6 @@ config = {
"PATH": "/tools/python27/bin:%(PATH)s",
"B2G_UPDATE_CHANNEL": "default",
},
"purge_minsize": 15,
"clobberer_url": "https://api.pub.build.mozilla.org/clobberer/lastclobber",
"is_automation": True,
"variant": "eng",

View File

@ -68,7 +68,6 @@ config = {
"WGET_OPTS": "-c -q",
"PATH": "/tools/python27/bin:%(PATH)s",
},
"purge_minsize": 15,
"clobberer_url": "https://api.pub.build.mozilla.org/clobberer/lastclobber",
"is_automation": True,
"repo_mirror_dir": "/builds/git-shared/repo",

View File

@ -69,7 +69,6 @@ config = {
"WGET_OPTS": "-c -q",
"PATH": "/tools/python27/bin:%(PATH)s",
},
"purge_minsize": 15,
"clobberer_url": "https://api.pub.build.mozilla.org/clobberer/lastclobber",
"is_automation": True,
"repo_mirror_dir": "/builds/git-shared/repo",

View File

@ -37,7 +37,6 @@ config = {
"WGET_OPTS": "-c -q",
"PATH": "/tools/python27/bin:%(PATH)s",
},
"purge_minsize": 20,
#"clobberer_url": "https://api-pub-build.allizom.org/clobberer/lastclobber",
#"clobberer_url": "https://api.pub.build.mozilla.org/clobberer/lastclobber",
"is_automation": True,

View File

@ -4,7 +4,7 @@
config = {
"staging": {
# if not clobberer_url, only clobber 'abs_work_dir'
# if true: possibly clobber, clobberer, and purge_builds
# if true: possibly clobber, clobberer
# see PurgeMixin for clobber() conditions
'clobberer_url': 'https://api-pub-build.allizom.org/clobberer/lastclobber',
# staging we should use MozillaTest
@ -23,7 +23,7 @@ config = {
},
"production": {
# if not clobberer_url, only clobber 'abs_work_dir'
# if true: possibly clobber, clobberer, and purge_builds
# if true: possibly clobber, clobberer
# see PurgeMixin for clobber() conditions
'clobberer_url': 'https://api.pub.build.mozilla.org/clobberer/lastclobber',
'graph_server': 'graphs.mozilla.org',

View File

@ -25,8 +25,6 @@ config = {
'app_ini_path': '%(obj_dir)s/dist/bin/application.ini',
# decides whether we want to use moz_sign_cmd in env
'enable_signing': True,
'purge_skip': ['info', 'rel-*:10d', 'tb-rel-*:10d'],
'purge_basedirs': ["/mock/users/cltbld/home/cltbld/build"],
# mock shtuff
'mock_mozilla_dir': '/builds/mock_mozilla',
'mock_target': 'mozilla-centos6-x86_64-android',
@ -93,7 +91,6 @@ config = {
'MINIDUMP_STACKWALK': '%(abs_tools_dir)s/breakpad/linux/minidump_stackwalk',
'MINIDUMP_SAVE_PATH': '%(base_work_dir)s/minidumps',
},
'purge_minsize': 12,
'mock_packages': ['autoconf213', 'mozilla-python27-mercurial', 'yasm',
'ccache', 'zip', "gcc472_0moz1", "gcc473_0moz1",
'java-1.7.0-openjdk-devel', 'zlib-devel',

View File

@ -30,8 +30,6 @@ config = {
'app_ini_path': '%(obj_dir)s/dist/bin/application.ini',
# decides whether we want to use moz_sign_cmd in env
'enable_signing': True,
'purge_skip': ['info', 'rel-*:10d', 'tb-rel-*:10d'],
'purge_basedirs': ["/mock/users/cltbld/home/cltbld/build"],
# mock shtuff
'mock_mozilla_dir': '/builds/mock_mozilla',
'mock_target': 'mozilla-centos6-x86_64',
@ -101,7 +99,6 @@ config = {
'MINIDUMP_STACKWALK': '%(abs_tools_dir)s/breakpad/linux/minidump_stackwalk',
'MINIDUMP_SAVE_PATH': '%(base_work_dir)s/minidumps',
},
'purge_minsize': 12,
'mock_packages': [
'autoconf213', 'python', 'mozilla-python27', 'zip', 'mozilla-python27-mercurial',
'git', 'ccache', 'perl-Test-Simple', 'perl-Config-General',

View File

@ -30,8 +30,6 @@ config = {
'app_ini_path': '%(obj_dir)s/dist/bin/application.ini',
# decides whether we want to use moz_sign_cmd in env
'enable_signing': True,
'purge_skip': ['info', 'rel-*:10d', 'tb-rel-*:10d'],
'purge_basedirs': ["/mock/users/cltbld/home/cltbld/build"],
# mock shtuff
'mock_mozilla_dir': '/builds/mock_mozilla',
'mock_target': 'mozilla-centos6-x86_64',
@ -103,7 +101,6 @@ config = {
'MINIDUMP_STACKWALK': '%(abs_tools_dir)s/breakpad/linux64/minidump_stackwalk',
'MINIDUMP_SAVE_PATH': '%(base_work_dir)s/minidumps',
},
'purge_minsize': 14,
'mock_packages': [
'autoconf213', 'python', 'mozilla-python27', 'zip', 'mozilla-python27-mercurial',
'git', 'ccache', 'perl-Test-Simple', 'perl-Config-General',

View File

@ -28,8 +28,6 @@ config = {
'app_ini_path': '%(obj_dir)s/dist/bin/application.ini',
# decides whether we want to use moz_sign_cmd in env
'enable_signing': True,
'purge_skip': ['info', 'rel-*:10d', 'tb-rel-*:10d'],
'purge_basedirs': [],
'enable_ccache': True,
'vcs_share_base': '/builds/hg-shared',
'objdir': 'obj-firefox/x86_64',
@ -85,7 +83,6 @@ config = {
'MINIDUMP_STACKWALK': '%(abs_tools_dir)s/breakpad/osx64/minidump_stackwalk',
'MINIDUMP_SAVE_PATH': '%(base_work_dir)s/minidumps',
},
'purge_minsize': 12,
'src_mozconfig': 'browser/config/mozconfigs/macosx-universal/nightly',
'tooltool_manifest_src': 'browser/config/tooltool-manifests/macosx64/releng.manifest',
#########################################################################

View File

@ -24,8 +24,6 @@ config = {
'app_ini_path': '%(obj_dir)s/dist/bin/application.ini',
# decides whether we want to use moz_sign_cmd in env
'enable_signing': True,
'purge_skip': ['info', 'rel-*:10d', 'tb-rel-*:10d'],
'purge_basedirs': [],
'enable_ccache': True,
'enable_check_test': False,
'vcs_share_base': '/builds/hg-shared',
@ -80,7 +78,6 @@ config = {
'MINIDUMP_STACKWALK': '%(abs_tools_dir)s/breakpad/linux64/minidump_stackwalk',
'MINIDUMP_SAVE_PATH': '%(base_work_dir)s/minidumps',
},
'purge_minsize': 12,
'src_mozconfig': 'browser/config/mozconfigs/macosx64/nightly',
'tooltool_manifest_src': 'browser/config/tooltool-manifests/macosx64/cross-releng.manifest',
#########################################################################

View File

@ -48,8 +48,6 @@ config = {
'app_ini_path': '%(obj_dir)s/dist/bin/application.ini',
# decides whether we want to use moz_sign_cmd in env
'enable_signing': True,
'purge_skip': ['info', 'rel-*:10d', 'tb-rel-*:10d'],
'purge_basedirs': [],
'enable_ccache': False,
'vcs_share_base': 'C:/builds/hg-shared',
'objdir': 'obj-firefox',
@ -101,7 +99,6 @@ config = {
'MINIDUMP_SAVE_PATH': '%(base_work_dir)s/minidumps',
},
'enable_pymake': True,
'purge_minsize': 12,
'src_mozconfig': 'browser/config/mozconfigs/win32/nightly',
'tooltool_manifest_src': "browser/config/tooltool-manifests/win32/releng.manifest",
#########################################################################

View File

@ -48,8 +48,6 @@ config = {
'app_ini_path': '%(obj_dir)s/dist/bin/application.ini',
# decides whether we want to use moz_sign_cmd in env
'enable_signing': True,
'purge_skip': ['info', 'rel-*:10d', 'tb-rel-*:10d'],
'purge_basedirs': [],
'enable_ccache': False,
'vcs_share_base': 'C:/builds/hg-shared',
'objdir': 'obj-firefox',
@ -100,7 +98,6 @@ config = {
'MINIDUMP_SAVE_PATH': '%(base_work_dir)s/minidumps',
},
'enable_pymake': True,
'purge_minsize': 12,
'src_mozconfig': 'browser/config/mozconfigs/win64/nightly',
'tooltool_manifest_src': "browser/config/tooltool-manifests/win64/releng.manifest",
#########################################################################

View File

@ -17,7 +17,6 @@ config = {
],
'debug_build': True,
'stage_platform': 'linux-debug',
'purge_minsize': 15,
'enable_signing': False,
'enable_talos_sendchange': False,
#### 32 bit build specific #####

View File

@ -18,7 +18,6 @@ config = {
'stage_platform': 'linux64-asan',
'publish_nightly_en_US_routes': False,
'build_type': 'asan',
'purge_minsize': 12,
'tooltool_manifest_src': "browser/config/tooltool-manifests/linux64/\
asan.manifest",
'platform_supports_post_upload_to_latest': False,

View File

@ -19,7 +19,6 @@ config = {
'publish_nightly_en_US_routes': False,
'build_type': 'asan-debug',
'debug_build': True,
'purge_minsize': 12,
'tooltool_manifest_src': "browser/config/tooltool-manifests/linux64/\
asan.manifest",
'platform_supports_post_upload_to_latest': False,

View File

@ -7,7 +7,6 @@ config = {
'package-source',
],
'stage_platform': 'source', # Not used, but required by the script
'purge_minsize': 3,
'buildbot_json_path': 'buildprops.json',
'app_ini_path': 'FAKE', # Not used, but required by the script
'objdir': 'obj-firefox',

View File

@ -17,7 +17,6 @@ config = {
'debug_build': True,
'stage_platform': 'linux64-st-an-debug',
'build_type': 'st-an-debug',
'purge_minsize': 12,
'tooltool_manifest_src': "browser/config/tooltool-manifests/linux64/\
clang.manifest",
'platform_supports_post_upload_to_latest': False,

View File

@ -16,8 +16,6 @@ config = {
'app_ini_path': '%(obj_dir)s/dist/bin/application.ini',
# decides whether we want to use moz_sign_cmd in env
'enable_signing': False,
'purge_skip': ['info', 'rel-*:10d', 'tb-rel-*:10d'],
'purge_basedirs': ["/mock/users/cltbld/home/cltbld/build"],
'enable_ccache': True,
'vcs_share_base': '/builds/hg-shared',
'objdir': 'obj-firefox',
@ -57,7 +55,6 @@ config = {
'LD_LIBRARY_PATH': "/tools/gcc-4.3.3/installed/lib64",
##
},
'purge_minsize': 14,
'mock_packages': [
'autoconf213', 'python', 'mozilla-python27', 'zip', 'mozilla-python27-mercurial',
'git', 'ccache', 'perl-Test-Simple', 'perl-Config-General',

View File

@ -16,7 +16,6 @@ config = {
# 'update',
],
'stage_platform': 'linux64-tsan',
'purge_minsize': 12,
'tooltool_manifest_src': "browser/config/tooltool-manifests/linux64/\
tsan.manifest",
'platform_supports_post_upload_to_latest': False,

View File

@ -39,6 +39,5 @@ config = {
##
},
'src_mozconfig': 'browser/config/mozconfigs/macosx64/debug',
'purge_minsize': 10,
#######################
}

View File

@ -35,6 +35,5 @@ config = {
##
},
'src_mozconfig': 'browser/config/mozconfigs/macosx64/opt-static-analysis',
'purge_minsize': 10,
#######################
}

View File

@ -40,6 +40,5 @@ config = {
##
},
'src_mozconfig': 'browser/config/mozconfigs/macosx64/debug',
'purge_minsize': 10,
#######################
}

View File

@ -39,6 +39,5 @@ config = {
##
},
'src_mozconfig': 'b2g/dev/config/mozconfigs/macosx64/mulet',
'purge_minsize': 10,
#######################
}

View File

@ -17,7 +17,6 @@ config = {
'debug_build': True,
'stage_platform': 'macosx64-st-an-debug',
'build_type': 'st-an-debug',
'purge_minsize': 12,
'tooltool_manifest_src': "browser/config/tooltool-manifests/macosx64/\
clang.manifest",
'platform_supports_post_upload_to_latest': False,

View File

@ -34,6 +34,5 @@ config = {
'XPCOM_DEBUG_BREAK': 'stack-and-abort',
},
'src_mozconfig': 'browser/config/mozconfigs/win32/debug',
'purge_minsize': 9,
#######################
}

View File

@ -33,6 +33,5 @@ config = {
'XPCOM_DEBUG_BREAK': 'stack-and-abort',
},
'src_mozconfig': 'b2g/dev/config/mozconfigs/win32/mulet',
'purge_minsize': 9,
#######################
}

View File

@ -33,6 +33,5 @@ config = {
'XPCOM_DEBUG_BREAK': 'stack-and-abort',
},
'src_mozconfig': 'browser/config/mozconfigs/win64/debug',
'purge_minsize': 9,
#######################
}

View File

@ -28,7 +28,6 @@ config = {
"virtualenv": [PYTHON_DIR + "/bin/python", "/tools/misc-python/virtualenv.py"],
},
"purge_minsize": 18,
"force_clobber": True,
'vcs_share_base': HG_SHARE_BASE_DIR,

View File

@ -48,5 +48,4 @@ config = {
}],
# purge options
'is_automation': True,
'purge_minsize': 12,
}

View File

@ -48,5 +48,4 @@ config = {
}],
# purge options
'is_automation': True,
'purge_minsize': 12,
}

View File

@ -11,7 +11,6 @@ config = {
"objdir": OBJDIR,
"is_automation": True,
"buildbot_json_path": "buildprops.json",
"purge_minsize": 10,
"force_clobber": True,
"clobberer_url": "https://api.pub.build.mozilla.org/clobberer/lastclobber",
"locales_file": "%s/mobile/android/locales/all-locales" % MOZILLA_DIR,

View File

@ -11,7 +11,6 @@ config = {
"objdir": OBJDIR,
"is_automation": True,
"buildbot_json_path": "buildprops.json",
"purge_minsize": 10,
"force_clobber": True,
"clobberer_url": "https://api.pub.build.mozilla.org/clobberer/lastclobber",
"locales_file": "%s/mobile/android/locales/all-locales" % MOZILLA_DIR,

View File

@ -30,5 +30,4 @@ config = {
}],
# purge options
'is_automation': True,
'purge_minsize': 12,
}

View File

@ -11,7 +11,6 @@ config = {
"objdir": OBJDIR,
"is_automation": True,
"buildbot_json_path": "buildprops.json",
"purge_minsize": 10,
"force_clobber": True,
"clobberer_url": "https://api.pub.build.mozilla.org/clobberer/lastclobber",
"locales_file": "%s/mobile/android/locales/all-locales" % MOZILLA_DIR,

View File

@ -11,7 +11,6 @@ config = {
"objdir": OBJDIR,
"is_automation": True,
"buildbot_json_path": "buildprops.json",
"purge_minsize": 10,
"force_clobber": True,
"clobberer_url": "https://api.pub.build.mozilla.org/clobberer/lastclobber",
"locales_file": "%s/mobile/android/locales/all-locales" % MOZILLA_DIR,

View File

@ -11,7 +11,6 @@ config = {
"objdir": OBJDIR,
"is_automation": True,
"buildbot_json_path": "buildprops.json",
"purge_minsize": 10,
"force_clobber": True,
"clobberer_url": "https://api.pub.build.mozilla.org/clobberer/lastclobber",
"locales_file": "%s/mobile/android/locales/all-locales" % MOZILLA_DIR,

View File

@ -11,7 +11,6 @@ config = {
"objdir": OBJDIR,
"is_automation": True,
"buildbot_json_path": "buildprops.json",
"purge_minsize": 10,
"force_clobber": True,
"clobberer_url": "https://api.pub.build.mozilla.org/clobberer/lastclobber",
"locales_file": "%s/mobile/android/locales/all-locales" % MOZILLA_DIR,

View File

@ -30,5 +30,4 @@ config = {
}],
# purge options
'is_automation': True,
'purge_minsize': 12,
}

View File

@ -11,7 +11,6 @@ config = {
"objdir": OBJDIR,
"is_automation": True,
"buildbot_json_path": "buildprops.json",
"purge_minsize": 10,
"force_clobber": True,
"clobberer_url": "https://api.pub.build.mozilla.org/clobberer/lastclobber",
"locales_file": "%s/mobile/android/locales/all-locales" % MOZILLA_DIR,

View File

@ -11,7 +11,6 @@ config = {
"objdir": OBJDIR,
"is_automation": True,
"buildbot_json_path": "buildprops.json",
"purge_minsize": 10,
"force_clobber": True,
"clobberer_url": "https://api.pub.build.mozilla.org/clobberer/lastclobber",
"locales_file": "%s/mobile/android/locales/all-locales" % MOZILLA_DIR,

View File

@ -11,7 +11,6 @@ config = {
"objdir": OBJDIR,
"is_automation": True,
"buildbot_json_path": "buildprops.json",
"purge_minsize": 10,
"force_clobber": True,
"clobberer_url": "https://api.pub.build.mozilla.org/clobberer/lastclobber",
"locales_file": "%s/mobile/android/locales/all-locales" % MOZILLA_DIR,

View File

@ -11,7 +11,6 @@ config = {
"objdir": OBJDIR,
"is_automation": True,
"buildbot_json_path": "buildprops.json",
"purge_minsize": 10,
"force_clobber": True,
"clobberer_url": "https://api.pub.build.mozilla.org/clobberer/lastclobber",
"locales_file": "%s/mobile/android/locales/all-locales" % MOZILLA_DIR,

View File

@ -10,7 +10,6 @@ config = {
"objdir": OBJDIR,
"is_automation": True,
"buildbot_json_path": "buildprops.json",
"purge_minsize": 10,
"force_clobber": True,
"clobberer_url": "https://api.pub.build.mozilla.org/clobberer/lastclobber",
"locales_file": "buildbot-configs/mozilla/l10n-changesets_mobile-beta.json",

View File

@ -11,7 +11,6 @@ config = {
"objdir": OBJDIR,
"is_automation": True,
"buildbot_json_path": "buildprops.json",
"purge_minsize": 10,
"force_clobber": True,
"clobberer_url": "https://api.pub.build.mozilla.org/clobberer/lastclobber",
"locales_file": "buildbot-configs/mozilla/l10n-changesets_mobile-beta.json",

View File

@ -11,7 +11,6 @@ config = {
"objdir": OBJDIR,
"is_automation": True,
"buildbot_json_path": "buildprops.json",
"purge_minsize": 10,
"force_clobber": True,
"clobberer_url": "https://api.pub.build.mozilla.org/clobberer/lastclobber",
"locales_file": "buildbot-configs/mozilla/l10n-changesets_mobile-beta.json",

View File

@ -10,7 +10,6 @@ config = {
"objdir": OBJDIR,
"is_automation": True,
"buildbot_json_path": "buildprops.json",
"purge_minsize": 10,
"force_clobber": True,
"clobberer_url": "https://api.pub.build.mozilla.org/clobberer/lastclobber",
"locales_file": "buildbot-configs/mozilla/l10n-changesets_mobile-release.json",

View File

@ -11,7 +11,6 @@ config = {
"objdir": OBJDIR,
"is_automation": True,
"buildbot_json_path": "buildprops.json",
"purge_minsize": 10,
"force_clobber": True,
"clobberer_url": "https://api.pub.build.mozilla.org/clobberer/lastclobber",
"locales_file": "buildbot-configs/mozilla/l10n-changesets_mobile-release.json",

View File

@ -11,7 +11,6 @@ config = {
"objdir": OBJDIR,
"is_automation": True,
"buildbot_json_path": "buildprops.json",
"purge_minsize": 10,
"force_clobber": True,
"clobberer_url": "https://api.pub.build.mozilla.org/clobberer/lastclobber",
"locales_file": "buildbot-configs/mozilla/l10n-changesets_mobile-release.json",

View File

@ -11,7 +11,6 @@ config = {
"objdir": OBJDIR,
"is_automation": True,
"buildbot_json_path": "buildprops.json",
"purge_minsize": 10,
"force_clobber": True,
"clobberer_url": "https://api-pub-build.allizom.org/clobberer/lastclobber",
"locales_file": "buildbot-configs/mozilla/l10n-changesets_mobile-beta.json",

View File

@ -11,7 +11,6 @@ config = {
"objdir": OBJDIR,
"is_automation": True,
"buildbot_json_path": "buildprops.json",
"purge_minsize": 10,
"force_clobber": True,
"clobberer_url": "https://api-pub-build.allizom.org/clobberer/lastclobber",
"locales_file": "buildbot-configs/mozilla/l10n-changesets_mobile-beta.json",

View File

@ -11,7 +11,6 @@ config = {
"objdir": OBJDIR,
"is_automation": True,
"buildbot_json_path": "buildprops.json",
"purge_minsize": 10,
"force_clobber": True,
"clobberer_url": "https://api-pub-build.allizom.org/clobberer/lastclobber",
"locales_file": "buildbot-configs/mozilla/l10n-changesets_mobile-beta.json",

View File

@ -11,7 +11,6 @@ config = {
"objdir": OBJDIR,
"is_automation": True,
"buildbot_json_path": "buildprops.json",
"purge_minsize": 10,
"force_clobber": True,
"clobberer_url": "https://api-pub-build.allizom.org/clobberer/lastclobber",
"locales_file": "buildbot-configs/mozilla/l10n-changesets_mobile-release.json",

View File

@ -11,7 +11,6 @@ config = {
"objdir": OBJDIR,
"is_automation": True,
"buildbot_json_path": "buildprops.json",
"purge_minsize": 10,
"force_clobber": True,
"clobberer_url": "https://api-pub-build.allizom.org/clobberer/lastclobber",
"locales_file": "buildbot-configs/mozilla/l10n-changesets_mobile-release.json",

View File

@ -11,7 +11,6 @@ config = {
"objdir": OBJDIR,
"is_automation": True,
"buildbot_json_path": "buildprops.json",
"purge_minsize": 10,
"force_clobber": True,
"clobberer_url": "https://api-pub-build.allizom.org/clobberer/lastclobber",
"locales_file": "buildbot-configs/mozilla/l10n-changesets_mobile-release.json",

View File

@ -1,303 +0,0 @@
#!/usr/bin/env python
# Written for Mozilla by Chris AtLee <catlee@mozilla.com> 2008
"""Delete old buildbot builds to make room for the current build.
%prog [options] base_dir1 [base_dir2 ...]
base_dir1 is the root of the directory tree you want to delete builds
from.
Sub-directories of base_dir1 will be deleted, in order from oldest to newest,
until the specified amount of space is free.
base_dir1 will always be used for space calculations, but if other base_dir#
are provided, subdirectories within those dirs will also be purged. This will
obviously only increase the available space if the other base_dirs are on the
same mountpoint, but this can be useful for, e.g., cleaning up scratchbox.
example:
python %prog -s 6 /builds/moz2_slave /scratchbox/users/cltbld/home/cltbld/build
"""
import os
import shutil
import sys
from fnmatch import fnmatch
import re
DEFAULT_BASE_DIRS = [".."]
clobber_suffix = '.deleteme'
if sys.platform == 'win32':
# os.statvfs doesn't work on Windows
from win32file import RemoveDirectory, DeleteFile, \
GetFileAttributesW, SetFileAttributesW, GetDiskFreeSpace, \
FILE_ATTRIBUTE_NORMAL, FILE_ATTRIBUTE_DIRECTORY
from win32api import FindFiles
def freespace(p):
secsPerClus, bytesPerSec, nFreeClus, totClus = GetDiskFreeSpace(p)
return secsPerClus * bytesPerSec * nFreeClus
else:
def freespace(p):
"Returns the number of bytes free under directory `p`"
r = os.statvfs(p)
return r.f_frsize * r.f_bavail
def mtime_sort(p1, p2):
"sorting function for sorting a list of paths by mtime"
return cmp(os.path.getmtime(p1), os.path.getmtime(p2))
def rmdirRecursiveWindows(dir):
"""Windows-specific version of rmdirRecursive that handles
path lengths longer than MAX_PATH.
"""
dir = os.path.realpath(dir)
# Make sure directory is writable
SetFileAttributesW('\\\\?\\' + dir, FILE_ATTRIBUTE_NORMAL)
for ffrec in FindFiles('\\\\?\\' + dir + '\*.*'):
file_attr = ffrec[0]
name = ffrec[8]
if name == '.' or name == '..':
continue
full_name = os.path.join(dir, name)
if file_attr & FILE_ATTRIBUTE_DIRECTORY:
rmdirRecursiveWindows(full_name)
else:
SetFileAttributesW('\\\\?\\' + full_name, FILE_ATTRIBUTE_NORMAL)
DeleteFile('\\\\?\\' + full_name)
RemoveDirectory('\\\\?\\' + dir)
def rmdirRecursive(dir):
"""This is a replacement for shutil.rmtree that works better under
windows. Thanks to Bear at the OSAF for the code.
(Borrowed from buildbot.slave.commands)"""
if os.name == 'nt':
rmdirRecursiveWindows(dir)
return
if not os.path.exists(dir):
# This handles broken links
if os.path.islink(dir):
os.remove(dir)
return
if os.path.islink(dir):
os.remove(dir)
return
# Verify the directory is read/write/execute for the current user
os.chmod(dir, 0700)
for name in os.listdir(dir):
full_name = os.path.join(dir, name)
# on Windows, if we don't have write permission we can't remove
# the file/directory either, so turn that on
if os.name == 'nt':
if not os.access(full_name, os.W_OK):
# I think this is now redundant, but I don't have an NT
# machine to test on, so I'm going to leave it in place
# -warner
os.chmod(full_name, 0600)
if os.path.isdir(full_name):
rmdirRecursive(full_name)
else:
# Don't try to chmod links
if not os.path.islink(full_name):
os.chmod(full_name, 0700)
os.remove(full_name)
os.rmdir(dir)
def str2seconds(s):
""" Accepts time intervals resembling:
30d (30 days)
10h (10 hours)
Returns the specified interval as a positive integer in seconds.
"""
m = re.match(r'^(\d+)([dh])$', s)
if (m):
mul = {'d': 24*60*60, 'h': 60*60}
n = int(m.group(1))
unit = m.group(2)
return n * mul[unit]
else:
raise ValueError("Unhandled time format '%s'" % s)
def purge(base_dirs, gigs, ignore, max_age, dry_run=False):
"""Delete directories under `base_dirs` until `gigs` GB are free.
Delete any directories older than max_age.
Will not delete directories listed in the ignore list except
those tagged with an expiry threshold. Example:
rel-*:40d
Will not delete rel-* directories until they are over 40 days old.
"""
gigs *= 1024 * 1024 * 1024
# convert 'ignore' to a dict resembling { directory: cutoff_time }
# where a cutoff time of -1 means 'never expire'.
ignore = dict(map(lambda x: x.split(':')[0:2] if len(x.split(':')) > 1 else [x, -1], ignore))
ignore = dict(map(lambda key: [key, time.time() - str2seconds(ignore[key])] if ignore[key] != -1 else [key, ignore[key]], ignore))
dirs = []
for base_dir in base_dirs:
if os.path.exists(base_dir):
for d in os.listdir(base_dir):
p = os.path.join(base_dir, d)
if not os.path.isdir(p):
continue
mtime = os.path.getmtime(p)
skip = False
for pattern, cutoff_time in ignore.iteritems():
if (fnmatch(d, pattern)):
if cutoff_time == -1 or mtime > cutoff_time:
skip = True
break
else:
print("Ignored directory '%s' exceeds cutoff time" % d)
if skip:
continue
dirs.append((mtime, p))
dirs.sort()
while dirs:
mtime, d = dirs.pop(0)
# If we're newer than max_age, and don't need any more free space,
# we're all done here
if (not max_age) or (mtime > max_age):
if freespace(base_dirs[0]) >= gigs:
break
print "Deleting", d
if not dry_run:
try:
clobber_path = d + clobber_suffix
if os.path.exists(clobber_path):
rmdirRecursive(clobber_path)
# Prevent repeated moving.
if d.endswith(clobber_suffix):
rmdirRecursive(d)
else:
shutil.move(d, clobber_path)
rmdirRecursive(clobber_path)
except:
print >>sys.stderr, "Couldn't purge %s properly. Skipping." % d
def purge_hg_shares(share_dir, gigs, max_age, dry_run=False):
"""Deletes old hg directories under share_dir"""
# Find hg directories
hg_dirs = []
for root, dirs, files in os.walk(share_dir):
for d in dirs[:]:
path = os.path.join(root, d, '.hg')
if os.path.exists(path) or os.path.exists(path + clobber_suffix):
hg_dirs.append(os.path.join(root, d))
# Remove d from the list so we don't go traversing down into it
dirs.remove(d)
# Now we have a list of hg directories, call purge on them
purge(hg_dirs, gigs, [], max_age, dry_run)
# Clean up empty directories
for d in hg_dirs:
if not os.path.exists(os.path.join(d, '.hg')):
print "Cleaning up", d
if not dry_run:
rmdirRecursive(d)
if __name__ == '__main__':
import time
from optparse import OptionParser
from ConfigParser import ConfigParser, NoOptionError
max_age = 14
config = ConfigParser()
config.read(os.path.expanduser('~/.purge_builds.cfg'))
try:
max_age = config.getint('DEFAULT', 'max_age')
except (NoOptionError, ValueError):
pass
cwd = os.path.basename(os.getcwd())
parser = OptionParser(usage=__doc__)
parser.set_defaults(size=5, share_size=1, skip=[cwd], dry_run=False, max_age=max_age)
parser.add_option('-s', '--size',
help='free space required (in GB, default 5)', dest='size',
type='float')
parser.add_option('--share-size',
help='free space required for vcs shares (in GB, default 1)', dest='share_size',
type='float')
parser.add_option('-n', '--not', help='do not delete this directory. Append :30d to skip for up to 30 days, or :30h to skip for up to 30 hours',
action='append', dest='skip')
parser.add_option('', '--dry-run', action='store_true',
dest='dry_run',
help='''do not delete anything, just print out what would be
deleted. note that since no directories are deleted, if the amount of free
disk space in base_dir(s) is less than the required size, then ALL directories
will be listed in the order in which they would be deleted.''')
parser.add_option('', '--max-age', dest='max_age', type='int',
help='''maximum age (in days) for directories. If any directory
has an mtime older than this, it will be deleted, regardless of how
much free space is required. Set to 0 to disable.''')
options, base_dirs = parser.parse_args()
if len(base_dirs) < 1:
for d in DEFAULT_BASE_DIRS:
if os.path.exists(d):
base_dirs.append(d)
if len(base_dirs) < 1:
parser.error("Must specify one or more base_dirs")
sys.exit(1)
# Figure out the mtime before which we'll start deleting old directories
if options.max_age:
cutoff_time = time.time() - 24 * 3600 * options.max_age
else:
cutoff_time = None
purge(base_dirs, options.size, options.skip, cutoff_time, options.dry_run)
# Try to cleanup shared hg repos. We run here even if we've freed enough
# space so we can be sure and delete repositories older than max_age
if 'HG_SHARE_BASE_DIR' in os.environ:
purge_hg_shares(os.environ['HG_SHARE_BASE_DIR'],
options.share_size, cutoff_time, options.dry_run)
after = freespace(base_dirs[0]) / (1024 * 1024 * 1024.0)
# Try to cleanup the current dir if we still need space and it will
# actually help.
if after < options.size:
# We skip the tools dir here because we've usually just cloned it.
purge(['.'], options.size, ['tools'], cutoff_time, options.dry_run)
after = freespace(base_dirs[0]) / (1024 * 1024 * 1024.0)
if after < options.size:
print "Error: unable to free %1.2f GB of space. " % options.size + \
"Free space only %1.2f GB" % after
sys.exit(1)
else:
print "%1.2f GB of space available" % after
sys.exit(0)

View File

@ -23,57 +23,12 @@ from mozharness.base.log import ERROR
# Depends on ScriptMixin for self.run_command,
# and BuildbotMixin for self.buildbot_config and self.query_is_nightly()
class PurgeMixin(object):
purge_tool = os.path.join(external_tools_path, 'purge_builds.py')
clobber_tool = os.path.join(external_tools_path, 'clobberer.py')
default_skips = ['info', 'rel-*', 'tb-rel-*']
default_maxage = 14
default_periodic_clobber = 7 * 24
def purge_builds(self, basedirs=None, min_size=None, skip=None, max_age=None):
# Try clobbering first
c = self.config
dirs = self.query_abs_dirs()
if 'clobberer_url' in c and c.get('use_clobberer', True):
self.clobberer()
min_size = min_size or c['purge_minsize']
max_age = max_age or c.get('purge_maxage') or self.default_maxage
skip = skip or c.get('purge_skip') or self.default_skips
if not basedirs:
# some platforms using this method (like linux) supply more than
# one basedir
basedirs = []
basedirs.append(os.path.dirname(dirs['base_work_dir']))
if self.config.get('purge_basedirs'):
basedirs.extend(self.config.get('purge_basedirs'))
cmd = []
if self._is_windows():
# The virtualenv isn't setup yet, so just use python directly.
cmd.append(self.query_exe('python'))
# Add --dry-run if you don't want to do this for realz
cmd.extend([self.purge_tool, '-s', str(min_size)])
if max_age:
cmd.extend(['--max-age', str(max_age)])
for s in skip:
cmd.extend(['--not', s])
cmd.extend(basedirs)
# purge_builds.py can also clean up old shared hg repos if we set
# HG_SHARE_BASE_DIR accordingly
env = {'PATH': os.environ.get('PATH')}
share_base = c.get('vcs_share_base', os.environ.get("HG_SHARE_BASE_DIR", None))
if share_base:
env['HG_SHARE_BASE_DIR'] = share_base
retval = self.run_command(cmd, env=env)
if retval != 0:
self.fatal("failed to purge builds", exit_code=2)
def clobberer(self):
c = self.config
dirs = self.query_abs_dirs()
@ -142,7 +97,5 @@ class PurgeMixin(object):
always_clobber_dirs = []
for path in always_clobber_dirs:
self.rmtree(path)
# run purge_builds / check clobberer
self.purge_builds()
else:
super(PurgeMixin, self).clobber()

View File

@ -154,9 +154,6 @@ class SpidermonkeyBuild(MockMixin,
('base_mirror_urls', 'hgtool_base_mirror_urls', None),
('hgurl', 'hgurl', None),
('clobberer_url', 'clobberer_url', 'https://api.pub.build.mozilla.org/clobberer/lastclobber'),
('purge_minsize', 'purge_minsize', 15),
('purge_maxage', 'purge_maxage', None),
('purge_skip', 'purge_skip', None),
('force_clobber', 'force_clobber', None),
('branch', 'blob_upload_branch', None),
]