Skip to content

Commit df5dc09

Browse files
committed
drop update script in favour of renovate
don't ask me about the sqlite stuff.. Signed-off-by: clux <sszynrae@gmail.com>
1 parent a0a52d6 commit df5dc09

File tree

6 files changed

+22
-123
lines changed

6 files changed

+22
-123
lines changed

.github/workflows/nightly.yml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,9 @@ jobs:
2626
platform: [linux/amd64, linux/arm64]
2727
include:
2828
- platform: linux/amd64
29-
dockerfile: Dockerfile
3029
arch: amd64
3130
target_dir: x86_64-unknown-linux-musl
3231
- platform: linux/arm64
33-
dockerfile: Dockerfile
3432
arch: arm64
3533
target_dir: aarch64-unknown-linux-musl
3634
steps:
@@ -67,7 +65,6 @@ jobs:
6765
context: .
6866
platforms: ${{ matrix.platform }}
6967
labels: ${{ steps.meta.outputs.labels }}
70-
file: ${{ matrix.dockerfile }}
7168
push: false
7269
load: true
7370
tags: rustmusl-temp

.github/workflows/stable.yml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,11 +26,9 @@ jobs:
2626
platform: [linux/amd64, linux/arm64]
2727
include:
2828
- platform: linux/amd64
29-
dockerfile: Dockerfile
3029
arch: amd64
3130
target_dir: x86_64-unknown-linux-musl
3231
- platform: linux/arm64
33-
dockerfile: Dockerfile
3432
arch: arm64
3533
target_dir: aarch64-unknown-linux-musl
3634
steps:
@@ -79,7 +77,6 @@ jobs:
7977
context: .
8078
platforms: ${{ matrix.platform }}
8179
labels: ${{ steps.meta.outputs.labels }}
82-
file: ${{ matrix.dockerfile }}
8380
push: false
8481
load: true
8582
tags: rustmusl-temp

Dockerfile

Lines changed: 19 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -41,24 +41,26 @@ RUN <<EOF
4141
EOF
4242

4343
# Install a more recent release of protoc:
44-
ARG PROTOBUF_VER="31.0"
44+
# renovate: datasource=github-releases depName=protocolbuffers/protobuf versioning=semver-coerced
45+
ARG PB_VERSION="v31.0"
4546
RUN <<EOF
4647
if [[ ${DOCKER_TARGET_ARCH} == 'aarch64' ]]; then
4748
DOCKER_TARGET_ARCH=aarch_64
4849
fi
4950

50-
ASSET_NAME="protoc-${PROTOBUF_VER}-linux-${DOCKER_TARGET_ARCH}"
51-
curl -fsSL -o protoc.zip "https://github.com/protocolbuffers/protobuf/releases/download/v${PROTOBUF_VER}/${ASSET_NAME}.zip"
51+
ASSET_NAME="protoc-${PB_VERSION#v}-linux-${DOCKER_TARGET_ARCH}"
52+
curl -fsSL -o protoc.zip "https://github.com/protocolbuffers/protobuf/releases/download/v${PB_VERSION#v}/${ASSET_NAME}.zip"
5253

5354
unzip -j -d /usr/local/bin protoc.zip bin/protoc
5455
rm -rf protoc.zip
5556
EOF
5657

5758
# Install prebuilt sccache based on platform:
58-
ARG SCCACHE_VER="0.10.0"
59+
# renovate: datasource=github-releases depName=mozilla/sccache
60+
ARG SCCACHE_VERSION="0.10.0"
5961
RUN <<EOF
60-
ASSET_NAME="sccache-v${SCCACHE_VER}-${DOCKER_TARGET_ARCH}-unknown-linux-musl"
61-
curl -fsSL "https://github.com/mozilla/sccache/releases/download/v${SCCACHE_VER}/${ASSET_NAME}.tar.gz" \
62+
ASSET_NAME="sccache-v${SCCACHE_VERSION}-${DOCKER_TARGET_ARCH}-unknown-linux-musl"
63+
curl -fsSL "https://github.com/mozilla/sccache/releases/download/v${SCCACHE_VERSION}/${ASSET_NAME}.tar.gz" \
6264
| tar -xz -C /usr/local/bin --strip-components=1 --no-same-owner "${ASSET_NAME}/sccache"
6365
EOF
6466

@@ -70,10 +72,11 @@ ENV CC=musl-gcc \
7072

7173
# Build zlib
7274
FROM base AS build-zlib
73-
ARG ZLIB_VER="1.3.1"
75+
# renovate: datasource=github-releases depName=madler/zlib
76+
ARG ZLIB_VERSION="1.3.1"
7477
WORKDIR /src/zlib
7578
RUN <<EOF
76-
curl -fsSL "https://zlib.net/zlib-${ZLIB_VER}.tar.gz" | tar -xz --strip-components=1
79+
curl -fsSL "https://zlib.net/zlib-${ZLIB_VERSION}.tar.gz" | tar -xz --strip-components=1
7780

