# docker login -u USER -p PASS nexus3.onap.org:10001
# Uses healthcheck feature added in docker-compose v2.1
-version: '2.1'
+version: '3.1'
services:
portal-db:
- image: portal_mariadb
+ image: mariadb
+# image: mysql
container_name: portal_mariaDB
+ ports:
+ - 3306:3306
+ restart: on-failure
environment:
- MYSQL_DATABASE: testdb
+ - MYSQL_DATABASE=testdb
+ - MYSQL_USER=portal
+ - MYSQL_PASSWORD=Test123456
+ - MYSQL_RANDOM_ROOT_PASSWORD=yes
healthcheck:
test: ["CMD", "mysqladmin" ,"ping", "-h", "localhost"]
networks:
ports:
- 8080:8080
depends_on:
- portal-db:
- condition: service_healthy
+ - portal-db
networks:
- backend
+++ /dev/null
-FROM mariadb:latest
-
-ADD my.cnf /etc/mysql/my.cnf
-ENV MYSQL_USER portal
-ENV MYSQL_PASSWORD Test123456
-ENV MYSQL_ROOT_PASSWORD klasjfhaskrigudsb
-EXPOSE 3306
\ No newline at end of file
# escpecially if they contain "#" chars...
# Remember to edit /etc/mysql/debian.cnf when changing the socket location.
[client]
-port = 3306
+#port = 3306
socket = /var/run/mysqld/mysqld.sock
# Here is entries for some specific programs
#user = mysql
pid-file = /var/run/mysqld/mysqld.pid
socket = /var/run/mysqld/mysqld.sock
-port = 3306
+#port = 3306
basedir = /usr
datadir = /var/lib/mysql
tmpdir = /tmp
# Read the manual for more InnoDB related options. There are many!
default_storage_engine = InnoDB
# you can't just change log file size, requires special procedure
-#innodb_log_file_size = 50M
+#innodb_log_file_size = 2047M
innodb_buffer_pool_size = 256M
-innodb_log_buffer_size = 8M
+innodb_log_buffer_size = 32M
innodb_file_per_table = 1
innodb_open_files = 400
innodb_io_capacity = 400