Commit 13aa0a77 authored by James T. Lee's avatar James T. Lee
Browse files

Initial build

parents
Pipeline #566 passed with stage
in 21 minutes and 34 seconds
---
.template: &template
image: '${CI_REGISTRY}/nest/tools/buildah:${CI_HOST_CPU}'
stage: 'build'
tags: ['nest']
script:
- 'mkdir debug'
- 'buildah login -u "$CI_REGISTRY_USER" -p "$CI_REGISTRY_PASSWORD" "$CI_REGISTRY"'
- 'buildah bud --security-opt seccomp=unconfined
--build-arg STAGE1_TAG="${CPU}-${ROLE}"
--build-arg FACTER_emerge_default_opts="$CI_HOST_EMERGE_DEFAULT_OPTS"
--build-arg FACTER_makeopts="$CI_HOST_MAKEOPTS"
--build-arg PROFILE="$PROFILE"
-v "/usr/bin/qemu-${QEMU_ARCH}:/usr/bin/qemu-${QEMU_ARCH}:ro"
-v "${PUPPET_CERTIFICATE}:/etc/puppetlabs/puppet/ssl/certs/ci.pem"
-v "${PUPPET_PRIVATE_KEY}:/etc/puppetlabs/puppet/ssl/private_keys/ci.pem"
-v "${PWD}/debug:/usr/lib/debug"
-v /nest:/nest
-t "${CI_REGISTRY_IMAGE}:${PLATFORM}-${ROLE}" .'
- 'buildah bud --build-arg STAGE1_TAG="${CPU}-${ROLE}" -t "${CI_REGISTRY_IMAGE}/debug:${PLATFORM}-${ROLE}" -f Containerfile.debug .'
- 'buildah push "${CI_REGISTRY_IMAGE}:${PLATFORM}-${ROLE}"'
- 'buildah push "${CI_REGISTRY_IMAGE}/debug:${PLATFORM}-${ROLE}"'
'Build haswell-server':
<<: *template
variables:
CPU: 'haswell'
PLATFORM: 'haswell'
ROLE: 'server'
PROFILE: 'haswell/server'
QEMU_ARCH: 'x86_64'
ARG STAGE1_TAG
FROM nest/stage1:${STAGE1_TAG}
ARG FACTER_build=stage2
ARG FACTER_emerge_default_opts
ARG FACTER_makeopts
ARG PROFILE
RUN eix-sync -q
# Switch to desired profile and make the base system consistent with it
RUN eselect profile set "nest:${PROFILE}"
RUN emerge --info
RUN emerge -v --update --deep --newuse --with-bdeps=y @world
# Configure the stage
RUN puppet agent --environment stage2 --test --runtimeout 0; [ $? -eq 2 ]
RUN rm -rf /var/db/repos
ARG STAGE1_TAG
FROM nest/stage1/debug:${STAGE1_TAG}
COPY debug/ /
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