Giter Site home page Giter Site logo

bianjp / docker-mariadb-alpine Goto Github PK

View Code? Open in Web Editor NEW
36.0 36.0 27.0 16 KB

[DEPRECATED] Lightweight MariaDB docker image with Alpine Linux.

Home Page: https://hub.docker.com/r/bianjp/mariadb-alpine/

License: MIT License

Shell 92.35% Dockerfile 7.65%
alpine docker mariadb mariadb-docker-image

docker-mariadb-alpine's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

docker-mariadb-alpine's Issues

Scripts under "docker-entrypoint-initdb.d" are not launched correctly

If I add a custom script under "docker-entrypoint-initdb.d" it's not launched correctly:

...
/usr/local/bin/docker-entrypoint.sh: running initialize.sh
/usr/local/bin/docker-entrypoint.sh: .: line 174: can't open 'initialize.sh'
...

Problably because the script seems launched from "./initialize.sh" instead of from "/docker-entrypoint-initdb.d/initialize.sh"

mariadb version

Hi,

Your documentation announce the latest mariadb as 10.2 (from alpine package) but it's 10.1 in your container.

Could you update please ?

$ docker-compose exec mysql mysql -V
mysql  Ver 15.1 Distrib 10.1.32-MariaDB, for Linux (x86_64) using readline 5.1

Unknown database ?

I try to instantiate it like this:

docker run --name mariadb-native -e MYSQL_USER="admin" -e MYSQL_PASSWORD="admin" -e MYSQL_ROOT_PASSWORD="admin" -e MYSQL_DATABASE="mariadb-test" -d bianjp/mariadb-alpine:latest

As the image boots, docker logs mariadb-native shows this:

Database initialized 180416 22:03:41 mysqld_safe Logging to '/var/lib/mysql/2105ae517565.err'. 180416 22:03:41 mysqld_safe Starting mysqld daemon with databases from /var/lib/mysql MySQL init process in progress... ERROR 1049 (42000): Unknown database '"mariadb-test"'

Unable to load database dump in in /docker-entrypoint-initdb.d

When I try to load a SQL dump at init I am getting an error that the database does not exist, however it seems to be included the double quotes in the name (See Unknown database '"my_database"' in the logs). Switching the image to mariadb:10.4 with no other changes populates the database as expected.

docker-compose.yml

version: '3.3'

services:
  app_db:
    image: bianjp/mariadb-alpine
    restart: "no"
    volumes:
      - ./initdb.d:/docker-entrypoint-initdb.d
    environment:
      MYSQL_ROOT_PASSWORD: root
      MYSQL_DATABASE: my_database
      MYSQL_USER: my_user
      MYSQL_PASSWORD: my_password

Container logs

app_db_1  | Database initialized
app_db_1  | MySQL init process in progress...
app_db_1  | 
app_db_1  | /usr/local/bin/docker-entrypoint.sh: running /docker-entrypoint-initdb.d/my_database.sql
app_db_1  | ERROR 1049 (42000): Unknown database '"my_database"'

Using the mariadb images, I get these logs with the same config/volumes (some lines omitted)

app_db_1  | Database initialized
app_db_1  | MySQL init process in progress...
app_db_1  | 
app_db_1  | /usr/local/bin/docker-entrypoint.sh: running /docker-entrypoint-initdb.d/my_database.sql
app_db_1  | 
app_db_1  | MySQL init process done. Ready for start up.
app_db_1  | 2019-10-30  1:47:02 0 [Note] mysqld: ready for connections.
app_db_1  | Version: '10.4.8-MariaDB-1:10.4.8+maria~bionic'  socket: '/var/run/mysqld/mysqld.sock'  port: 3306  mariadb.org binary distribution

Support for additional my.cnf conf file ?

Is there support to specify an additional my.cnf file that is used to customized/override the default one?
I've tried with:

docker run --name mariadb-native -v /home/ubuntu/custom:/etc/mysql/conf.d ...
where inside custom/custom-file.cnf there is:

[mysqld]
innodb_buffer_pool_size=64M

Is this supported ?

多CPU架构支持

建议:

增加多CPU架构支持。项目是基于Alpine,它的镜像是可以支持x86_64, arm等CPU的。当前项目未依赖具体CPU架构的程序,可以增加多CPU架构。

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.