Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add (and use) ghproxy deployment #128

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
1 change: 1 addition & 0 deletions prow/bump.sh
Expand Up @@ -125,4 +125,5 @@ fi
${SED} -i "s/\(k8s-prow\/.\+:\)v[a-f0-9-]\+/\1${new_version}/I" \
prow/config.yaml prow/cluster/cluster.yaml \
prow/cluster/grandmatriarch_*.yaml \
prow/cluster/ghproxy.yaml \
prow/prowjobs/GoogleCloudPlatform/oss-test-infra/gcp-oss-test-infra-config.yaml
8 changes: 8 additions & 0 deletions prow/cluster/cluster.yaml
Expand Up @@ -91,6 +91,8 @@ spec:
- --skip-report=true
- --config-path=/etc/config/config.yaml
- --job-config-path=/etc/job-config
- --github-endpoint=http://ghproxy
- --github-endpoint=https://api.github.com
volumeMounts:
- name: config
mountPath: /etc/config
Expand Down Expand Up @@ -192,6 +194,8 @@ spec:
- --oauth-url=/github-login
- --github-token-path=/etc/github/oauth
- --github-oauth-config-file=/etc/githuboauth/secret
- --github-endpoint=http://ghproxy
- --github-endpoint=https://api.github.com
ports:
- name: http
containerPort: 8080
Expand Down Expand Up @@ -449,6 +453,8 @@ spec:
- --config-path=/etc/config/config.yaml
- --job-config-path=/etc/job-config
- --dry-run=false
- --github-endpoint=http://ghproxy
- --github-endpoint=https://api.github.com
ports:
- name: http
containerPort: 8888
Expand Down Expand Up @@ -805,6 +811,8 @@ spec:
- --config-path=/etc/config/config.yaml
- --job-config-path=/etc/job-config
- --dry-run=false
- --github-endpoint=http://ghproxy
- --github-endpoint=https://api.github.com
ports:
- name: http
containerPort: 8888
Expand Down
76 changes: 76 additions & 0 deletions prow/cluster/ghproxy.yaml
@@ -0,0 +1,76 @@
# Copyright 2019 Google LLC
#
# 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
#
# https://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.

kind: PersistentVolumeClaim
apiVersion: v1
metadata:
namespace: default
labels:
app: ghproxy
name: ghproxy
spec:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 15Gi
---
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
namespace: default
name: ghproxy
labels:
app: ghproxy
spec:
replicas: 1
template:
metadata:
labels:
app: ghproxy
spec:
containers:
- name: ghproxy
image: gcr.io/k8s-prow/ghproxy:v20191008-bbd30bc09
args:
- --cache-dir=/cache
- --cache-sizeGB=99
- --serve-metrics=true
ports:
- containerPort: 8888
volumeMounts:
- name: cache
mountPath: /cache
volumes:
- name: cache
persistentVolumeClaim:
claimName: ghproxy
---
apiVersion: v1
kind: Service
metadata:
labels:
app: ghproxy
namespace: default
name: ghproxy
spec:
ports:
- name: main
port: 80
protocol: TCP
targetPort: 8888
- name: metrics
port: 9090
selector:
app: ghproxy