Skip to content

Commit

Permalink
Restore failed rebase
Browse files Browse the repository at this point in the history
  • Loading branch information
cytopia committed Feb 28, 2019
1 parent 7539a16 commit 73dcb0d
Show file tree
Hide file tree
Showing 30 changed files with 146 additions and 433 deletions.
Empty file removed .devilbox/etc/mariadb-10.3/.keepme
Empty file.
Empty file removed .devilbox/etc/mariadb-5.5/.keepme
Empty file.
Empty file removed .devilbox/etc/mysql-5.5/.keepme
Empty file.
Empty file removed .devilbox/etc/mysql-5.6/.keepme
Empty file.
Empty file removed .devilbox/etc/mysql-5.7/.keepme
Empty file.
Empty file removed .devilbox/etc/mysql-8.0/.keepme
Empty file.
10 changes: 0 additions & 10 deletions .devilbox/etc/mysql-8.0/charset.cnf

This file was deleted.

4 changes: 2 additions & 2 deletions .devilbox/www/config.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@
putenv('RES_OPTIONS=retrans:1 retry:1 timeout:1 attempts:1');


$DEVILBOX_VERSION = 'v0.15';
$DEVILBOX_DATE = '2019-02-27';
$DEVILBOX_VERSION = 'v1.0.0-alpha1';
$DEVILBOX_DATE = '2019-02-28';
$DEVILBOX_API_PAGE = 'devilbox-api/status.json';

//
Expand Down
6 changes: 3 additions & 3 deletions .devilbox/www/htdocs/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -679,14 +679,14 @@
<?php if ($avail_mysql): ?>
<tr>
<th>mysql</th>
<td><?php echo loadClass('Helper')->getEnv('HOST_PATH_MYSQL_DATADIR').'/'.loadClass('Helper')->getEnv('MYSQL_SERVER'); ?></td>
<td>Docker volume</td>
<td>/var/lib/mysql</td>
</tr>
<?php endif; ?>
<?php if ($avail_pgsql): ?>
<tr>
<th>pgsql</th>
<td><?php echo loadClass('Helper')->getEnv('HOST_PATH_PGSQL_DATADIR').'/'.loadClass('Helper')->getEnv('PGSQL_SERVER'); ?></td>
<td>Docker volume</td>
<td>/var/lib/postgresql/data/pgdata</td>
</tr>
<?php endif; ?>
Expand All @@ -707,7 +707,7 @@
<?php if ($avail_mongo): ?>
<tr>
<th>mongo</th>
<td><?php echo loadClass('Helper')->getEnv('HOST_PATH_MONGO_DATADIR'); ?></td>
<td>Docker volume</td>
<td>/data/db</td>
</tr>
<?php endif; ?>
Expand Down
19 changes: 18 additions & 1 deletion .devilbox/www/include/lib/container/Memcd.php
Original file line number Diff line number Diff line change
Expand Up @@ -114,8 +114,25 @@ public function getKeys()
// Memcached >= 1.5
for ($i=0; $i<$cli_retries; $i++) {

// Get item number to trigger with stats cachedump
$output = array();
exec('printf "stats cachedump 1 0\nquit\n" | nc memcd 11211 | grep -E \'^ITEM\'', $output);
exec('printf "stats items\nquit\n" | nc memcd 11211 | grep -E \'items:[0-9]+:number\s[0-9]+\'', $output);
$num1 = 1;
$num2 = 0;
if (isset($output[0])) {
$matches = array();
preg_match('/items:([0-9]+):number\s([0-9]+)/', $output[0], $matches);
if (isset($matches[1])) {
$num1 = $matches[1];
}
if (isset($matches[2])) {
$num2 = $matches[2];
}
}

// Trigger stats cachedump on item number
$output = array();
exec('printf "stats cachedump '.$num1.' '.$num2.' \nquit\n" | nc memcd 11211 | grep -E \'^ITEM\'', $output);
foreach ($output as $line) {
$matches = array();
preg_match('/(^ITEM)\s*(.+?)\s*\[([0-9]+\s*b);\s*([0-9]+\s*s)\s*\]/', $line, $matches);
Expand Down
5 changes: 4 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -46,13 +46,16 @@
/cfg/mysql-5.6/*.cnf
/cfg/mysql-5.7/*.cnf
/cfg/mysql-8.0/*.cnf
/cfg/mariadb-5/*.cnf
/cfg/mariadb-5.5/*.cnf
/cfg/mariadb-10.0/*.cnf
/cfg/mariadb-10.1/*.cnf
/cfg/mariadb-10.2/*.cnf
/cfg/mariadb-10.3/*.cnf
/cfg/mariadb-10.4/*.cnf
/cfg/percona-5.5/*.cnf
/cfg/percona-5.6/*.cnf
/cfg/percona-5.7/*.cnf
/cfg/percona-8.0/*.cnf

# Ignore custom PHP.ini configs
/cfg/php-ini-5.2/*.ini
Expand Down
3 changes: 3 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -142,9 +142,12 @@ env:
- S1=PHP V1=7.2 S2=MYSQL V2=mariadb-10.0
- S1=PHP V1=7.2 S2=MYSQL V2=mariadb-10.1
- S1=PHP V1=7.2 S2=MYSQL V2=mariadb-10.2
- S1=PHP V1=7.2 S2=MYSQL V2=mariadb-10.3
- S1=PHP V1=7.2 S2=MYSQL V2=mariadb-10.4
- S1=PHP V1=7.2 S2=MYSQL V2=percona-5.5
- S1=PHP V1=7.2 S2=MYSQL V2=percona-5.6
- S1=PHP V1=7.2 S2=MYSQL V2=percona-5.7
- S1=PHP V1=7.2 S2=MYSQL V2=percona-8.0
# PHP 7.2 vs PgSQL
- S1=PHP V1=7.2 S2=PGSQL V2=9.0
- S1=PHP V1=7.2 S2=PGSQL V2=9.1
Expand Down
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ major versions.
- Use Docker volumes instead of directory mounts for stateful data (MySQL, PgSQL and MongoDB)
- This fixes various mount issues on Windows: #175 #382
- This improves general performance
- Use Official MySQL, MariaDB and Percona Docker container


## v0.15.0 [unreleased]
Expand Down
28 changes: 14 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -214,9 +214,9 @@ Every single attachable container comes with many different versions. In order t
<td><a target="_blank" title="Apache 2.2" href="https://github.com/devilbox/docker-apache-2.2">2.2</a></td>
<td><a target="_blank" title="Nginx stable" href="https://github.com/devilbox/docker-nginx-stable">stable</a></td>
<td><a target="_blank" title="PHP 5.2" href="https://github.com/devilbox/docker-php-fpm">5.2</a><sup>[1]</sup></td>
<td><a target="_blank" title="MySQL 5.5" href="https://github.com/cytopia/docker-mysql-5.5">5.5</a></td>
<td><a target="_blank" title="MariaDB 5.5" href="https://github.com/cytopia/docker-mariadb-5.5">5.5</a></td>
<td><a target="_blank" title="PerconaDB 5.5" href="https://github.com/cytopia/docker-percona-5.5">5.5</a></td>
<td><a target="_blank" title="MySQL 5.5" href="https://github.com/devilbox/docker-mysql">5.5</a></td>
<td><a target="_blank" title="MariaDB 5.5" href="https://github.com/devilbox/docker-mysql">5.5</a></td>
<td><a target="_blank" title="PerconaDB 5.5" href="https://github.com/devilbox/docker-mysql">5.5</a></td>
<td><a target="_blank" title="PgSQL 9.0" href="https://github.com/docker-library/postgres">9.0</a></td>
<td><a target="_blank" title="Redis 2.8" href="https://github.com/docker-library/redis">2.8</a></td>
<td><a target="_blank" title="Memcached 1.4" href="https://github.com/docker-library/memcached">1.4</a></td>
Expand All @@ -226,9 +226,9 @@ Every single attachable container comes with many different versions. In order t
<td><a target="_blank" title="Apache 2.4" href="https://github.com/devilbox/docker-apache-2.4">2.4</a></td>
<td><a target="_blank" title="Nginx mainline" href="https://github.com/devilbox/docker-nginx-mainline">mainline</a></td>
<td><a target="_blank" title="PHP 5.3" href="https://github.com/devilbox/docker-php-fpm">5.3</a></td>
<td><a target="_blank" title="MySQL 5.6" href="https://github.com/cytopia/docker-mysql-5.6">5.6</a></td>
<td><a target="_blank" title="MariaDB 10.0" href="https://github.com/cytopia/docker-mariadb-10.0">10.0</a></td>
<td><a target="_blank" title="PerconaDB 5.6" href="https://github.com/cytopia/docker-percona-5.6">5.6</a></td>
<td><a target="_blank" title="MySQL 5.6" href="https://github.com/devilbox/docker-mysql">5.6</a></td>
<td><a target="_blank" title="MariaDB 10.0" href="https://github.com/devilbox/docker-mysql">10.0</a></td>
<td><a target="_blank" title="PerconaDB 5.6" href="https://github.com/devilbox/docker-mysql">5.6</a></td>
<td><a target="_blank" title="PgSQL 9.1" href="https://github.com/docker-library/postgres">9.1</a></td>
<td><a target="_blank" title="Redis 3.0" href="https://github.com/docker-library/redis">3.0</a></td>
<td><a target="_blank" title="Memcached 1.5" href="https://github.com/docker-library/memcached">1.5</a></td>
Expand All @@ -238,9 +238,9 @@ Every single attachable container comes with many different versions. In order t
<td></td>
<td></td>
<td><a target="_blank" title="PHP 5.4" href="https://github.com/devilbox/docker-php-fpm">5.4</a></td>
<td><a target="_blank" title="MySQL 5.7" href="https://github.com/cytopia/docker-mysql-5.7">5.7</a></td>
<td><a target="_blank" title="MariaDB 10.1" href="https://github.com/cytopia/docker-mariadb-10.1">10.1</a></td>
<td><a target="_blank" title="PerconaDB 5.7" href="https://github.com/cytopia/docker-percona-5.7">5.7</a></td>
<td><a target="_blank" title="MySQL 5.7" href="https://github.com/devilbox/docker-mysql">5.7</a></td>
<td><a target="_blank" title="MariaDB 10.1" href="https://github.com/devilbox/docker-mysql">10.1</a></td>
<td><a target="_blank" title="PerconaDB 5.7" href="https://github.com/devilbox/docker-mysql">5.7</a></td>
<td><a target="_blank" title="PgSQL 9.2" href="https://github.com/docker-library/postgres">9.2</a></td>
<td><a target="_blank" title="Redis 3.2" href="https://github.com/docker-library/redis">3.2</a></td>
<td><a target="_blank" title="Memcached latest" href="https://github.com/docker-library/memcached">latest</a></td>
Expand All @@ -250,9 +250,9 @@ Every single attachable container comes with many different versions. In order t
<td></td>
<td></td>
<td><a target="_blank" title="PHP 5.5" href="https://github.com/devilbox/docker-php-fpm">5.5</a></td>
<td><a target="_blank" title="MySQL 8.0" href="https://github.com/cytopia/docker-mysql-8.0">8.0</a></td>
<td><a target="_blank" title="MariaDB 10.2" href="https://github.com/cytopia/docker-mariadb-10.2">10.2</a></td>
<td></td>
<td><a target="_blank" title="MySQL 8.0" href="https://github.com/devilbox/docker-mysql">8.0</a></td>
<td><a target="_blank" title="MariaDB 10.2" href="https://github.com/devilbox/docker-mysql">10.2</a></td>
<td><a target="_blank" title="PerconaDB 8.0" href="https://github.com/devilbox/docker-mysql">8.0</a></td>
<td><a target="_blank" title="PgSQL 9.3" href="https://github.com/docker-library/postgres">9.3</a></td>
<td><a target="_blank" title="Redis 4.0" href="https://github.com/docker-library/redis">4.0</a></td>
<td></td>
Expand All @@ -263,7 +263,7 @@ Every single attachable container comes with many different versions. In order t
<td></td>
<td><a target="_blank" title="PHP 5.6" href="https://github.com/devilbox/docker-php-fpm">5.6</a></td>
<td></td>
<td><a target="_blank" title="MariaDB 10.3" href="https://github.com/cytopia/docker-mariadb-10.3">10.3</a></td>
<td><a target="_blank" title="MariaDB 10.3" href="https://github.com/devilbox/docker-mysql">10.3</a></td>
<td></td>
<td><a target="_blank" title="PgSQL 9.4" href="https://github.com/docker-library/postgres">9.4</a></td>
<td><a target="_blank" title="Redis 5.0" href="https://github.com/docker-library/redis">5.0</a></td>
Expand All @@ -275,7 +275,7 @@ Every single attachable container comes with many different versions. In order t
<td></td>
<td><a target="_blank" title="PHP 7.0" href="https://github.com/devilbox/docker-php-fpm">7.0</a></td>
<td></td>
<td></td>
<td><a target="_blank" title="MariaDB 10.4" href="https://github.com/devilbox/docker-mysql">10.4</a></td>
<td></td>
<td><a target="_blank" title="PgSQL 9.5" href="https://github.com/docker-library/postgres">9.5</a></td>
<td><a target="_blank" title="Redis latest" href="https://github.com/docker-library/redis">latest</a></td>
Expand Down
File renamed without changes.
5 changes: 5 additions & 0 deletions cfg/mariadb-10.4/devilbox-custom.cnf-example
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
[mysqld]
;key_buffer_size=16M

[mysqldump]
;quick
File renamed without changes.
5 changes: 5 additions & 0 deletions cfg/mariadb-5.5/devilbox-custom.cnf-example
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
[mysqld]
;key_buffer_size=16M

[mysqldump]
;quick
File renamed without changes.
5 changes: 5 additions & 0 deletions cfg/percona-8.0/devilbox-custom.cnf-example
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
[mysqld]
;key_buffer_size=16M

[mysqldump]
;quick
42 changes: 4 additions & 38 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -303,35 +303,12 @@ services:
# MySQL Database
# ------------------------------------------------------------
mysql:
image: cytopia/${MYSQL_SERVER}:latest
image: devilbox/mysql:${MYSQL_SERVER}
hostname: mysql

environment:

##
## Debug?
##
- DEBUG_COMPOSE_ENTRYPOINT

##
## Adjust timezone
##
- TIMEZONE

##
## Adjust Root password
##
- MYSQL_ROOT_PASSWORD

##
## Socket directory Path
##
- MYSQL_SOCKET_DIR=/tmp/mysql

##
## Runtime settings
##
- MYSQL_GENERAL_LOG=${MYSQL_GENERAL_LOG}
- MYSQL_ALLOW_EMPTY_PASSWORD=yes

ports:
# [local-machine:]local-port:docker-port
Expand All @@ -345,12 +322,6 @@ services:
# ---- Format: ----
# HOST-DIRECTORY : DOCKER-DIRECTORY

# Mount logs
- ${DEVILBOX_PATH}/log/${MYSQL_SERVER}:/var/log/mysql:rw${MOUNT_OPTIONS}

# Mount devilbox default overwrites
- ${DEVILBOX_PATH}/.devilbox/etc/${MYSQL_SERVER}:/etc/mysql/conf.d:ro${MOUNT_OPTIONS}

# Mount devilbox user-defined cnf files in order
# to overwrite the MySQL server configuration
- ${DEVILBOX_PATH}/cfg/${MYSQL_SERVER}:/etc/mysql/docker-default.d:ro${MOUNT_OPTIONS}
Expand Down Expand Up @@ -421,13 +392,6 @@ services:
app_net:
ipv4_address: 172.16.238.14

volumes:
# ---- Format: ----
# HOST-DIRECTORY : DOCKER-DIRECTORY

# Mount logs
- ${DEVILBOX_PATH}/log/redis-${REDIS_SERVER}:/var/log/redis:rw${MOUNT_OPTIONS}

depends_on:
- bind
- php
Expand Down Expand Up @@ -526,9 +490,11 @@ volumes:
devilbox-mariadb-10.1:
devilbox-mariadb-10.2:
devilbox-mariadb-10.3:
devilbox-mariadb-10.4:
devilbox-percona-5.5:
devilbox-percona-5.6:
devilbox-percona-5.7:
devilbox-percona-8.0:

# ------------------------------------------------------------
# Postgres
Expand Down
Loading

0 comments on commit 73dcb0d

Please sign in to comment.