Skip to content

Commit

Permalink
Fixes tinkerbell#38: Using persistent volume to hold registry data
Browse files Browse the repository at this point in the history
In this fix we are using "/var/tinkerbell/registry" directory locally to persist the data of registry
  • Loading branch information
parauliya committed Apr 24, 2020
1 parent ce990ee commit 0585550
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
1 change: 1 addition & 0 deletions deploy/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@ services:
REGISTRY_AUTH_HTPASSWD_PATH: /auth/htpasswd
volumes:
- ./certs:/certs
- /var/tinkerbell/registry:/var/lib/registry
depends_on:
fluentbit:
condition: service_started
Expand Down
4 changes: 4 additions & 0 deletions setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -344,6 +344,10 @@ start_registry() {
}

setup_docker_registry() {
registry_images=/var/tinkerbell/registry
if [ ! -d "$registry_images" ]; then
mkdir -p "$registry_images"
fi
if [ -f ~/.docker/config.json ]; then
if grep -q "$TINKERBELL_HOST_IP" ~/.docker/config.json; then
echo "$INFO found existing docker auth token for registry $TINKERBELL_HOST_IP, using existing registry"
Expand Down

0 comments on commit 0585550

Please sign in to comment.