Skip to content

Commit

Permalink
enable cache on zombie-builder step
Browse files Browse the repository at this point in the history
  • Loading branch information
qdrvm-ci committed Jun 17, 2024
1 parent 17d70ee commit fdde097
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 1 deletion.
16 changes: 15 additions & 1 deletion .github/workflows/zombie-builder.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,22 @@ on:
# - cron: '0 2 * * 0' # Update zombie builder image each Sunday night
workflow_dispatch:

env:
env:
POLKADOT_BINARY_REPO: ${secrets.GCP_REGISTRY_PATH}/polkadot-sdk-bin
BUILD_DIR: build
KAGOME_IN_DOCKER: 1
CTEST_OUTPUT_ON_FAILURE: 1
GITHUB_HUNTER_USERNAME: ${{ secrets.HUNTER_USERNAME }}
GITHUB_HUNTER_TOKEN: ${{ secrets.HUNTER_TOKEN }}
# Change all container: values to this variable once this feature is available
# https://github.jparrowsec.cnmunity/t/how-to-set-and-access-a-workflow-variable/17335/6
CACHE_VERSION: v07
CACHE_PATHS: |
~/Library/Caches/pip
~/.cargo
~/.ccache
~/.hunter
~/.rustup
jobs:
# get_polkadot_binary_image:
Expand Down
6 changes: 6 additions & 0 deletions .github/workflows/zombie-tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,12 @@ on:
workflow_dispatch:

env:
BUILD_DIR: build
KAGOME_IN_DOCKER: 1
CTEST_OUTPUT_ON_FAILURE: 1
GITHUB_HUNTER_USERNAME: ${{ secrets.HUNTER_USERNAME }}
GITHUB_HUNTER_TOKEN: ${{ secrets.HUNTER_TOKEN }}

CACHE_VERSION: v07
CACHE_PATHS: |
~/Library/Caches/pip
Expand Down
7 changes: 7 additions & 0 deletions zombienet/docker/zombie_builder.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,13 @@ LABEL org.opencontainers.image.description="Zombienet image"
ARG ZOMBIENET_RELEASE
ENV ZOMBIENET_RELEASE=$ZOMBIENET_RELEASE

RUN useradd --home-dir /home/nonroot \
--create-home \
--shell /bin/bash \
--gid nonroot \
--groups nonroot \
--uid 10000 nonroot

WORKDIR /home/nonroot/

RUN install_packages \
Expand Down

0 comments on commit fdde097

Please sign in to comment.