2021-04-09 15:28:18 -04:00
|
|
|
/*
|
|
|
|
* SPDX-License-Identifier: Apache-2.0
|
|
|
|
*
|
|
|
|
* The OpenSearch Contributors require contributions made to
|
|
|
|
* this file be licensed under the Apache-2.0 license or a
|
|
|
|
* compatible open source license.
|
|
|
|
*
|
|
|
|
* Modifications Copyright OpenSearch Contributors. See
|
|
|
|
* GitHub history for details.
|
|
|
|
*/
|
|
|
|
|
2021-03-16 04:53:48 -04:00
|
|
|
import org.opensearch.gradle.DockerBase
|
2020-08-18 04:27:23 -04:00
|
|
|
|
2019-05-06 21:04:13 -04:00
|
|
|
apply plugin: 'base'
|
|
|
|
|
2021-04-20 12:27:40 -04:00
|
|
|
tasks.register("buildDockerBuildContext", Tar) {
|
2020-06-23 03:11:46 -04:00
|
|
|
archiveExtension = 'tar.gz'
|
2019-11-14 06:01:23 -05:00
|
|
|
compression = Compression.GZIP
|
|
|
|
archiveClassifier = "docker-build-context"
|
2021-04-20 12:27:40 -04:00
|
|
|
archiveBaseName = "opensearch"
|
2020-05-12 06:10:05 -04:00
|
|
|
// Non-local builds don't need to specify an architecture.
|
2021-02-22 18:08:15 -05:00
|
|
|
with dockerBuildContext(null, DockerBase.CENTOS, false)
|
2019-05-06 21:04:13 -04:00
|
|
|
}
|
|
|
|
|
2021-04-20 12:27:40 -04:00
|
|
|
tasks.named("assemble").configure { dependsOn "buildDockerBuildContext" }
|