mirror of
https://github.com/google/nomulus.git
synced 2025-04-30 03:57:51 +02:00
Fix builds after refactor (#99)
Fixed both GAE and proxy builds after #90 refactored the code structure. Also removed now unnecessary chmod and chown from GCB scripts.
This commit is contained in:
parent
9eb54f94f8
commit
ad20178f18
4 changed files with 4 additions and 13 deletions
|
@ -21,14 +21,14 @@ apply plugin: 'war'
|
||||||
// plugin will recognize this as an app-engine standard app (and also
|
// plugin will recognize this as an app-engine standard app (and also
|
||||||
// obtains the appengine-web.xml from the correct location)
|
// obtains the appengine-web.xml from the correct location)
|
||||||
project.convention.plugins['war'].webAppDirName =
|
project.convention.plugins['war'].webAppDirName =
|
||||||
"../../java/google/registry/env/${environment}/${project.name}"
|
"../../core/src/main/java/google/registry/env/${environment}/${project.name}"
|
||||||
|
|
||||||
apply plugin: 'com.google.cloud.tools.appengine'
|
apply plugin: 'com.google.cloud.tools.appengine'
|
||||||
|
|
||||||
// Get the web.xml file for the service.
|
// Get the web.xml file for the service.
|
||||||
war {
|
war {
|
||||||
webInf {
|
webInf {
|
||||||
from "../../java/google/registry/env/common/${project.name}/WEB-INF"
|
from "../../core/src/main/java/google/registry/env/common/${project.name}/WEB-INF"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -16,11 +16,6 @@
|
||||||
# To trigger a build automatically, follow the instructions below and add a trigger:
|
# To trigger a build automatically, follow the instructions below and add a trigger:
|
||||||
# https://cloud.google.com/cloud-build/docs/running-builds/automate-builds
|
# https://cloud.google.com/cloud-build/docs/running-builds/automate-builds
|
||||||
steps:
|
steps:
|
||||||
# Set permissions correctly. Not sure why it is necessary, but it is.
|
|
||||||
- name: 'gcr.io/${PROJECT_ID}/builder:latest'
|
|
||||||
args: ['chown', '-R', 'root:root', '.']
|
|
||||||
- name: 'gcr.io/${PROJECT_ID}/builder:latest'
|
|
||||||
args: ['chmod', '-R', '777', '.']
|
|
||||||
# Create a directory to store the artifacts
|
# Create a directory to store the artifacts
|
||||||
- name: 'gcr.io/${PROJECT_ID}/builder:latest'
|
- name: 'gcr.io/${PROJECT_ID}/builder:latest'
|
||||||
args: ['mkdir', 'nomulus']
|
args: ['mkdir', 'nomulus']
|
||||||
|
|
|
@ -14,10 +14,6 @@
|
||||||
# https://cloud.google.com/cloud-build/docs/running-builds/automate-builds
|
# https://cloud.google.com/cloud-build/docs/running-builds/automate-builds
|
||||||
steps:
|
steps:
|
||||||
# Set permissions correctly. Not sure why it is necessary, but it is.
|
# Set permissions correctly. Not sure why it is necessary, but it is.
|
||||||
- name: 'gcr.io/${PROJECT_ID}/builder:latest'
|
|
||||||
args: ['chown', '-R', 'root:root', '.']
|
|
||||||
- name: 'gcr.io/${PROJECT_ID}/builder:latest'
|
|
||||||
args: ['chmod', '-R', '777', '.']
|
|
||||||
# Build the deploy jar.
|
# Build the deploy jar.
|
||||||
- name: 'gcr.io/${PROJECT_ID}/builder:latest'
|
- name: 'gcr.io/${PROJECT_ID}/builder:latest'
|
||||||
args:
|
args:
|
||||||
|
@ -59,7 +55,7 @@ artifacts:
|
||||||
location: 'gs://${PROJECT_ID}-deploy/${TAG_NAME}'
|
location: 'gs://${PROJECT_ID}-deploy/${TAG_NAME}'
|
||||||
# This cannot be regexs because of how Spinnaker constructs artifact paths.
|
# This cannot be regexs because of how Spinnaker constructs artifact paths.
|
||||||
paths:
|
paths:
|
||||||
- 'java/google/registry/proxy/kubernetes/proxy-*.yaml'
|
- 'proxy/src/main/java/google/registry/proxy/kubernetes/proxy-*.yaml'
|
||||||
- 'release/cloudbuild-tag.yaml'
|
- 'release/cloudbuild-tag.yaml'
|
||||||
timeout: 3600s
|
timeout: 3600s
|
||||||
options:
|
options:
|
||||||
|
|
|
@ -67,7 +67,7 @@ steps:
|
||||||
sed -i s%distroless/java%${PROJECT_ID}/base@$base_digest% proxy/Dockerfile
|
sed -i s%distroless/java%${PROJECT_ID}/base@$base_digest% proxy/Dockerfile
|
||||||
sed -i s/builder:latest/builder@$builder_digest/g release/cloudbuild-proxy.yaml
|
sed -i s/builder:latest/builder@$builder_digest/g release/cloudbuild-proxy.yaml
|
||||||
sed -i s/builder:latest/builder@$builder_digest/g release/cloudbuild-nomulus.yaml
|
sed -i s/builder:latest/builder@$builder_digest/g release/cloudbuild-nomulus.yaml
|
||||||
sed -i s/GCP_PROJECT/${PROJECT_ID}/ java/google/registry/proxy/kubernetes/proxy-*.yaml
|
sed -i s/GCP_PROJECT/${PROJECT_ID}/ proxy/src/main/java/google/registry/proxy/kubernetes/proxy-*.yaml
|
||||||
sed -i s/'$${TAG_NAME}'/${TAG_NAME}/g release/cloudbuild-sync.yaml
|
sed -i s/'$${TAG_NAME}'/${TAG_NAME}/g release/cloudbuild-sync.yaml
|
||||||
# Upload the gradle binary to GCS if it does not exist and point URL in gradle wrapper to it.
|
# Upload the gradle binary to GCS if it does not exist and point URL in gradle wrapper to it.
|
||||||
- name: 'gcr.io/cloud-builders/gsutil'
|
- name: 'gcr.io/cloud-builders/gsutil'
|
||||||
|
|
Loading…
Add table
Reference in a new issue