Skip to content

Commit 625d741

Browse files
weizhouapacheclaude
andcommitted
Add ubuntu2604.v1 for ACS 4.23.0.0
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
1 parent ca9a545 commit 625d741

5 files changed

Lines changed: 88 additions & 0 deletions

File tree

‎.github/workflows/build-docker-image.yml‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,11 @@ jobs:
5757
- name: Set Docker image FULL TAG
5858
run: echo "FULL_TAG=$(if [ "${{ secrets.DOCKER_REGISTRY }}" = "" ];then echo ${DOCKER_REPOSITORY}/cloudstack-builder:${TAG};else echo ${{ secrets.DOCKER_REGISTRY }}/${DOCKER_REPOSITORY}/cloudstack-builder:${TAG};fi)" >> $GITHUB_ENV
5959

60+
- name: Build the Docker image for cloudstack-builder
61+
run: cd ubuntu2604.v1 && docker build . --file Dockerfile --tag ${FULL_TAG}ubuntu2604.v1
62+
- name: Push Docker image to Docker Registry
63+
run: cd .. && docker push ${FULL_TAG}ubuntu2604.v1
64+
6065
- name: Build the Docker image for cloudstack-builder
6166
run: cd ubuntu2404.v2 && docker build . --file Dockerfile --tag ${FULL_TAG}ubuntu2404.v2
6267
- name: Push Docker image to Docker Registry

‎README.md‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ Contents
1919

2020
| **Docker image** | **CloudStack versions** | **Software Versions** | **Note** |
2121
|---------------------|-------------------------------|-----------------------|----------------------|
22+
| **ubuntu2604.v1** | 4.23.x | JDK 21, nodejs 24 | DEB packages for Ubuntu distros |
2223
| **ubuntu2404.v2** | 4.22.x | JDK 17, nodejs 20 | DEB packages for Ubuntu distros |
2324
| **rocky9.v1** | 4.22.x | JDK 17, nodejs 20 | RPM packages for RHEL/Rocky Linux/AlmaLinux/OracleLinux 8/9/10 distros |
2425
| **oraclelinux10.v1**| 4.22.x | JDK 21, nodejs 20 | RPM packages for RHEL/Rocky Linux/AlmaLinux/OracleLinux 8/9/10 distros |

‎config.ubuntu2604.v1.sample‎

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
2+
# The repository of the image. Default is weizhouapache/cloudstack-builder
3+
REPO=weizhouapache/cloudstack-builder
4+
5+
# The name of the image
6+
IMAGE=ubuntu2604.v1
7+
8+
# The source directory or git repository
9+
# This will be mounted or cloned to /source the docker container.
10+
SOURCE=https://github.com/apache/cloudstack.git
11+
12+
# The directory where the packages will be.
13+
# This will be mounted to /output the docker container.
14+
OUTPUT=/tmp
15+
16+
# The CloudStack version, branch name or commit SHA.
17+
VERSION=4.23.0.0
18+
19+
# The build options.
20+
# The default value for is "-Dnoredist -DskipTests -Dsystemvm-kvm -Dsystemvm-xen -Dsystemvm-vmware"
21+
# Please refer to https://github.com/weizhouapache/docker-cloudstack-builder/blob/main/README.md
22+
BUILD_OPTS=
23+
24+
# Please set to sudo if use a non-root user
25+
SUDO=

‎ubuntu2604.v1/Dockerfile‎

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
FROM ubuntu:26.04
2+
MAINTAINER Wei Zhou <weizhou@apache.org>
3+
4+
ENV DEBIAN_FRONTEND noninteractive
5+
6+
RUN apt update -qq && \
7+
apt upgrade -y && \
8+
apt-get install -y dpkg-dev python3 debhelper openjdk-21-jdk genisoimage python3-mysql.connector maven lsb-release devscripts python3-setuptools git wget curl jq
9+
10+
RUN curl -sL https://deb.nodesource.com/setup_24.x | bash - \
11+
&& apt-get install -y nodejs
12+
13+
COPY entrypoint.sh /entrypoint.sh
14+
15+
ENTRYPOINT ["/entrypoint.sh"]

‎ubuntu2604.v1/entrypoint.sh‎

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
#!/bin/bash -x
2+
3+
# Print system information
4+
mvn -version
5+
java --version
6+
javac -version
7+
8+
SOURCE_DIR=/source/
9+
OUTPUT_DIR=/output/
10+
BUILD_OPTS_DEFAULT="-Dnoredist -DskipTests -Dsystemvm-kvm -Dsystemvm-xen -Dsystemvm-vmware -T2"
11+
12+
SOURCE=${SOURCE:-}
13+
VERSION=${VERSION:-}
14+
BUILD_OPTS=${BUILD_OPTS:-$BUILD_OPTS_DEFAULT}
15+
16+
if [[ $SOURCE =~ http.* ]] || [[ $SOURCE =~ git.* ]]; then
17+
if [ -d "$SOURCE_DIR" ]; then
18+
echo "$SOURCE_DIR already exists in the container"
19+
exit 1
20+
fi
21+
git clone $SOURCE $SOURCE_DIR
22+
elif [ -z "$SOURCE_DIR" ] || [ ! -d "$SOURCE_DIR" ] || [ ! -f "$SOURCE_DIR/pom.xml" ]; then
23+
echo "Source $SOURCE_DIR does not exist in the container"
24+
exit 1
25+
fi
26+
if [ ! -d "$OUTPUT_DIR" ]; then
27+
echo "$OUTPUT_DIR does not exist in the container"
28+
exit 1
29+
fi
30+
31+
cd $SOURCE_DIR
32+
if [ ! -z "$VERSION" ]; then
33+
git checkout $VERSION
34+
fi
35+
36+
# Packaging
37+
NODE_OPTIONS=--openssl-legacy-provider ACS_BUILD_OPTS=$BUILD_OPTS packaging/build-deb.sh
38+
39+
mv $SOURCE_DIR/../cloudstack-*.deb $OUTPUT_DIR
40+
if [[ $SOURCE =~ http.* ]] || [[ $SOURCE =~ git.* ]]; then
41+
rm -rf $SOURCE_DIR
42+
fi

0 commit comments

Comments
 (0)