Giter VIP home page Giter VIP logo

docker-alpine-glibc's Introduction

prantlf/alpine-glibc

Docker image: Alpine Linux with GNU C Library (glibc) for compatibility

This image is supposed to serve as a base for small images (Alpine Linux) which need to include tools built against GNU C Library (glibc). This image is built automatically on the top of the tag latest from the Alpine repository, so that it is always based on the latest Alpine Linux. The package alpine-pkg-glibc has to be updated from time to time by editing the Dockerfile and triggering a new build manually.

If you have trouble pulling the image from the Docker's default hub.docker.com, try gitlab.com, where this project is primarily maintained: registry.gitlab.com/prantlf/docker-alpine-glibc.

Tags

Tags consist of versions of the Alpine Linux and GLIBC in this order, separated by a hyphen. The latest tag maps to the latest <alpine> tag. The latest <alpine> tag maps to the latest <alpine>-<glibc> tag. The bin and <alpine>-bin tags contain the glibc-bin package installed too.

  • latest, bin
  • 3.16, 3.16-bin, 3.16-2.35, 3.16-2.35-bin
  • 3.15, 3.15-bin, 3.14, 3.14-2.34, 3.14-2.33, 3.13, 3.12

Install

docker pull prantlf/alpine-glibc
docker pull prantlf/alpine-glibc:3.16

Use

You can create your own image based on this one by referring to it from your Dockerfile:

FROM prantlf/alpine-glibc:latest

The final image can use the English locale by setting the environment variable LANG to C.UTF-8 or en_US.UTF-8.

See the git-p4 Docker image repository for an example.

If you install glibc-i18n-2.34-r0.apk and create a locale by /usr/glibc-compat/bin/localedef, you will need to unpack the charmap. For example:

gunzip --keep /usr/glibc-compat/share/i18n/charmaps/UTF-8.gz
/usr/glibc-compat/bin/localedef -i cs_CZ -f UTF-8 cs_CZ.UTF-8

It appears, that installing another package using apk breaks the symlink to ld-linux-x86-64.so.2 in /lib64. If it happens to you, restore the symlink after executing apk:

ln -sf /usr/glibc-compat/lib/ld-linux-x86-64.so.2 /lib64/ld-linux-x86-64.so.2

Build, Test and Publish

The local image is built as alpine-glibc and pushed to the docker hub as prantlf/alpine-glibc:latest.

# Remove an old local image:
make clean
# Check the `Dockerfile`:
make lint
# Build a new local image:
make build
# Enter an interactive shell inside the created image:
make run
# Login to the docker hub:
make login
# Push the local image to the docker hub:
make push
# Pull the image from the docker hub:
make pull
# Add version tags to the published image:
make tag

License

Copyright (c) 2020-2022 Ferdinand Prantl

Licensed under the MIT license.

docker-alpine-glibc's People

Contributors

prantlf avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.