7881
export CC="musl-gcc -fPIC -pie"
7982
export CFLAGS="-I${PREFIX}/include"
@@ -85,10 +88,13 @@ EOF
8588

8689
# Build libsqlite3 using same configuration as the alpine linux main/sqlite package
8790
FROM base AS build-sqlite
88-
ARG SQLITE_VER="3490200"
91+
# renovate: datasource=github-tags packageName=sqlite/sqlite versioning=semver-coerced
92+
ARG SQLITE_VERSION="3.49.2"
8993
WORKDIR /src/sqlite
9094
RUN <<EOF
91-
curl -fsSL "https://www.sqlite.org/2025/sqlite-autoconf-${SQLITE_VER}.tar.gz" | tar -xz --strip-components=1
95+
# see product names and info at https://sqlite.org/download.html for why this line constructs the tarball name from a semver version
96+
SQL_ID="$(awk -F. '{print $1}' <<< "${SQLITE_VERSION}")$(printf "%02d" $(awk -F. '{print $2}' <<< "${SQLITE_VERSION}"))$(printf "%02d" $(awk -F. '{print $3}' <<< "${SQLITE_VERSION}"))00"
97+
curl -fsSL "https://www.sqlite.org/2025/sqlite-autoconf-${SQL_ID}.tar.gz" | tar -xz --strip-components=1
9298

9399
export CC="musl-gcc -fPIC -pie"
94100
export CFLAGS="-DSQLITE_ENABLE_FTS4 -DSQLITE_ENABLE_FTS3_PARENTHESIS -DSQLITE_ENABLE_FTS5 -DSQLITE_ENABLE_COLUMN_METADATA -DSQLITE_SECURE_DELETE -DSQLITE_ENABLE_UNLOCK_NOTIFY -DSQLITE_ENABLE_RTREE -DSQLITE_USE_URI -DSQLITE_ENABLE_DBSTAT_VTAB -DSQLITE_ENABLE_JSON1"
@@ -102,15 +108,16 @@ FROM base AS install-rustup
102108
ARG CHANNEL
103109
# Use specific version of Rustup:
104110
# https://github.com/clux/muslrust/pull/63
105-
ARG RUSTUP_VER="1.28.2"
111+
# renovate: datasource=github-tags packageName=rust-lang/rustup
112+
ARG RUSTUP_VERSION=1.28.2
106113
# Better support for running container user as non-root:
107114
# https://github.com/clux/muslrust/pull/101
108115
# Uses `--no-modify-path` as `PATH` is set explicitly
109116
ENV RUSTUP_HOME=/opt/rustup
110117
ENV CARGO_HOME=/opt/cargo
111118
RUN <<EOF
112119
RUST_ARCH="${DOCKER_TARGET_ARCH}-unknown-linux-gnu"
113-
curl -fsSL -o rustup-init "https://static.rust-lang.org/rustup/archive/${RUSTUP_VER}/${RUST_ARCH}/rustup-init"
120+
curl -fsSL -o rustup-init "https://static.rust-lang.org/rustup/archive/${RUSTUP_VERSION}/${RUST_ARCH}/rustup-init"
114121
chmod +x rustup-init
115122
mkdir -p /opt/{cargo,rustup}
116123

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,9 +53,9 @@ The following system libraries are compiled against `musl-gcc`:
5353
- sqlite3 ([libsqlite3-sys crate](https://github.com/jgallagher/rusqlite/tree/master/libsqlite3-sys) used by [diesel](https://github.com/diesel-rs/diesel))
5454
- zlib
5555

56-
Note that these libraries **may be removed** if sensible and popular Rust crates can replace them in the future.
56+
These dependencies are updated with renovate from git releases.
5757

58-
In the mean time, we **[try](https://github.com/clux/muslrust/blob/main/update_libs.py)** to keep these up to date.
58+
Note that these libraries **may be removed** if sensible and popular Rust crates can replace them in the future.
5959

6060
Removed Libraries;
6161

justfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ default:
44
@just --list --unsorted --color=always
55

66
_build channel platform:
7-
docker build --build-arg CHANNEL="{{channel}}" --platform="{{platform}}" -t rustmusl-temp . -f Dockerfile
7+
docker build --build-arg CHANNEL="{{channel}}" --platform="{{platform}}" -t rustmusl-temp .
88
# Build the stable x86 container
99
build-stable-amd: (_build "stable" "linux/amd64")
1010
# Build the nightly x86 container

update_libs.py

Lines changed: 0 additions & 102 deletions
This file was deleted.

0 commit comments

Comments
 (0)