mirror of
https://github.com/goharbor/harbor.git
synced 2024-11-22 18:25:56 +01:00
Merge branch 'master' into job_service
This commit is contained in:
commit
d5a696d821
17
make/photon/redis/Dockerfile
Normal file
17
make/photon/redis/Dockerfile
Normal file
@ -0,0 +1,17 @@
|
||||
FROM vmware/photon:1.0
|
||||
|
||||
RUN tdnf distro-sync -y \
|
||||
&& tdnf install -y redis sudo \
|
||||
&& mkdir /data \
|
||||
&& chown redis:redis /data
|
||||
|
||||
VOLUME /data
|
||||
WORKDIR /data
|
||||
COPY docker-entrypoint.sh /usr/bin/
|
||||
COPY redis.conf /etc/redis.conf
|
||||
RUN chmod +x /usr/bin/docker-entrypoint.sh \
|
||||
&& chown redis:redis /etc/redis.conf
|
||||
ENTRYPOINT ["docker-entrypoint.sh"]
|
||||
|
||||
EXPOSE 6379
|
||||
CMD ["redis-server", "/etc/redis.conf"]
|
13
make/photon/redis/docker-entrypoint.sh
Normal file
13
make/photon/redis/docker-entrypoint.sh
Normal file
@ -0,0 +1,13 @@
|
||||
#!/bin/sh
|
||||
set -e
|
||||
|
||||
if [ "${1#-}" != "$1" ] || [ "${1%.conf}" != "$1" ]; then
|
||||
set -- redis-server "$@"
|
||||
fi
|
||||
|
||||
if [ "$1" = 'redis-server' -a "$(id -u)" = '0' ]; then
|
||||
chown -R redis .
|
||||
exec sudo -u redis "$@"
|
||||
fi
|
||||
|
||||
exec "$@"
|
1293
make/photon/redis/redis.conf
Normal file
1293
make/photon/redis/redis.conf
Normal file
File diff suppressed because it is too large
Load Diff
Loading…
Reference in New Issue
Block a user