Skip to content

Commit 9893680

Browse files
committed
the RPM packages would be installed, but lacking cuttlefish-base.
1 parent c13e2d1 commit 9893680

File tree

17 files changed

+200
-216
lines changed

17 files changed

+200
-216
lines changed

.github/workflows/reusable-docker.yml

Lines changed: 32 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
name: Reusable Docker Container Run
2+
description: It mounts RUNNER.TEMP, because the mount is supposed to be outside the Docker context.
23

34
on:
45
workflow_call:
@@ -73,6 +74,18 @@ jobs:
7374
ENV_VARS: '--env REPO_USER="${{ INPUTS.USERNAME }}" --env REPO_NAME="${{ INPUTS.REPOSITORY }}" --env REPO_BRANCH="${{ INPUTS.BRANCH }}" --env RUNNER_UID="${{ INPUTS.RUNNER_UID }}" --env RUNNER_GID="${{ INPUTS.RUNNER_GID }}"'
7475
steps:
7576

77+
- shell: bash
78+
id: setup
79+
run: |
80+
PLATFORM='${{ INPUTS.PLATFORM }}'
81+
ARTIFACT_NAME=${GITHUB_REPOSITORY#$GITHUB_REPOSITORY_OWNER/}-rhel9-${PLATFORM#linux/}-unsigned
82+
echo "ARTIFACT_NAME=${ARTIFACT_NAME}" >> $GITHUB_OUTPUT
83+
echo "ARTIFACT_PATH=${{ RUNNER.TEMP }}/.rpms" >> $GITHUB_OUTPUT
84+
echo "CACHE_PATH=${{ RUNNER.TEMP }}/.cache" >> $GITHUB_OUTPUT
85+
echo "::group::Setup Info"
86+
echo "::notice file=reusable-docker.yml,line={85},title=Artifact Name: ${ARTIFACT_NAME}"
87+
echo "::endgroup::"
88+
7689
# https://github.com/docker/login-action
7790
- name: Log in to the Container registry
7891
uses: 'docker/login-action@v3'
@@ -84,25 +97,25 @@ jobs:
8497

8598
# Need to check out once again, in order to utilize `hashFiles()`.
8699
- uses: 'actions/checkout@v4'
87-
- name: Restore bazel cache
100+
- name: Restore Bazel cache
88101
id: bazel-cache-restore
89102
uses: 'actions/cache/restore@v4'
90103
with:
91104
key: bazel-cache-${{ RUNNER.ARCH }}-${{ hashFiles('./base/cvd/**.bazel') }}
92105
restore-keys: bazel-cache-${{ RUNNER.ARCH }}-
93-
path: ${{ RUNNER.TEMP }}/.cache
106+
path: ${{ STEPS.SETUP.OUTPUTS.CACHE_PATH }}
94107

95108
# https://docs.docker.com/reference/cli/docker/container/run/
96109
# https://docs.docker.com/reference/cli/docker/container/cp/
97110
# --entrypoint ${{ INPUTS.ENTRY-POINT }} cannot be changed with GitHub docker.
98-
- name: Run ${{ INPUTS.REGISTRY }}/${{ INPUTS.USERNAME }}/${{ INPUTS.IMAGE }} with ${{ INPUTS.USERNAME }} / ${{ INPUTS.REPOSITORY }} / ${{ INPUTS.BRANCH }}
111+
- name: 'Run image ${{ INPUTS.REGISTRY }}/${{ INPUTS.USERNAME }}/${{ INPUTS.IMAGE }} with source branch: https://github.com/${{ INPUTS.USERNAME }}/${{ INPUTS.REPOSITORY }}.git#${{ INPUTS.BRANCH }}'
99112
id: build-rpm-packages
100113
shell: bash
101114
env:
102-
VOLUMES: '--volume ${{ RUNNER.TEMP }}/.cache:/home/runner/.cache --volume ${{ RUNNER.TEMP }}/.rpms:/home/runner/.rpms'
115+
VOLUMES: '--volume ${{ STEPS.SETUP.OUTPUTS.CACHE_PATH }}:/home/runner/.cache --volume ${{ STEPS.SETUP.OUTPUTS.ARTIFACT_PATH }}:/home/runner/.rpms'
103116
run: |
104-
mkdir -p ${{ RUNNER.TEMP }}/.rpms
105-
mkdir -p ${{ RUNNER.TEMP }}/.cache
117+
mkdir -p ${{ STEPS.SETUP.OUTPUTS.CACHE_PATH }}
118+
mkdir -p ${{ STEPS.SETUP.OUTPUTS.ARTIFACT_PATH }}
106119
docker run $DOCKER_OPTIONS $VOLUMES $ENV_VARS $DOCKER_IMAGE
107120
108121
# https://github.com/actions/upload-artifact
@@ -111,24 +124,27 @@ jobs:
111124
if: ${{ success() }}
112125
id: retain-rpm-packages
113126
with:
114-
name: ${{ INPUTS.REPOSITORY }}-rhel9-${{ RUNNER.ARCH }}-unsigned
115-
path: "${{ RUNNER.TEMP }}/.rpms"
127+
name: ${{ STEPS.SETUP.OUTPUTS.ARTIFACT_NAME }}
128+
path: ${{ STEPS.SETUP.OUTPUTS.ARTIFACT_PATH }}
116129
include-hidden-files: 'true'
117130
retention-days: 14
118131

119-
- name: List directory ${{ RUNNER.TEMP }}/.rpms
132+
- name: List directory ${{ STEPS.SETUP.OUTPUTS.ARTIFACT_PATH }}
120133
id: list-rpm-packages
121134
shell: bash
122135
run: |
123-
[ "$(ls -1 ${{ RUNNER.TEMP }}/.rpms/*.rpm 2>/dev/null | wc -l)" -lt 4 ] && echo "::warning file=reusable-docker.yml,title=RPM Build::Less than 4 ${{ INPUTS.REPOSITORY }} RPM packages were built."
124-
printf "Ubuntu mount-point: %s" "${{ RUNNER.TEMP }}/.rpms"
125-
ls -la ${{ RUNNER.TEMP }}/.rpms
126-
ls -lan ${{ RUNNER.TEMP }}/.rpms
136+
if [ "$(ls -1 ${{ STEPS.SETUP.OUTPUTS.ARTIFACT_PATH }}/*.rpm 2>/dev/null | wc -l)" -lt 4 ]; then
137+
echo "::warning file=reusable-docker.yml,line=134,title=RPM Build::Less than the expected 4 RPM packages were built."
138+
for package in ${{ STEPS.SETUP.OUTPUTS.ARTIFACT_PATH }}/*.rpm; do echo "::notice file=reusable-docker.yml,line=136,title=${package}"; done
139+
fi
140+
echo "Ubuntu mount-point: ${{ STEPS.SETUP.OUTPUTS.ARTIFACT_PATH }}"
141+
ls -la ${{ STEPS.SETUP.OUTPUTS.ARTIFACT_PATH }}
142+
ls -lan ${{ STEPS.SETUP.OUTPUTS.ARTIFACT_PATH }}
127143
128144
# https://github.com/actions/cache
129-
- name: Save bazel cache
145+
- name: Save Bazel cache
130146
id: bazel-cache-save
131147
uses: 'actions/cache/save@v4'
132148
with:
133-
key: ${{ steps.bazel-cache-restore.outputs.cache-primary-key }}
134-
path: ${{ RUNNER.TEMP }}/.cache
149+
path: ${{ STEPS.SETUP.OUTPUTS.CACHE_PATH }}
150+
key: ${{ STEPS.BAZEL-CACHE-RESTORE.OUTPUTS.CACHE-PRIMARY-KEY }}

.github/workflows/rhel-integration.yml

Lines changed: 28 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
name: RHEL Integration
2+
description: It mounts GITHUB.WORKSPACE, because the packages must be within the Docker context.
23

34
on:
45
workflow_call:
@@ -49,21 +50,6 @@ jobs:
4950
DOCKER_IMAGE: ${{ INPUTS.REGISTRY }}/${{ INPUTS.USERNAME }}/${{ INPUTS.IMAGE }}
5051
steps:
5152

52-
# https://github.com/actions/download-artifact
53-
- uses: 'actions/download-artifact@v4'
54-
id: restore-rpm-packages
55-
with:
56-
name: ${{ INPUTS.REPOSITORY }}-rhel9-${{ RUNNER.ARCH }}-unsigned
57-
path: '${{ RUNNER.TEMP }}/.rpms'
58-
59-
- name: List directory ${{ RUNNER.TEMP }}/.rpms
60-
id: list-rpm-packages
61-
shell: bash
62-
run: |
63-
printf "Ubuntu mount-point: %s" "${{ RUNNER.TEMP }}/.rpms"
64-
ls -la ${{ RUNNER.TEMP }}/.rpms
65-
ls -lan ${{ RUNNER.TEMP }}/.rpms
66-
6753
- uses: 'docker/login-action@v3'
6854
id: container-registry
6955
with:
@@ -87,11 +73,32 @@ jobs:
8773
if: ${{ INPUTS.PLATFORM != 'linux/amd64' }}
8874
with: { platforms: arm64 }
8975

90-
- shell: bash
76+
- name: Run shell script, which determines the artifact name
77+
shell: bash
9178
id: setup
9279
run: |
93-
echo "RUNNER_GID=$(id -g)" >> $GITHUB_OUTPUT
94-
echo "RUNNER_UID=$(id -u)" >> $GITHUB_OUTPUT
80+
PLATFORM='${{ INPUTS.PLATFORM }}'
81+
ARTIFACT_NAME=${GITHUB_REPOSITORY#$GITHUB_REPOSITORY_OWNER/}-rhel9-${PLATFORM#linux/}-unsigned
82+
echo "ARTIFACT_PATH=${{ GITHUB.WORKSPACE }}/.rpms" >> $GITHUB_OUTPUT
83+
echo "ARTIFACT_NAME=${ARTIFACT_NAME}" >> $GITHUB_OUTPUT
84+
echo "::group::Setup Info"
85+
echo "::notice file=rhel-integration.yml,line={85},title=Artifact Name: ${ARTIFACT_NAME}"
86+
echo "::endgroup::"
87+
88+
# https://github.com/actions/download-artifact
89+
- uses: 'actions/download-artifact@v4'
90+
id: restore-rpm-packages
91+
with:
92+
name: ${{ STEPS.SETUP.OUTPUTS.ARTIFACT_NAME }}
93+
path: ${{ STEPS.SETUP.OUTPUTS.ARTIFACT_PATH }}
94+
95+
- name: List directory ${{ STEPS.SETUP.OUTPUTS.ARTIFACT_PATH }}
96+
id: list-rpm-packages
97+
shell: bash
98+
run: |
99+
echo "Runner directory: ${{ STEPS.SETUP.OUTPUTS.ARTIFACT_PATH }}"
100+
ls -la ${{ STEPS.SETUP.OUTPUTS.ARTIFACT_PATH }}
101+
ls -lan ${{ STEPS.SETUP.OUTPUTS.ARTIFACT_PATH }}
95102
96103
- uses: 'docker/build-push-action@v6'
97104
id: build
@@ -104,9 +111,10 @@ jobs:
104111
labels: ${{ STEPS.METADATA.OUTPUTS.LABELS }}
105112
tags: ${{ STEPS.METADATA.OUTPUTS.TAGS }}
106113
build-args: |
107-
RUNNER_GID=${{ STEPS.SETUP.OUTPUTS.RUNNER_GID }}
108-
RUNNER_UID=${{ STEPS.SETUP.OUTPUTS.RUNNER_UID }}
109114
LINUX_IMAGE=${{ VARS.RHEL_LINUX_IMAGE }}
115+
GITHUB_USER=${{ GITHUB.REPOSITORY_OWNER }}
116+
GITHUB_REPO=${{ STEPS.SETUP.OUTPUTS.REPOSITORY_NAME }}
117+
GITHUB_BRANCH=${{ GITHUB.HEAD_REF || GITHUB.REF_NAME }}
110118
111119
# Note: The digest comes from `buildx`, not the metadata.
112120
# https://github.com/actions/attest-build-provenance

.github/workflows/rhel-orchestration.yml

Lines changed: 35 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
name: RHEL Orchestration
2+
description: It mounts GITHUB.WORKSPACE, because the packages must be within the Docker context.
23

34
on:
45
workflow_call:
@@ -50,21 +51,6 @@ jobs:
5051
ARTIFACT_NAME: ${{ NEEDS.SETUP.OUTPUTS.ARTIFACT_NAME }}
5152
steps:
5253

53-
# https://github.com/actions/download-artifact
54-
- uses: 'actions/download-artifact@v4'
55-
id: restore-rpm-packages
56-
with:
57-
name: ${{ INPUTS.REPOSITORY }}-rhel9-${{ RUNNER.ARCH }}-unsigned
58-
path: '${{ RUNNER.TEMP }}/.rpms'
59-
60-
- name: List directory ${{ RUNNER.TEMP }}/.rpms
61-
id: list-rpm-packages
62-
shell: bash
63-
run: |
64-
printf "Ubuntu mount-point: %s" "${{ RUNNER.TEMP }}/.rpms"
65-
ls -la ${{ RUNNER.TEMP }}/.rpms
66-
ls -lan ${{ RUNNER.TEMP }}/.rpms
67-
6854
- uses: 'docker/login-action@v3'
6955
id: container-registry
7056
with:
@@ -81,15 +67,40 @@ jobs:
8167
type=sha
8268
latest
8369
84-
- shell: bash
85-
id: setup
86-
run: |
87-
echo "RUNNER_GID=$(id -g)" >> $GITHUB_OUTPUT
88-
echo "RUNNER_UID=$(id -u)" >> $GITHUB_OUTPUT
89-
9070
# https://github.com/marketplace/actions/build-and-push-docker-images
9171
- uses: 'actions/checkout@v4'
9272
- uses: 'docker/setup-buildx-action@v3'
73+
- uses: 'docker/setup-qemu-action@v3'
74+
if: ${{ INPUTS.PLATFORM != 'linux/amd64' }}
75+
with: { platforms: arm64 }
76+
77+
- name: Run shell script, which determines the artifact name
78+
shell: bash
79+
id: setup
80+
run: |
81+
PLATFORM='${{ INPUTS.PLATFORM }}'
82+
ARTIFACT_NAME=${GITHUB_REPOSITORY#$GITHUB_REPOSITORY_OWNER/}-rhel9-${PLATFORM#linux/}-unsigned
83+
echo "ARTIFACT_PATH=${{ GITHUB.WORKSPACE }}/.rpms" >> $GITHUB_OUTPUT
84+
echo "ARTIFACT_NAME=${ARTIFACT_NAME}" >> $GITHUB_OUTPUT
85+
echo "::group::Setup Info"
86+
echo "::notice file=rhel-orchestration.yml,line={86},title=Artifact Name: ${ARTIFACT_NAME}"
87+
echo "::endgroup::"
88+
89+
# https://github.com/actions/download-artifact
90+
- uses: 'actions/download-artifact@v4'
91+
id: restore-rpm-packages
92+
with:
93+
name: ${{ STEPS.SETUP.OUTPUTS.ARTIFACT_NAME }}
94+
path: ${{ STEPS.SETUP.OUTPUTS.ARTIFACT_PATH }}
95+
96+
- name: List directory ${{ STEPS.SETUP.OUTPUTS.ARTIFACT_PATH }}
97+
id: list-rpm-packages
98+
shell: bash
99+
run: |
100+
echo "Runner directory: ${{ STEPS.SETUP.OUTPUTS.ARTIFACT_PATH }}"
101+
ls -la ${{ STEPS.SETUP.OUTPUTS.ARTIFACT_PATH }}
102+
ls -lan ${{ STEPS.SETUP.OUTPUTS.ARTIFACT_PATH }}
103+
93104
- uses: 'docker/build-push-action@v6'
94105
id: build
95106
with:
@@ -104,6 +115,9 @@ jobs:
104115
RUNNER_GID=${{ STEPS.SETUP.OUTPUTS.RUNNER_GID }}
105116
RUNNER_UID=${{ STEPS.SETUP.OUTPUTS.RUNNER_UID }}
106117
LINUX_IMAGE=${{ VARS.RHEL_LINUX_IMAGE }}
118+
GITHUB_USER=${{ GITHUB.REPOSITORY_OWNER }}
119+
GITHUB_REPO=${{ STEPS.SETUP.OUTPUTS.REPOSITORY_NAME }}
120+
GITHUB_BRANCH=${{ GITHUB.HEAD_REF || GITHUB.REF_NAME }}
107121
108122
# Note: The digest comes from `buildx`, not the metadata.
109123
# https://github.com/actions/attest-build-provenance

.github/workflows/rpm-builder.yml

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
name: RPM Builder
2+
description: It builds RPM packages and Docker images, with these preinstalled.
23

34
on:
45
push:
@@ -35,8 +36,10 @@ jobs:
3536
runner: ${{ VARS.RUNNER_ARM }}
3637
image: rpm-builder-arm64
3738
outputs:
39+
ARTIFACT_NAME: ${{ STEPS.SETUP.OUTPUTS.ARTIFACT_NAME }}
40+
RUNNER_GID: ${{ STEPS.SETUP.OUTPUTS.RUNNER_GID }}
3841
RUNNER_UID: ${{ STEPS.SETUP.OUTPUTS.RUNNER_UID }}
39-
RUNNER:GID: ${{ STEPS.SETUP.OUTPUTS.RUNNER_GID }}
42+
4043
steps:
4144
- uses: 'actions/checkout@v4'
4245
- uses: 'docker/login-action@v3'
@@ -61,16 +64,13 @@ jobs:
6164
if: ${{ MATRIX.PLATFORM == 'linux/arm64' }}
6265
with: { platforms: arm64 }
6366

64-
- shell: bash
67+
- name: Run shell script, which determines the repository name
68+
shell: bash
6569
id: setup
6670
run: |
71+
echo "REPOSITORY_NAME=${GITHUB_REPOSITORY#$GITHUB_REPOSITORY_OWNER/}" >> $GITHUB_OUTPUT
6772
echo "RUNNER_GID=$(id -g)" >> $GITHUB_OUTPUT
6873
echo "RUNNER_UID=$(id -u)" >> $GITHUB_OUTPUT
69-
REPOSITORY_NAME=${GITHUB_REPOSITORY#$GITHUB_REPOSITORY_OWNER/}
70-
echo "REPOSITORY_NAME=${REPOSITORY_NAME}" >> $GITHUB_OUTPUT
71-
echo "::group::Setup Info"
72-
echo "::notice file=rpm-builder.yml,title=Repository: $REPOSITORY_NAME"
73-
echo "::endgroup::"
7474
7575
- uses: 'docker/build-push-action@v6'
7676
id: build
@@ -83,12 +83,12 @@ jobs:
8383
labels: ${{ STEPS.METADATA.OUTPUTS.LABELS }}
8484
tags: ${{ STEPS.METADATA.OUTPUTS.TAGS }}
8585
build-args: |
86-
GITHUB_USER=${{ GITHUB.REPOSITORY_OWNER }}
87-
GITHUB_REPO=${{ STEPS.SETUP.OUTPUTS.REPOSITORY_NAME }}
88-
GITHUB_BRANCH=${{ GITHUB.HEAD_REF || GITHUB.REF_NAME }}
8986
RUNNER_GID=${{ STEPS.SETUP.OUTPUTS.RUNNER_GID }}
9087
RUNNER_UID=${{ STEPS.SETUP.OUTPUTS.RUNNER_UID }}
9188
LINUX_IMAGE=${{ VARS.RHEL_LINUX_IMAGE }}
89+
GITHUB_USER=${{ GITHUB.REPOSITORY_OWNER }}
90+
GITHUB_REPO=${{ STEPS.SETUP.OUTPUTS.REPOSITORY_NAME }}
91+
GITHUB_BRANCH=${{ GITHUB.HEAD_REF || GITHUB.REF_NAME }}
9292
9393
# Note: The digest comes from `buildx`, not the metadata.
9494
# https://github.com/actions/attest-build-provenance

docker/rhel-integration/Dockerfile

Lines changed: 18 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,18 @@
1-
# Dockerfile based on `rockylinux/rockylinux:9.5`
1+
# RHEL Integration Dockerfile
22
ARG LINUX_IMAGE=rockylinux/rockylinux:9.5
33
FROM $LINUX_IMAGE AS base_image
44
LABEL description="RHEL Integration"
55
LABEL version="1.0.2"
66
LABEL repository="https://github.com/google/android-cuttlefish"
77
LABEL maintainer="Martin Zeitler"
8+
RUN [ "touch", "/root/.dockerenv" ]
89
SHELL [ "/bin/bash", "-c" ]
9-
10-
# Arguments
11-
ARG RUNNER_GID="118"
12-
ARG RUNNER_UID="1001"
13-
ENV GID="${RUNNER_GID}"
14-
ENV UID="${RUNNER_UID}"
15-
16-
# Adding the user provides the home directory.
17-
RUN groupadd -f -g ${GID} docker
18-
RUN useradd -g ${GID} -u ${UID} -s /bin/bash runner
19-
20-
# Don't ask for the `sudo` password.
21-
RUN [ "echo", "%docker", "ALL=(ALL)", "NOPASSWD:", "ALL", ">", "/etc/sudoers.d/docker.conf" ]
10+
WORKDIR "/root"
11+
USER "root"
2212

2313
# The EPEL repository installs `dnf-core-plugin` (`config-manager` and `builddeps`) and provides `ncurses-compat-libs`.
2414
# Configuring further package repositories: / https://wiki.rockylinux.org/rocky/repo/#extra-repositories
25-
RUN [ "dnf", "-y", "install", "https://dl.fedoraproject.org/pub/epel/epel-release-latest-9.noarch.rpm" ]
15+
RUN [ "dnf", "-y", "install", "https://dl.fedoraproject.org/pub/epel/epel-release-latest-9.noarch.rpm"]
2616
RUN [ "rm", "/etc/yum.repos.d/epel-cisco-openh264.repo" ]
2717
RUN [ "dnf", "config-manager", "--set-enabled", "crb" ]
2818
RUN [ "dnf", "-y", "upgrade" ]
@@ -31,9 +21,7 @@ RUN [ "dnf", "clean", "all" ]
3121

3222
# Integration
3323
FROM base_image AS integration
34-
35-
# Provide an interactive shell.
36-
ENTRYPOINT [ "/bin/bash" ]
24+
ARG ARTIFACT_PATH=./.rpms
3725

3826
# Expose Operator Port (HTTP:1080, HTTPS:1443)
3927
EXPOSE 1080 1443
@@ -47,30 +35,19 @@ EXPOSE 15550-15560
4735
# Expose ADB
4836
EXPOSE 6520-6620
4937

50-
# https://docs.docker.com/reference/dockerfile/#notes-about-specifying-volumes
51-
# The host directory is declared at container run-time, with `--volume`, eg.
52-
# --volume /home/username/android-cuttlefish/.rpms/:/home/github/.rpms
53-
RUN [ "mkdir", "/home/runner/.rpms" ]
54-
VOLUME [ "/home/runner/.rpms" ]
55-
WORKDIR "/home/runner"
56-
57-
# Import Google RPM repository public key.
58-
# https://www.google.com/linuxrepositories/
59-
RUN [ "dnf", "-y", "install", "wget"]
60-
RUN [ "wget", "https://dl.google.com/linux/linux_signing_key.pub" ]
61-
RUN [ "rpm", "--import", "linux_signing_key.pub" ]
38+
# Restore build artifacts.
39+
RUN [ "mkdir", "/root/.rpms" ]
40+
COPY [ "${ARTIFACT_PATH}/cuttlefish-integration-*", "/root/.rpms" ]
41+
COPY [ "${ARTIFACT_PATH}/cuttlefish-user-*", "/root/.rpms/" ]
42+
COPY [ "${ARTIFACT_PATH}/cuttlefish-base-*", "/root/.rpms/" ]
6243

63-
# Add prebuilt RPM packages and install them.
64-
RUN [ "touch", "/home/runner/.dockerenv" ]
65-
COPY [ "/home/runner/work/_temp/.rpms/cuttlefish-integration-*", "/home/runner/.rpms/" ]
66-
COPY [ "/home/runner/work/_temp/.rpms/cuttlefish-user-*", "/home/runner/.rpms/" ]
67-
COPY [ "/home/runner/work/_temp/.rpms/cuttlefish-base-*", "/home/runner/.rpms/" ]
68-
# COPY [ "./.rpms/cuttlefish-integration-*", "/home/runner/.rpms/" ]
69-
# COPY [ "./.rpms/cuttlefish-user-*", "/home/runner/.rpms/" ]
70-
# COPY [ "./.rpms/cuttlefish-base-*", "/home/runner/.rpms/" ]
44+
# Container scripts.
45+
COPY [ "./docker/rpm-builder/scripts/install_rpm.sh", "/root/install_rpm.sh" ]
46+
RUN [ "chmod", "+x", "/root/install_rpm.sh" ]
7147

72-
RUN for FILE in /home/runner/.rpms/* ; do dnf -y install $FILE; done
48+
# Install RPM.
49+
RUN [ "/bin/bash", "-c", "/root/install_rpm.sh", "integration" ]
7350
RUN [ "dnf", "clean", "all" ]
7451

75-
# Run commands as user `runner`, who is the owner of the RPM packages.
76-
USER "runner"
52+
# Provide an interactive shell.
53+
ENTRYPOINT [ "/bin/bash" ]

0 commit comments

Comments
 (0)