Class ContainerNamingUtil


  • public class ContainerNamingUtil
    extends Object
    Since:
    1.0.0
    Author:
    marcus
    • Method Detail

      • getContainersToStop

        public static Collection<Container> getContainersToStop​(ImageConfiguration image,
                                                                String defaultContainerNamePattern,
                                                                Date buildTimestamp,
                                                                Collection<Container> containers)
        Keep only the entry with the higest index if an indexed naming scheme for container has been chosen.
        Parameters:
        image - the image from which to the the container pattern
        buildTimestamp - the timestamp for the build
        containers - the list of existing containers
        Returns:
        a list with potentially lower indexed entries removed