mirror of
https://github.com/google/nomulus.git
synced 2025-08-06 01:35:17 +02:00
Update proxy deployment pipeline
The pipeline is broken into two. The first one is to be triggered when the public repo is tagged. It then tags the private repo, builds and upload the builder and base images, and push a new commit to the release (merged repo). This pipeline also does text manipulation on several files in the release repo to ensure that the images uploaded in this pipeline is always used to reproducibly build the release repo at the same commit. The second pipeline is then triggered by commit into the release repo, which builds, signs and uploads the proxy image. Also updated the dependency lock files to use the latest plugins dependencies, which are uploaded to the GCS repo. ------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=244666211
This commit is contained in:
parent
7a006df6c3
commit
926e68e806
8 changed files with 181 additions and 81 deletions
25
release/builder/Dockerfile
Normal file
25
release/builder/Dockerfile
Normal file
|
@ -0,0 +1,25 @@
|
|||
# Copyright 2019 The Nomulus Authors. All Rights Reserved.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
# This Dockerfile builds an image that can be used in Google Cloud Build.
|
||||
# We need the following programs to build the Nomulus app and the proxy:
|
||||
# 1. Java 8 for compilation.
|
||||
# 2. Node.js/NPM for JavaScript compilation.
|
||||
# 3. Google Cloud SDK for generating the WARs.
|
||||
# 4. Git to manipulate the private and the merged repos.
|
||||
# 5. Docker to build and push images.
|
||||
FROM marketplace.gcr.io/google/ubuntu1804
|
||||
ENV DEBIAN_FRONTEND=noninteractive LANG=en_US.UTF-8
|
||||
ADD ./build.sh .
|
||||
RUN ["bash", "./build.sh"]
|
43
release/builder/build.sh
Executable file
43
release/builder/build.sh
Executable file
|
@ -0,0 +1,43 @@
|
|||
#!/bin/bash
|
||||
# Copyright 2019 The Nomulus Authors. All Rights Reserved.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
set -e
|
||||
apt-get install locales -y
|
||||
locale-gen en_US.UTF-8
|
||||
apt-get install apt-utils -y
|
||||
apt-get update -y
|
||||
apt-get upgrade -y
|
||||
# Install Java
|
||||
apt-get install openjdk-8-jdk-headless -y
|
||||
# Install npm
|
||||
apt-get install npm -y
|
||||
# Install gcloud
|
||||
# Cribbed from https://cloud.google.com/sdk/docs/quickstart-debian-ubuntu
|
||||
apt-get install lsb-release -y
|
||||
export CLOUD_SDK_REPO="cloud-sdk-$(lsb_release -c -s)"
|
||||
echo "deb http://packages.cloud.google.com/apt $CLOUD_SDK_REPO main" \
|
||||
| tee -a /etc/apt/sources.list.d/google-cloud-sdk.list
|
||||
curl https://packages.cloud.google.com/apt/doc/apt-key.gpg \
|
||||
| apt-key add -
|
||||
apt-get update -y
|
||||
apt-get install google-cloud-sdk-app-engine-java -y
|
||||
# Install git
|
||||
apt-get install git -y
|
||||
# Install docker
|
||||
apt-get install docker.io -y
|
||||
apt-get remove apt-utils locales lsb-release -y
|
||||
apt-get autoclean -y
|
||||
apt-get autoremove -y
|
||||
rm -rf /var/lib/apt/lists/*
|
Loading…
Add table
Add a link
Reference in a new issue