Factor out 'remoteDocRoot' property
Remote path '/var/www/domains/springframework.org/static/htdocs' is no longer hard-coded in docs/build.gradle, because (a) it will be needed in two separate locations as schema uploads are developed, and (b) this value should be easily editable during local testing.
This commit is contained in:
@@ -187,12 +187,10 @@ dependencies {
|
||||
scpAntTask("org.apache.ant:ant-jsch:1.8.1")
|
||||
}
|
||||
|
||||
checkForProps(taskPath: project.path + ':uploadArchives', requiredProps: ['sshHost', 'sshUsername', 'sshPrivateKey'])
|
||||
checkForProps(taskPath: project.path + ':uploadArchives', requiredProps: ['sshHost', 'sshUsername', 'sshPrivateKey', 'remoteDocRoot'])
|
||||
|
||||
uploadArchives {
|
||||
def sshHost = project.properties.sshHost
|
||||
def sshUsername = project.properties.sshUsername
|
||||
def remoteSiteDir = '/var/www/domains/springframework.org/static/htdocs/' + rootProject.name
|
||||
def remoteSiteDir = remoteDocRoot + rootProject.name
|
||||
def docUrl = "http://${sshHost}/${rootProject.name}/docs/${version}"
|
||||
def remoteDocsDir = "${remoteSiteDir}/docs/"
|
||||
def fqRemoteDir = "${sshUsername}@${sshHost}:${remoteDocsDir}"
|
||||
|
||||
Reference in New Issue
Block a user