Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error with docker-compose.yml #33

Open
meigea opened this issue Nov 21, 2018 · 1 comment
Open

Error with docker-compose.yml #33

meigea opened this issue Nov 21, 2018 · 1 comment

Comments

@meigea
Copy link

meigea commented Nov 21, 2018

I have tried it with docker-cmd-line like docker run -ti -e .... and run well, but run bad with docker-compose

My-docker-compose

  mysql:
    container_name: mysql-server
    image: 'sameersbn/mysql:5.7.22-1'
    restart: always
    container_name: mysql
    volumes:
      - /srv/docker/data/mysqldata:/var/lib/mysql
    ports:
      - '3306:3306'
    environment:
     - DB_USER=admin007
     - DB_PASS=myadmin@816
     - DB_NAME=djsite
     - DB_REMOTE_ROOT_NAME=root
     - DB_REMOTE_ROOT_PASS=meigea@123
     - MYSQL_CHARSET=utf8mb4
     - MYSQL_COLLATION=utf8_bin

the log of Error

mysql exited with code 1
mysql          | Creating database "djsite"...
mysql          | ERROR 1253 (42000) at line 1: COLLATION 'utf8_bin' is not valid for CHARACTER SET 'utf8mb4'
mysql          | Creating database "djsite"...
mysql          | ERROR 1253 (42000) at line 1: COLLATION 'utf8_bin' is not valid for CHARACTER SET 'utf8mb4'
mysql          | Creating database "djsite"...
mysql          | ERROR 1253 (42000) at line 1: COLLATION 'utf8_bin' is not valid for CHARACTER SET 'utf8mb4'
mysql          | Creating database "djsite"...
mysql          | ERROR 1253 (42000) at line 1: COLLATION 'utf8_bin' is not valid for CHARACTER SET 'utf8mb4'
mysql          | Creating database "djsite"...
mysql          | ERROR 1253 (42000) at line 1: COLLATION 'utf8_bin' is not valid for CHARACTER SET 'utf8mb4'
mysql          | Creating database "djsite"...
mysql          | ERROR 1253 (42000) at line 1: COLLATION 'utf8_bin' is not valid for CHARACTER SET 'utf8mb4'
mysql          | Creating database "djsite"...
mysql          | ERROR 1253 (42000) at line 1: COLLATION 'utf8_bin' is not valid for CHARACTER SET 'utf8mb4'
mysql          | Creating database "djsite"...
mysql          | ERROR 1253 (42000) at line 1: COLLATION 'utf8_bin' is not valid for CHARACTER SET 'utf8mb4'
mysql          | Creating database "djsite"...
mysql          | ERROR 1253 (42000) at line 1: COLLATION 'utf8_bin' is not valid for CHARACTER SET 'utf8mb4'
@nguyenl95
Copy link

@meigea It looks like character set doesn't support collation. You may consider to use default repo's charset and collation utf8 and utf8_unicode_ci.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants