Skip to content
This repository was archived by the owner on Jul 2, 2024. It is now read-only.

Commit ee0a109

Browse files
committed
Adds CentOS-7 version.
1 parent ce8086e commit ee0a109

File tree

9 files changed

+31
-22
lines changed

9 files changed

+31
-22
lines changed

CHANGELOG.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
# Change Log
22

3-
## centos-6
3+
## centos-7
44

5-
Summary of release changes for Version 1.
5+
Summary of release changes for Version 2.
66

7-
CentOS-6 6.10 x86_64 - Redis 3.2.
7+
CentOS-7 7.5.1804 x86_64 - Redis 4.0.
88

9-
### 1.0.0 - Unreleased
9+
### 2.0.0 - Unreleased
1010

1111
- Initial release.

Dockerfile

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
# =============================================================================
22
# jdeathe/centos-ssh-redis
33
#
4-
# CentOS-6, Redis 3.2.
4+
# CentOS-6, Redis 4.0.
55
# =============================================================================
6-
FROM jdeathe/centos-ssh:1.9.0
6+
FROM jdeathe/centos-ssh:2.4.0
77

88
RUN yum -y install \
99
--setopt=tsflags=nodocs \
1010
--disableplugin=fastestmirror \
11-
redis32u-3.2.12-1.ius.centos6 \
11+
redis40u-4.0.11-1.ius.centos7 \
1212
&& yum versionlock add \
13-
redis32u* \
13+
redis40u* \
1414
&& yum clean all
1515

1616
# -----------------------------------------------------------------------------
@@ -58,12 +58,14 @@ ENV REDIS_AUTOSTART_REDIS_BOOTSTRAP="true" \
5858
REDIS_MAXMEMORY_POLICY="allkeys-lru" \
5959
REDIS_MAXMEMORY_SAMPLES="5" \
6060
REDIS_OPTIONS="" \
61-
REDIS_TCP_BACKLOG="1024"
61+
REDIS_TCP_BACKLOG="1024" \
62+
SSH_AUTOSTART_SSHD=false \
63+
SSH_AUTOSTART_SSHD_BOOTSTRAP=false
6264

6365
# -----------------------------------------------------------------------------
6466
# Set image metadata
6567
# -----------------------------------------------------------------------------
66-
ARG RELEASE_VERSION="1.0.0"
68+
ARG RELEASE_VERSION="2.0.0"
6769
LABEL \
6870
maintainer="James Deathe <james.deathe@gmail.com>" \
6971
install="docker run \
@@ -90,7 +92,7 @@ jdeathe/centos-ssh-redis:${RELEASE_VERSION} \
9092
org.deathe.license="MIT" \
9193
org.deathe.vendor="jdeathe" \
9294
org.deathe.url="https://github.com/jdeathe/centos-ssh-redis" \
93-
org.deathe.description="CentOS-6 6.10 x86_64 - Redis 3.2."
95+
org.deathe.description="CentOS-7 7.5.1804 x86_64 - Redis 4.0."
9496

9597
HEALTHCHECK \
9698
--interval=0.5s \

LICENSE

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
Copyright (c) 2016 James Deathe (jdeathe)
2-
https://github.com/jdeathe/centos-ssh-memcached
1+
Copyright (c) 2018 James Deathe (jdeathe)
2+
https://github.com/jdeathe/centos-ssh-redis
33

44
Permission is hereby granted, free of charge, to any person obtaining
55
a copy of this software and associated documentation files (the

README-short.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
CentOS-6 6.10 x86_64 - Redis.
1+
CentOS-7 7.5.1804 x86_64 - Redis.

README.md

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,8 @@ Run up a container named `redis.pool-1.1.1` from the docker image `jdeathe/cento
3939
$ docker run -d \
4040
--name redis.pool-1.1.1 \
4141
-p 6379:6379/tcp \
42-
jdeathe/centos-ssh-redis:1.0.0
42+
--sysctl "net.core.somaxconn=1024" \
43+
jdeathe/centos-ssh-redis:2.0.0
4344
```
4445

4546
Now you can verify it is initialised and running successfully by inspecting the container's logs.
@@ -70,7 +71,10 @@ $ docker run \
7071
--env "REDIS_MAXMEMORY_SAMPLES=10" \
7172
--env "REDIS_OPTIONS=--loglevel verbose" \
7273
--env "REDIS_TCP_BACKLOG=2048" \
73-
jdeathe/centos-ssh-redis:1.0.0 \
74+
--sysctl "net.core.somaxconn=2048" \
75+
--sysctl "net.ipv4.ip_local_port_range=1024 65535" \
76+
--sysctl "net.ipv4.route.flush=1" \
77+
jdeathe/centos-ssh-redis:2.0.0
7478
```
7579

7680
#### Environment Variables

environment.mk

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ DOCKER_IMAGE_NAME := centos-ssh-redis
66
SHPEC_ROOT := test/shpec
77

88
# Tag validation patterns
9-
DOCKER_IMAGE_TAG_PATTERN := ^(latest|centos-6|((1|centos-6-1)\.[0-9]+\.[0-9]+))$
10-
DOCKER_IMAGE_RELEASE_TAG_PATTERN := ^(1|centos-6-1)\.[0-9]+\.[0-9]+$
9+
DOCKER_IMAGE_TAG_PATTERN := ^(latest|centos-[6-7]|((1|2|centos-(6-1|7-2))\.[0-9]+\.[0-9]+))$
10+
DOCKER_IMAGE_RELEASE_TAG_PATTERN := ^(1|2|centos-(6-1|7-2))\.[0-9]+\.[0-9]+$
1111

1212
# -----------------------------------------------------------------------------
1313
# Variables

src/etc/systemd/system/centos-ssh-redis@.service

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ Environment="DOCKER_USER=jdeathe"
5252
Environment="DOCKER_CONTAINER_OPTS="
5353
Environment="DOCKER_IMAGE_PACKAGE_PATH=/var/opt/scmi/packages"
5454
Environment="DOCKER_IMAGE_NAME=centos-ssh-redis"
55-
Environment="DOCKER_IMAGE_TAG=1.0.0"
55+
Environment="DOCKER_IMAGE_TAG=2.0.0"
5656
Environment="DOCKER_PORT_MAP_TCP_6379=6379"
5757
Environment="DOCKER_PORT_MAP_UDP_6379=NULL"
5858
Environment="REDIS_AUTOSTART_REDIS_BOOTSTRAP=true"

src/opt/scmi/environment.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@ readonly DOCKER_USER=jdeathe
55
readonly DOCKER_IMAGE_NAME=centos-ssh-redis
66

77
# Tag validation patterns
8-
readonly DOCKER_IMAGE_TAG_PATTERN='^(latest|centos-6|((1|centos-6-1)\.[0-9]+\.[0-9]+))$'
9-
readonly DOCKER_IMAGE_RELEASE_TAG_PATTERN='^(1|centos-6-1)\.[0-9]+\.[0-9]+$'
8+
readonly DOCKER_IMAGE_TAG_PATTERN='^(latest|centos-[6-7]|((1|2|centos-(6-1|7-2))\.[0-9]+\.[0-9]+))$'
9+
readonly DOCKER_IMAGE_RELEASE_TAG_PATTERN='^(1|2|centos-(6-1|7-2))\.[0-9]+\.[0-9]+$'
1010

1111
# -----------------------------------------------------------------------------
1212
# Variables
@@ -56,6 +56,6 @@ REDIS_AUTOSTART_REDIS_BOOTSTRAP="${REDIS_AUTOSTART_REDIS_BOOTSTRAP:-true}"
5656
REDIS_AUTOSTART_REDIS_WRAPPER="${REDIS_AUTOSTART_REDIS_WRAPPER:-true}"
5757
REDIS_MAXMEMORY="${REDIS_MAXMEMORY:-64mb}"
5858
REDIS_MAXMEMORY_POLICY="${REDIS_MAXMEMORY_POLICY:-allkeys-lru}"
59-
REDIS_MAXMEMORY_SAMPLES="${REDIS_MAXMEMORY_SAMPLES:-10}"
59+
REDIS_MAXMEMORY_SAMPLES="${REDIS_MAXMEMORY_SAMPLES:-5}"
6060
REDIS_OPTIONS="${REDIS_OPTIONS:-}"
6161
REDIS_TCP_BACKLOG="${REDIS_TCP_BACKLOG:-1024}"

src/usr/sbin/redis-server-bootstrap

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,9 @@ set_wrapper_execute_user \
5353
"${WRAPPER}" \
5454
"${USER}"
5555

56+
# Force a longer execution time to allow output in logs
57+
sleep 0.05
58+
5659
TIMER_TOTAL="$(
5760
echo - | awk "\
5861
{ T1=\"${TIMER_START}\" } \

0 commit comments

Comments
 (0)