archive: Create tarball with archive/tar package
Because on different systems tar utility may be of different implementations(BSD or GNU) it may cause incompatibilities in their usage. To mitigate this problem we use archive/tar package from the standard Go library to implement function for tarball creation. It uses PAX format, supports archiving of the symbolic links, empty folders, long filenames, recursive archiving.
This is a replacement of the existing WriteTarball
function that needs to be done under feature flag to minimize the risk.
Part of: #5409
Edited by Pavlo Strokov