- Save the
docker-compose.yml
andconfig.yml
in the same directory on one of your volumes on the NAS. - SSH in and use
docker-compose up -d
- Test the mirror with
curl --head http://NAS-IP:55000
- Start up docker daemons with the following option or put this in the daemon config file or copy into Docker for Mac/Windows settings.
--registry-mirror=http://NAS-IP:55000
- Pull an image and then check that it is cached in your mirror with
curl http://NAS-IP:55000/v2/_catalog
- or check that a large image isn't slow after the first pull :)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: '2' | |
networks: | |
monitoring: | |
services: | |
traefik: | |
image: traefik:v1.5.0-rc5 | |
restart: always |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@echo off | |
FOR /f "tokens=*" %%i IN ('docker ps -aq') DO docker rm %%i | |
FOR /f "tokens=*" %%i IN ('docker images --format "{{.ID}}"') DO docker rmi %%i |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package sample; | |
import java.io.ByteArrayOutputStream; | |
import java.io.IOException; | |
import java.security.MessageDigest; | |
import java.security.SecureRandom; | |
import java.text.DateFormat; | |
import java.text.SimpleDateFormat; |