Skip to content

Commit

Permalink
/go/performance/continuous_integration/SysbenchDockerfile: trying to …
Browse files Browse the repository at this point in the history
…fix docker image again
  • Loading branch information
coffeegoddd committed Feb 15, 2024
1 parent 33c0818 commit 8f86384
Showing 1 changed file with 10 additions and 23 deletions.
33 changes: 10 additions & 23 deletions go/performance/continuous_integration/SysbenchDockerfile
Original file line number Diff line number Diff line change
@@ -1,30 +1,26 @@
FROM --platform=linux/amd64 golang:1.21.2-bullseye
FROM --platform=linux/amd64 golang:1.21-alpine as gobin
FROM --platform=linux/amd64 ubuntu:22.04

COPY --from=gobin /usr/local/go/ /usr/local/go/

ENV PATH="/usr/local/go/bin:${PATH}"
ENV DEBIAN_FRONTEND=noninteractive

RUN apt update
RUN apt install -y curl wget git

# Install sysbench deps
RUN apt update -y && apt install -y \
automake \
libtool \
pkg-config \
libaio-dev \
default-libmysqlclient-dev \
libssl-dev

# Install sqlite3 from source
RUN \
apt-get install -y \
build-essential \
tcl \
lsb-release \
&& wget \
lsb-release

RUN wget \
-O sqlite.tar.gz \
https://www.sqlite.org/src/tarball/sqlite.tar.gz?r=release \
&& tar xvfz sqlite.tar.gz \
# Configure and make SQLite3 binary
# Configure and make SQLite3 binary
&& ./sqlite/configure --prefix=/usr \
&& make \
&& make install \
Expand All @@ -44,16 +40,7 @@ ENV PATH="/doltgresql/utils/doltgres_builder/cmd/doltgresBin/$DOLTGRESQL_VERSION
RUN doltgres version

WORKDIR /mysql
RUN curl -L -O https://dev.mysql.com/get/mysql-apt-config_0.8.22-1_all.deb
RUN dpkg -i mysql-apt-config_0.8.22-1_all.deb
# On 2023-12-14, the GPG key this repository uses to publish these packages expired. We make it insecure and install it anyway for now.
# See https://bugs.mysql.com/bug.php?id=113427
# Hopefully we can remove this soon.
RUN sed -i.bak \
-e 's|^deb |deb [allow-insecure=true allow-weak=true allow-downgrade-to-insecure=true] |' \
-e 's|^deb-src |deb-src [allow-insecure=true allow-weak=true allow-downgrade-to-insecure=true] |' \
/etc/apt/sources.list.d/mysql.list
RUN apt-get update && apt-get install -y --allow-unauthenticated mysql-server
RUN apt install -y mysql-server
RUN mysql --version

# Install sysbench
Expand Down

0 comments on commit 8f86384

Please sign in to comment.