Skip to content

Commit 169566a

Browse files
authored
ROX-19827: migrate infra-server/certifier images to quay.io (#1201)
1 parent 8bc726f commit 169566a

File tree

16 files changed

+90
-111
lines changed

16 files changed

+90
-111
lines changed

.github/workflows/PR.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,9 @@ jobs:
2020
lint:
2121
uses: ./.github/workflows/lint.yaml
2222

23+
unit-tests:
24+
uses: ./.github/workflows/unit-tests.yaml
25+
2326
build-and-push:
2427
uses: ./.github/workflows/build-and-push.yaml
2528
secrets: inherit

.github/workflows/ReleaseTagged.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,9 @@ jobs:
1616
lint:
1717
uses: ./.github/workflows/lint.yaml
1818

19+
unit-tests:
20+
uses: ./.github/workflows/unit-tests.yaml
21+
1922
build-and-push:
2023
uses: ./.github/workflows/build-and-push.yaml
2124
secrets: inherit

.github/workflows/build-and-push.yaml

Lines changed: 28 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ defaults:
88
working-directory: go/src/github.com/stackrox/infra
99

1010
jobs:
11-
build-and-push:
11+
build-and-push-server:
1212
runs-on: ubuntu-latest
1313
container:
1414
image: quay.io/stackrox-io/apollo-ci:stackrox-test-0.3.61
@@ -40,26 +40,45 @@ jobs:
4040
make proto-generated-srcs
4141
git diff --exit-code HEAD
4242
43-
- name: Go Unit Test
44-
run: |
45-
make unit-test
46-
4743
- name: Build Infra Server
4844
run: |
4945
make image
5046
47+
- name: Login for image push
48+
uses: docker/login-action@v3
49+
with:
50+
registry: quay.io
51+
username: ${{ secrets.QUAY_RHACS_ENG_INFRA_RW_USERNAME }}
52+
password: ${{ secrets.QUAY_RHACS_ENG_INFRA_RW_PASSWORD }}
53+
54+
- name: Push
55+
run: |
56+
make push
57+
58+
build-and-push-certifier:
59+
runs-on: ubuntu-latest
60+
container:
61+
image: quay.io/stackrox-io/apollo-ci:stackrox-test-0.3.61
62+
63+
steps:
64+
- name: Checkout
65+
uses: actions/checkout@v4
66+
with:
67+
fetch-depth: 0
68+
ref: ${{ github.event.pull_request.head.sha }}
69+
path: go/src/github.com/stackrox/infra
70+
5171
- name: Build Certifier
5272
run: |
5373
cd certifier && make image
5474
5575
- name: Login for image push
5676
uses: docker/login-action@v3
5777
with:
58-
registry: us.gcr.io
59-
username: _json_key
60-
password: ${{ secrets.INFRA_IMAGE_PUSH }}
78+
registry: quay.io
79+
username: ${{ secrets.QUAY_RHACS_ENG_INFRA_RW_USERNAME }}
80+
password: ${{ secrets.QUAY_RHACS_ENG_INFRA_RW_PASSWORD }}
6181

6282
- name: Push
6383
run: |
64-
make push
6584
cd certifier && make push

.github/workflows/unit-tests.yaml

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
name: Unit Tests
2+
3+
on:
4+
workflow_call:
5+
6+
defaults:
7+
run:
8+
working-directory: go/src/github.com/stackrox/infra
9+
10+
jobs:
11+
unit-test:
12+
runs-on: ubuntu-latest
13+
container:
14+
image: quay.io/stackrox-io/apollo-ci:stackrox-test-0.3.61
15+
16+
steps:
17+
- name: Checkout
18+
uses: actions/checkout@v4
19+
with:
20+
fetch-depth: 0
21+
ref: ${{ github.event.pull_request.head.sha }}
22+
path: go/src/github.com/stackrox/infra
23+
24+
- name: Setup env
25+
run: |
26+
GOPATH="$GITHUB_WORKSPACE/go"
27+
echo GOPATH="${GOPATH}" >> "$GITHUB_ENV"
28+
PATH="${PATH}:${GOPATH}/bin"
29+
echo PATH="${PATH}" >> "$GITHUB_ENV"
30+
31+
- name: Go Unit Test
32+
run: |
33+
make unit-test

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ endif
2525
tag:
2626
@echo $(VERSION)
2727

28-
IMAGE=us.gcr.io/stackrox-infra/infra-server:$(VERSION)
28+
IMAGE=quay.io/rhacs-eng/infra-server:$(VERSION)
2929
.PHONY: image-name
3030
image-name:
3131
@echo $(IMAGE)

certifier/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ endif
1515
tag:
1616
@echo $(VERSION)
1717

18-
IMAGE=us.gcr.io/stackrox-infra/certifier:$(VERSION)
18+
IMAGE=quay.io/rhacs-eng/infra-certifier:$(VERSION)
1919
.PHONY: image-name
2020
image-name:
2121
@echo $(IMAGE)

chart/infra-server/static/workflow-aks.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ spec:
4848
archive:
4949
tar: {}
5050
container:
51-
image: gcr.io/stackrox-infra/automation-flavors/aks:0.2.16
51+
image: quay.io/stackrox-io/ci:automation-flavors-aks-0.10.1
5252
imagePullPolicy: Always
5353
command:
5454
- entrypoint
@@ -96,7 +96,7 @@ spec:
9696

9797
- name: destroy
9898
container:
99-
image: gcr.io/stackrox-infra/automation-flavors/aks:0.2.16
99+
image: quay.io/stackrox-io/ci:automation-flavors-aks-0.10.1
100100
imagePullPolicy: Always
101101
command:
102102
- entrypoint

chart/infra-server/static/workflow-example.yaml

Lines changed: 0 additions & 72 deletions
This file was deleted.

chart/infra-server/templates/demo-certifier.yaml

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ data:
1313
{{ required ".Values.demo__demo_cert_bot_json is undefined" .Values.demo__demo_cert_bot_json }}
1414
1515
---
16-
1716
apiVersion: batch/v1
1817
kind: CronJob
1918
metadata:
@@ -27,7 +26,7 @@ spec:
2726
spec:
2827
containers:
2928
- name: certifier
30-
image: us.gcr.io/stackrox-infra/certifier:0.0.0-5
29+
image: quay.io/rhacs-eng/infra-certifier:{{ required "A valid .Values.tag entry is required!" .Values.tag }}
3130
imagePullPolicy: IfNotPresent
3231
args:
3332
- --common-name=*.demo.stackrox.com
@@ -46,9 +45,10 @@ spec:
4645
- name: configuration
4746
secret:
4847
secretName: demo-certifier-credentials
48+
imagePullSecrets:
49+
- name: infra-image-registry-pull-secret
4950

5051
---
51-
5252
apiVersion: batch/v1
5353
kind: CronJob
5454
metadata:
@@ -62,7 +62,7 @@ spec:
6262
spec:
6363
containers:
6464
- name: certifier
65-
image: us.gcr.io/stackrox-infra/certifier:0.8.8
65+
image: quay.io/rhacs-eng/infra-certifier:{{ required "A valid .Values.tag entry is required!" .Values.tag }}
6666
imagePullPolicy: IfNotPresent
6767
args:
6868
- --common-name=*.demos.rox.systems
@@ -82,5 +82,6 @@ spec:
8282
- name: configuration
8383
secret:
8484
secretName: demo-certifier-credentials
85-
85+
imagePullSecrets:
86+
- name: infra-image-registry-pull-secret
8687
{{ end }}

chart/infra-server/templates/deployment.yaml

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ spec:
2525
spec:
2626
containers:
2727
- name: infra-server
28-
image: us.gcr.io/stackrox-infra/infra-server:{{ required "A valid .Values.tag entry is required!" .Values.tag }}
28+
image: quay.io/rhacs-eng/infra-server:{{ required "A valid .Values.tag entry is required!" .Values.tag }}
2929
env:
3030
- name: GOOGLE_APPLICATION_CREDENTIALS
3131
value: /configuration/google-credentials.json
@@ -55,9 +55,5 @@ spec:
5555
- name: configuration
5656
secret:
5757
secretName: infra-server-secrets
58-
59-
{{ if eq .Values.environment "development" }}
60-
6158
imagePullSecrets:
6259
- name: infra-image-registry-pull-secret
63-
{{ end }}

0 commit comments

Comments
 (0)