Skip to content

Commit

Permalink
suqashall
Browse files Browse the repository at this point in the history
  • Loading branch information
johnhaddon committed Feb 22, 2024
1 parent 1e5e0ea commit 95e1b1a
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 8 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/dockerImagePublish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
- uses: actions/checkout@v2

- name: Build the container image
run: buildah build --file Dockerfile --tag image --layers=false --squash
run: buildah build --file Dockerfile --tag image --squash-all

- name: Log into registry
#run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login docker.pkg.github.com -u ${{ github.actor }} --password-stdin
Expand Down
28 changes: 21 additions & 7 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,7 @@
# the glibc requirements of VFXPlatform 2023 (2.28 or lower), with many of our
# build dependencies already pre-installed.

FROM aswf/ci-base:2023.2

# Identify the build environment. This can be used by build processes for
# environment specific behaviour such as naming artifacts built from this
# container.
ENV GAFFER_BUILD_ENVIRONMENT="gcc11"
FROM aswf/ci-base:2023.2 as build

# As we don't want to inadvertently grab newer versions of our yum-installed
# packages, we use yum-versionlock to keep them pinned. We track the list of
Expand Down Expand Up @@ -85,6 +80,14 @@ RUN yum install -y 'dnf-command(versionlock)' && \
# correct version will already be installed and we just ignore this...
./versionlock.sh lock-new /tmp/packages

# The trimming we did above won't actually make our image any smaller, because
# it is composed from layers, and the base layer still contains the original
# files. Flatten the result into a new single-layer image so we actually end up
# with something smaller.

FROM scratch
COPY --from=build / /

# Set WORKDIR back to / to match the behaviour of our CentOS 7 Dockerfile.
# This makes it easier to deal with copying build artifacts as they will be
# in the same location in both containers.
Expand All @@ -98,4 +101,15 @@ ENV PYTHONPATH=
ENV _INKSCAPE_GC="disable"

# Make the Optix SDK available for Cycles builds.
ENV OPTIX_ROOT_DIR=/usr/local/NVIDIA-OptiX-SDK-7.3.0
ENV OPTIX_ROOT_DIR=/usr/local/NVIDIA-OptiX-SDK-7.3.0

# Identify the build environment. This can be used by build processes for
# environment specific behaviour such as naming artifacts built from this
# container.
ENV GAFFER_BUILD_ENVIRONMENT="gcc11"

# Restore the entry point from the base image, since that was lost when
# we flattened the image.
ENTRYPOINT /opt/nvidia/nvidia_entrypoint.sh

RUN export MYVAR=HELLOO

0 comments on commit 95e1b1a

Please sign in to comment.