+ val tempMainPath: File = createTempDir("k8s-profile-", "")
+ val tempProfilePath: File = createTempDir("${k8sRbProfileName}-", "", tempMainPath)
+ log.info("Decompressing profile to ${tempProfilePath.toString()}")
+
+ val decompressedProfile: File = BluePrintArchiveUtils.deCompress(profileFilePath.toFile(),
+ "${tempProfilePath.toString()}", ArchiveType.TarGz)
+
+ log.info("${profileFilePath.toString()} decompression completed")
+
+ //Here we can add extra files inside the archive
+ profileFilePath = Paths.get(tempMainPath.toString().plus(File.separator).plus("${k8sRbProfileName}.tar.gz"))
+
+ if (!BluePrintArchiveUtils.compress(decompressedProfile, profileFilePath.toFile(),
+ ArchiveType.TarGz)) {
+ throw BluePrintProcessorException("Profile compression has failed")
+ }
+
+ log.info("${profileFilePath.toString()} compression completed")
+