cloudstack icon indicating copy to clipboard operation
cloudstack copied to clipboard

Featured private templates

Open rajujith opened this issue 1 year ago • 3 comments

ISSUE TYPE
  • Improvement Request
COMPONENT NAME
Templates
CLOUDSTACK VERSION
4.18.1, ALL
SUMMARY

Currently, CloudStack expects the featured templates to be public as well if they are not public the featured templates are not listed in the featured templates tab in UI. Either in the template filter 'Featured' in the Images pane or in the instance deployment wizard. Why featured templates are tied to the property 'public' can this dependency be removed to allow private templates as well as Featured ones?

rajujith avatar Nov 08 '23 06:11 rajujith

@rajujith i marked this as bug as the api also does not show featured non-public templates when using templatefilter=featured, but does when using templatefilter=all.

I actually think we should be able to directly list on the basis of the flags, i.e. ispublic=false or isfeatured=true. Wgat do you think?

DaanHoogland avatar Nov 08 '23 12:11 DaanHoogland

@DaanHoogland I do agree to list directly on the basis of the flags ispublic=false or isfeatured=true.

rajujith avatar Nov 09 '23 09:11 rajujith

listTempalates API currently doesn't have ispublic or isfeatured parameters. Also, I'm not in favour of adding such new parameter as it would add confusion to the existing templatefilter parameter. I feel we should be able to fix the issue listing non-public featured template by removing this condition, https://github.com/apache/cloudstack/blob/4.19/server/src/main/java/com/cloud/api/query/QueryManagerImpl.java#L4505

shwstppr avatar May 09 '24 08:05 shwstppr

@rajujith @shwstppr @DaanHoogland @sureshanaparti according to the source code, it looks featured templates must be public image https://github.com/apache/cloudstack/blob/4.19.0.1/api/src/main/java/com/cloud/template/VirtualMachineTemplate.java#L71-L80

weizhouapache avatar Jun 10 '24 07:06 weizhouapache

The improvement required here is to implement featured private template types where a user wants to list private /non public templates as featured.

rajujith avatar Jun 11 '24 11:06 rajujith

The improvement required here is to implement featured private template types where a user wants to list private /non public templates as featured.

THANKS @rajujith can you suggest the name of the new template filters ?

weizhouapache avatar Jun 11 '24 11:06 weizhouapache

@weizhouapache how about 'spotlight'? or just 'featured private'?

rajujith avatar Jun 11 '24 11:06 rajujith

thanks @rajujith since this is an improvement, moving to 4.20.0.0

weizhouapache avatar Jun 11 '24 12:06 weizhouapache

@weizhouapache can we extend the featured feature (bad pun unintended) to include the callers featured private templates, or should it really be a separate feature?

DaanHoogland avatar Jun 11 '24 14:06 DaanHoogland

@weizhouapache can we extend the featured feature (bad pun unintended) to include the callers featured private templates, or should it really be a separate feature?

@DaanHoogland I would suggest to add new template filters for

  • private-featured
  • private-non-featured

at first we need to have a consensus on the names. for me, it looks like a small improvement with low priority

we should NOT touch the existing template filters

weizhouapache avatar Jun 11 '24 14:06 weizhouapache