Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 5b6040c60d | |||
| 358356a1b1 | |||
| 71133be104 |
@@ -16,4 +16,4 @@ images:
|
|||||||
- name: gitea.czernobog.pl/gitea/astrololo-render
|
- name: gitea.czernobog.pl/gitea/astrololo-render
|
||||||
newTag: latest
|
newTag: latest
|
||||||
- name: gitea.czernobog.pl/gitea/astrololo-presentation
|
- name: gitea.czernobog.pl/gitea/astrololo-presentation
|
||||||
newTag: b36b3bee
|
newTag: a9f2a038
|
||||||
|
|||||||
@@ -12,29 +12,6 @@ namespace, sharing the same librarian / musician / radio and the shared
|
|||||||
Files: `deploy-bot.yaml` (Deployment + Service), `deploy-bot-backup.yaml`
|
Files: `deploy-bot.yaml` (Deployment + Service), `deploy-bot-backup.yaml`
|
||||||
(daily backup CronJob). Both are wired into `kustomization.yaml`.
|
(daily backup CronJob). Both are wired into `kustomization.yaml`.
|
||||||
|
|
||||||
## Update channel — only on `[deploy]`
|
|
||||||
|
|
||||||
Unlike the test bot (which tracks every build), the production bot updates **only
|
|
||||||
when you promote a version**. It runs a **separate image**,
|
|
||||||
`conjurer-bot-deploy`, which the conjurer CI tags **only when the commit message
|
|
||||||
contains `[deploy]`** (it re-tags the already-built `conjurer-bot:<sha>` — same
|
|
||||||
bytes). The image-updater's `deploy-bot` alias then bumps this bot's tag.
|
|
||||||
|
|
||||||
So: normal commits update the test bot + librarian; a commit with `[deploy]` in
|
|
||||||
its message is the one that also rolls the production bot.
|
|
||||||
|
|
||||||
**Bootstrap (first run):** `conjurer-bot-deploy` doesn't exist until the first
|
|
||||||
`[deploy]` build. Either land one commit with `[deploy]` in the message, or seed
|
|
||||||
it once by hand:
|
|
||||||
```bash
|
|
||||||
docker pull gitea.czernobog.pl/gitea/conjurer-bot:ac16b77f
|
|
||||||
docker tag gitea.czernobog.pl/gitea/conjurer-bot:ac16b77f \
|
|
||||||
gitea.czernobog.pl/gitea/conjurer-bot-deploy:ac16b77f
|
|
||||||
docker push gitea.czernobog.pl/gitea/conjurer-bot-deploy:ac16b77f
|
|
||||||
```
|
|
||||||
(match the tag in `kustomization.yaml`). Note the librarian is shared, so it
|
|
||||||
still tracks latest — mind large bot⇄librarian version skews.
|
|
||||||
|
|
||||||
## One-time setup
|
## One-time setup
|
||||||
|
|
||||||
1. **Secret** — already exists as `deploy-conjurer-netrc` (a netrc carrying the
|
1. **Secret** — already exists as `deploy-conjurer-netrc` (a netrc carrying the
|
||||||
|
|||||||
@@ -15,8 +15,5 @@ spec:
|
|||||||
applicationRefs:
|
applicationRefs:
|
||||||
- namePattern: "conjurer"
|
- namePattern: "conjurer"
|
||||||
images:
|
images:
|
||||||
- { alias: "librarian", imageName: "gitea.czernobog.pl/gitea/conjurer-librarian" }
|
- { alias: "librarian", imageName: "gitea.czernobog.pl/gitea/conjurer-librarian" }
|
||||||
- { alias: "bot", imageName: "gitea.czernobog.pl/gitea/conjurer-bot" }
|
- { alias: "bot", imageName: "gitea.czernobog.pl/gitea/conjurer-bot" }
|
||||||
# Production bot tracks its own image, which only gets new tags on
|
|
||||||
# [deploy] commits (conjurer CI) - so it updates only on promoted builds.
|
|
||||||
- { alias: "deploy-bot", imageName: "gitea.czernobog.pl/gitea/conjurer-bot-deploy" }
|
|
||||||
@@ -30,11 +30,7 @@ spec:
|
|||||||
imagePullSecrets: [{ name: gitea-registry }]
|
imagePullSecrets: [{ name: gitea-registry }]
|
||||||
containers:
|
containers:
|
||||||
- name: bot
|
- name: bot
|
||||||
# SEPARATE image from the test bot: conjurer-bot-deploy only gets a new
|
image: gitea.czernobog.pl/gitea/conjurer-bot:c8aae106
|
||||||
# tag when a commit message contains [deploy] (see the conjurer CI), so
|
|
||||||
# this bot updates only on versions you explicitly promote. Tag is
|
|
||||||
# managed by the image-updater (kustomization images:).
|
|
||||||
image: gitea.czernobog.pl/gitea/conjurer-bot-deploy:c8aae106
|
|
||||||
ports: [{ containerPort: 5000 }]
|
ports: [{ containerPort: 5000 }]
|
||||||
env:
|
env:
|
||||||
- { name: CONJURER_DATA_DIR, value: "/data" }
|
- { name: CONJURER_DATA_DIR, value: "/data" }
|
||||||
|
|||||||
@@ -11,6 +11,3 @@ images:
|
|||||||
newTag: ac16b77f
|
newTag: ac16b77f
|
||||||
- name: gitea.czernobog.pl/gitea/conjurer-bot
|
- name: gitea.czernobog.pl/gitea/conjurer-bot
|
||||||
newTag: ac16b77f
|
newTag: ac16b77f
|
||||||
# Production bot channel - only bumped when a [deploy]-tagged build appears.
|
|
||||||
- name: gitea.czernobog.pl/gitea/conjurer-bot-deploy
|
|
||||||
newTag: ac16b77f
|
|
||||||
|
|||||||
Reference in New Issue
Block a user