Commit 7d09e1d7 authored by Amir MOHAMMADI's avatar Amir MOHAMMADI

Give public packages more priority over private packages

parent 2b1daf98
Pipeline #42945 passed with stage
in 16 minutes and 58 seconds
......@@ -289,8 +289,8 @@ def get_channels(public, stable, server, intranet, group):
* not public and stable: returns both public and private stable channels
* not public and not stable: returns all channels
Beta channels have priority over stable channels, if returned. Private
channels have priority over public channles, if turned.
Beta channels have priority over stable channels, if returned. Public
channels have priority over private channles, if turned.
Args:
......@@ -319,18 +319,19 @@ def get_channels(public, stable, server, intranet, group):
channels = []
# do not use '/public' urls for public channels
prefix = "/software/" + group
if not stable:
channels += [server + prefix + "/conda/label/beta"] # allowed betas
channels += [server + prefix + "/conda"]
if not public:
prefix = "/private"
if not stable: # allowed private channels
channels += [server + prefix + "/conda/label/beta"] # allowed betas
channels += [server + prefix + "/conda"]
# do not use '/public' versions here
prefix = "/software/" + group
if not stable:
channels += [server + prefix + "/conda/label/beta"] # allowed betas
channels += [server + prefix + "/conda"]
return channels
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment