Skip to content

Commit

Permalink
Add dockerfile && docker image actions
Browse files Browse the repository at this point in the history
  • Loading branch information
andrikoz committed Jan 5, 2024
1 parent 2c4adfb commit c7a0557
Show file tree
Hide file tree
Showing 3 changed files with 47 additions and 32 deletions.
32 changes: 0 additions & 32 deletions .github/workflows/base.yml

This file was deleted.

23 changes: 23 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: build
on: [push]
jobs:
docker:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build and push
uses: docker/build-push-action@v5
with:
platforms: linux/amd64
context: .
push: true
tags: ghcr.io/bluegroundltd/librdkafka:latest
24 changes: 24 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
FROM --platform=linux/amd64 debian:bullseye-slim AS rdkafka-builder
RUN apt-get update && apt-get install -yqq \
build-essential \
git \
libcurl4-openssl-dev \
liblz4-dev \
libsasl2-dev \
libssl-dev \
libtool-bin \
libxml2-dev \
libzstd-dev \
pkg-config \
python3 \
rapidjson-dev \
zlib1g-dev

# linking the libxml library where the librdkafka build script expects it
RUN ln -sf /usr/lib/x86_64-linux-gnu/pkgconfig/libxml-2.0.pc /usr/lib/x86_64-linux-gnu/pkgconfig/libxml2.pc

COPY . .

RUN ./configure && \
make && \
make install

0 comments on commit c7a0557

Please sign in to comment.