Skip to content

Commit 2091d5f

Browse files
committed
Merge branch 'main' into promote/release-v5.10.3940
2 parents c14678e + 5d694b3 commit 2091d5f

File tree

6 files changed

+88
-9
lines changed

6 files changed

+88
-9
lines changed

base/monitoring/jaeger/jaeger.Deployment.yaml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,12 @@ spec:
3131
containers:
3232
- name: jaeger
3333
image: index.docker.io/sourcegraph/jaeger-all-in-one:5.10.3940@sha256:d830a8c3e8c2be841de04118664f01710fa75d22f4302351309cb39932eee936
34-
args: ["--memory.max-traces=20000", "--sampling.strategies-file=/etc/jaeger/sampling_strategies.json", "--collector.otlp.enabled"]
34+
args:
35+
[
36+
"--memory.max-traces=20000",
37+
"--sampling.strategies-file=/etc/jaeger/sampling_strategies.json",
38+
"--collector.otlp.enabled",
39+
]
3540
ports:
3641
- containerPort: 5775
3742
protocol: UDP

base/sourcegraph/codeinsights-db/codeinsights-db.StatefulSet.yaml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,12 @@ spec:
2727
initContainers:
2828
- name: correct-data-dir-permissions
2929
image: index.docker.io/sourcegraph/alpine-3.14:5.10.3940@sha256:e9008c3e20b445abb8788bb513479418ef55476e2c01228b6c094776919bcbe4
30-
command: ["sh", "-c", "if [ -d /var/lib/postgresql/data/pgdata ]; then chmod 750 /var/lib/postgresql/data/pgdata; fi"]
30+
command:
31+
[
32+
"sh",
33+
"-c",
34+
"if [ -d /var/lib/postgresql/data/pgdata ]; then chmod 750 /var/lib/postgresql/data/pgdata; fi",
35+
]
3136
volumeMounts:
3237
- mountPath: /var/lib/postgresql/data/
3338
name: disk

base/sourcegraph/codeintel-db/codeintel-db.StatefulSet.yaml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,12 @@ spec:
2828
initContainers:
2929
- name: correct-data-dir-permissions
3030
image: index.docker.io/sourcegraph/alpine-3.14:5.10.3940@sha256:e9008c3e20b445abb8788bb513479418ef55476e2c01228b6c094776919bcbe4
31-
command: ["sh", "-c", "if [ -d /data/pgdata-12 ]; then chmod 750 /data/pgdata-12; fi"]
31+
command:
32+
[
33+
"sh",
34+
"-c",
35+
"if [ -d /data/pgdata-12 ]; then chmod 750 /data/pgdata-12; fi",
36+
]
3237
volumeMounts:
3338
- mountPath: /data
3439
name: disk

base/sourcegraph/pgsql/pgsql.StatefulSet.yaml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,12 @@ spec:
2828
initContainers:
2929
- name: correct-data-dir-permissions
3030
image: index.docker.io/sourcegraph/alpine-3.14:5.10.3940@sha256:e9008c3e20b445abb8788bb513479418ef55476e2c01228b6c094776919bcbe4
31-
command: ["sh", "-c", "if [ -d /data/pgdata-12 ]; then chmod 750 /data/pgdata-12; fi"]
31+
command:
32+
[
33+
"sh",
34+
"-c",
35+
"if [ -d /data/pgdata-12 ]; then chmod 750 /data/pgdata-12; fi",
36+
]
3237
volumeMounts:
3338
- mountPath: /data
3439
name: disk

components/executors/dind/executor.Deployment.yaml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -65,11 +65,11 @@ spec:
6565
securityContext:
6666
privileged: true
6767
command:
68-
- 'dockerd'
69-
- '--tls=false'
70-
- '--mtu=1200'
71-
- '--registry-mirror=http://private-docker-registry:5000'
72-
- '--host=tcp://0.0.0.0:2375'
68+
- "dockerd"
69+
- "--tls=false"
70+
- "--mtu=1200"
71+
- "--registry-mirror=http://private-docker-registry:5000"
72+
- "--host=tcp://0.0.0.0:2375"
7373
livenessProbe:
7474
tcpSocket:
7575
port: 2375

release.yaml

Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -332,6 +332,7 @@ promoteToPublic:
332332
cat << EOF | buildkite-agent annotate --style info
333333
Promoted release is **publicly available** through a git tag at [\`{{version}}\`](https://github.com/sourcegraph/deploy-sourcegraph-k8s/tree/{{version}}).
334334
EOF
335+
335336
- name: 'Promote on release registry'
336337
cmd: |
337338
echo "Promoting deploy-sourcegraph-k8s {{version}} release on release registry"
@@ -348,3 +349,61 @@ promoteToPublic:
348349
echo "Build created, see:"
349350
echo $body | jq .web_url
350351
fi
352+
353+
- name: "update main with latest version"
354+
cmd: |
355+
set -eu
356+
branch="promote/release-{{version}}-update-main"
357+
echo "Checking out origin/main"
358+
git fetch origin main
359+
git switch main
360+
echo "Creating branch origin/${branch}"
361+
git switch -c "${branch}"
362+
363+
- name: "sg ops"
364+
cmd: |
365+
set -eu
366+
sg ops update-images \
367+
--kind k8s \
368+
--registry index.docker.io/sourcegraph \
369+
--docker-username=$DOCKER_USERNAME \
370+
--docker-password=$DOCKER_PASSWORD \
371+
--pin-tag {{inputs.server.tag}} \
372+
base/
373+
374+
- name: "sg ops (executors)"
375+
cmd: |
376+
set -eu
377+
sg ops update-images \
378+
--kind k8s \
379+
--registry index.docker.io/sourcegraph \
380+
--docker-username=$DOCKER_USERNAME \
381+
--docker-password=$DOCKER_PASSWORD \
382+
--pin-tag {{inputs.server.tag}} \
383+
components/executors/
384+
385+
- name: "git:commit"
386+
cmd: |
387+
set -eu
388+
branch="promote/release-{{version}}-update-main"
389+
find . -name "*.yaml" | xargs git add
390+
find . -name "*.yml" | xargs git add
391+
392+
# Careful with the quoting for the config, using double quotes will lead
393+
# to the shell dropping out all quotes from the json, leading to failed
394+
# parsing.
395+
git commit -am 'update-main: {{version}}' -m 'update main with latest release'
396+
git push origin "${branch}"
397+
398+
- name: "github:pr"
399+
cmd: |
400+
set -eu
401+
internal_branch="promote/release-{{version}}-update-main"
402+
gh pr create \
403+
--fill \
404+
--draft \
405+
--base "$internal_branch" \
406+
--title "Update main: build {{version}}" \
407+
--body "Test plan: automated release PR, CI will perform additional checks"
408+
echo "🚢 Please check the associated CI build to ensure the process completed".
409+

0 commit comments

Comments
 (0)