My common goal is to synchronize the file with S3, and then tightly link it to avoid "many copies" and to save space when creating docker containers. That's what i still have
withAWS(region: 'us-east-1') { s3Download( bucket: 'artifacts.mydomain.tld', file: "${env.ORACLE_RPM}", path: "${env.HOME}/${env.ORACLE_RPM}", ) script { linkBlocking("etc/docker/${env.PROJECT}/${env.ORACLE_RPM}", "${env.HOME}/${env.ORACLE_RPM}") } }
s3Download works, although I'm not sure that it will update the file if a newer version is available.
However, when I tried to use the FileSystem class, I cannot actually determine the correct calling convention, the constructor is at least underestimated.
source share