Skip to content
This repository was archived by the owner on Sep 12, 2018. It is now read-only.

Commit 59ba1ca

Browse files
committed
Test properly if registry is a mirror
1 parent d695902 commit 59ba1ca

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

docker_registry/app.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414

1515
from . import toolkit
1616
from .lib import config
17+
from .lib import mirroring
1718
from .server import __version__
1819

1920
app = flask.Flask('docker-registry')
@@ -26,7 +27,7 @@
2627
@app.route('/v1/_ping')
2728
def ping():
2829
headers = {'X-Docker-Registry-Standalone': cfg.standalone is True}
29-
if cfg.mirroring:
30+
if mirroring.is_mirror():
3031
headers['X-Docker-Registry-Standalone'] = 'mirror'
3132
return toolkit.response(headers=headers)
3233

0 commit comments

Comments
 (0)