Commit f60a51e1 authored by André Anjos's avatar André Anjos

Merge branch 'base-build' into 'master'

Base build

See merge request !14
parents 40fbdd3e e84d7970
Pipeline #26894 passed with stages
in 6 minutes and 28 seconds
# This YAML file contains descriptions for the CI of most of our Bob/BEAT/BATL
# packages - do **not** modify it unless you know what you're doing (and up
# to!)
# Definition of global variables (all stages)
# Definition of our build pipeline order
- build
# Build targets
.build_template: &build_job
stage: build
- curl --silent "${BOOTSTRAP}" --output ""
- python3 -vv channel base
- source ${CONDA_ROOT}/etc/profile.d/
- conda activate base
- bdt ci base-build -vv order.txt
- '[ "${CI_COMMIT_REF_NAME}" = "master" ] && bdt ci base-deploy -vv'
- bdt ci clean -vv
cache: &build_caches
- ${CONDA_ROOT}/pkgs/*.tar.bz2
- ${CONDA_ROOT}/pkgs/urls.txt
<<: *build_job
- docker
image: continuumio/conda-concourse-ci
<<: *build_caches
key: "linux-cache"
<<: *build_job
- macosx
<<: *build_caches
key: "macosx-cache"
......@@ -303,6 +303,57 @@ def pypi(package, dry_run):
1. Builds a list of packages (base dependencies) defined in a text file
$ bdt ci base-build -vv order.txt
@click.argument('order', required=True, type=click.Path(file_okay=True,
dir_okay=False, exists=True), nargs=1)
@click.option('-d', '--dry-run/--no-dry-run', default=False,
help='Only goes through the actions, but does not execute them ' \
'(combine with the verbosity flags - e.g. ``-vvv``) to enable ' \
'printing to help you understand what will be done')
def base_build(order, dry_run):
"""Builds base (dependence) packages
This command builds dependence packages (packages that are not Bob/BEAT
packages) in the CI infrastructure. It is **not** meant to be used outside
this context.
from ..constants import CONDA_BUILD_CONFIG
from import base_build as _build
condarc = os.path.join(os.environ['CONDA_ROOT'], 'condarc')'Loading (this build\'s) CONDARC file from %s...', condarc)
with open(condarc, 'rb') as f:
condarc_options = yaml.load(f)
# dump packages at conda_root
condarc_options['croot'] = os.path.join(os.environ['CONDA_ROOT'],
# loads dirnames from order file (accepts # comments and empty lines)
recipes = []
with open(order, 'rt') as f:
for line in f:
line = line.partition('#')[0].strip()
if line: recipes.append(line)
for recipe in recipes:
if not os.path.exists(os.path.join(recipe, 'meta.yaml')):
# ignore - not a conda package
base_build(SERVER, True, recipe, CONDA_BUILD_CONFIG,
os.environ['PYTHON_VERSION'], args.python_version, condarc_options)
1. Builds the current package
$ bdt ci build -vv
......@@ -58,18 +58,25 @@ test:
- bdt -?
- bdt --help
- bdt lasttag --help
#- bdt lasttag -vv bob/bob.devtools
- bdt changelog --help
#- bdt changelog -vv bob/bob.devtools
- bdt release --help
#- bdt release -vvd
- bdt visibility --help
#- bdt visibility -vv bob/bob.devtools
- bdt dumpsphinx --help
- bdt dumpsphinx > /dev/null
- bdt create --help
- bdt build --help
- bdt getpath --help
#- bdt getpath -vv bob/bob.devtools .gitignore
- bdt caupdate --help
- bdt new --help
- bdt new -t "New package" -o bob.foobar bob/bob.foobar "John Doe" ""
- bdt new -t "New package" -o beat.foobar beat/beat.foobar "John Doe" ""
- bdt ci --help
- bdt ci base-build --help
- bdt ci build --help
- bdt ci base-deploy --help
- bdt ci deploy --help
......@@ -59,6 +59,7 @@ setup(
'': [
'base-build =',
'build =',
'clean =',
'base-deploy =',
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment