Skip to content
This repository has been archived by the owner on Nov 30, 2021. It is now read-only.

Commit

Permalink
Revert "fix(controller): more image parsing fixes"
Browse files Browse the repository at this point in the history
This reverts commit 7756f8a.
  • Loading branch information
Matthew Fisher committed Jul 21, 2014
1 parent 7d06fbd commit bf6c249
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions controller/registry/private.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,16 +23,10 @@ def publish_release(source, config, target):
contains the new configuration as ENV entries.
"""
try:
if source.count('/') == 2:
# image comes from private registry
if source.count(':') == 2:
src_image = source.rsplit(':', 1)[0].split('/', 1)[1]
src_tag = source.split(':')[2]
elif source.count('/') == 1 and source.count(':') == 1:
# image comes from dockerhub, includes tag
src_image = source.split(':')[0]
src_tag = source.split(':')[1]
else:
# image comes from dockerhub, no tag
src_image = source
src_tag = 'latest'
target_image = target.rsplit(':', 1)[0]
Expand Down

0 comments on commit bf6c249

Please sign in to comment.