-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathregistry.service
23 lines (21 loc) · 903 Bytes
/
registry.service
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
[Unit]
Description=docker private registry service
After=docker.service
[Service]
ExecStartPre=-/usr/bin/docker kill registry
ExecStartPre=-/usr/bin/docker rm registry
ExecStart=/usr/bin/docker run --name registry -v /mirror/registry:/tmp/ -p 5000:5000 \
-e "http_proxy=http://10.175.250.81:8080" \
-e "https_proxy=http://10.175.250.81:8080" \
-e "STANDALONE=true" \
-e "MIRROR_SOURCE=https://registry-1.docker.io" \
-e "MIRROR_SOURCE_INDEX=https://index.docker.io" \
-e "SETTINGS_FLAVOR=local" \
-e SEARCH_BACKEND=sqlalchemy \
--dns 146.11.115.200 \
registry
ExecStop=-/usr/bin/docker stop registry
Restart=always
RestartSec=10s
[Install]
WantedBy=multi-user.target