Compare commits
1 Commits
main
...
hermes-rep
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
ac54aee53d |
28
Jenkinsfile
vendored
28
Jenkinsfile
vendored
@ -1,16 +1,11 @@
|
|||||||
pipeline {
|
pipeline {
|
||||||
agent {
|
agent {
|
||||||
kubernetes {
|
kubernetes {
|
||||||
// Keep build I/O off the node's runtime USB drive.
|
|
||||||
workspaceVolume dynamicPVC(accessModes: 'ReadWriteOnce', requestsSize: '40Gi', storageClassName: 'ci-scratch')
|
|
||||||
defaultContainer 'tester'
|
defaultContainer 'tester'
|
||||||
yaml """
|
yaml """
|
||||||
apiVersion: v1
|
apiVersion: v1
|
||||||
kind: Pod
|
kind: Pod
|
||||||
spec:
|
spec:
|
||||||
securityContext:
|
|
||||||
fsGroup: 1000
|
|
||||||
fsGroupChangePolicy: OnRootMismatch
|
|
||||||
nodeSelector:
|
nodeSelector:
|
||||||
kubernetes.io/arch: arm64
|
kubernetes.io/arch: arm64
|
||||||
node-role.kubernetes.io/worker: "true"
|
node-role.kubernetes.io/worker: "true"
|
||||||
@ -19,9 +14,10 @@ spec:
|
|||||||
requiredDuringSchedulingIgnoredDuringExecution:
|
requiredDuringSchedulingIgnoredDuringExecution:
|
||||||
nodeSelectorTerms:
|
nodeSelectorTerms:
|
||||||
- matchExpressions:
|
- matchExpressions:
|
||||||
- {key: hardware, operator: In, values: [rpi5, rpi4]}
|
- key: kubernetes.io/hostname
|
||||||
- {key: node-role.kubernetes.io/worker, operator: In, values: ["true"]}
|
operator: NotIn
|
||||||
- {key: kubernetes.io/hostname, operator: NotIn, values: [titan-04, titan-05, titan-06, titan-08, titan-11, titan-12, titan-13, titan-14, titan-15, titan-17, titan-18, titan-19]}
|
values:
|
||||||
|
- titan-06
|
||||||
preferredDuringSchedulingIgnoredDuringExecution:
|
preferredDuringSchedulingIgnoredDuringExecution:
|
||||||
- weight: 100
|
- weight: 100
|
||||||
preference:
|
preference:
|
||||||
@ -54,9 +50,8 @@ spec:
|
|||||||
- "--host=tcp://0.0.0.0:2375"
|
- "--host=tcp://0.0.0.0:2375"
|
||||||
- "--tls=false"
|
- "--tls=false"
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
- name: workspace-volume
|
- name: dind-storage
|
||||||
mountPath: /var/lib/docker
|
mountPath: /var/lib/docker
|
||||||
subPath: .cache/docker
|
|
||||||
- name: workspace-volume
|
- name: workspace-volume
|
||||||
mountPath: /home/jenkins/agent
|
mountPath: /home/jenkins/agent
|
||||||
- name: builder
|
- name: builder
|
||||||
@ -95,20 +90,20 @@ spec:
|
|||||||
volumes:
|
volumes:
|
||||||
- name: docker-config-writable
|
- name: docker-config-writable
|
||||||
emptyDir: {}
|
emptyDir: {}
|
||||||
|
- name: dind-storage
|
||||||
|
emptyDir: {}
|
||||||
- name: harbor-config
|
- name: harbor-config
|
||||||
secret:
|
secret:
|
||||||
secretName: harbor-robot-pipeline
|
secretName: harbor-robot-pipeline
|
||||||
items:
|
items:
|
||||||
- key: .dockerconfigjson
|
- key: .dockerconfigjson
|
||||||
path: config.json
|
path: config.json
|
||||||
|
- name: workspace-volume
|
||||||
|
emptyDir: {}
|
||||||
"""
|
"""
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
environment {
|
environment {
|
||||||
PIP_CACHE_DIR = '/home/jenkins/agent/.cache/pip'
|
|
||||||
NPM_CONFIG_CACHE = '/home/jenkins/agent/.cache/npm'
|
|
||||||
SONAR_USER_HOME = '/home/jenkins/agent/.cache/sonar'
|
|
||||||
TMPDIR = '/home/jenkins/agent/.cache/tmp'
|
|
||||||
PIP_DISABLE_PIP_VERSION_CHECK = '1'
|
PIP_DISABLE_PIP_VERSION_CHECK = '1'
|
||||||
PYTHONUNBUFFERED = '1'
|
PYTHONUNBUFFERED = '1'
|
||||||
SUITE_NAME = 'atlasbot'
|
SUITE_NAME = 'atlasbot'
|
||||||
@ -124,11 +119,6 @@ spec:
|
|||||||
buildDiscarder(logRotator(daysToKeepStr: '30', numToKeepStr: '200', artifactDaysToKeepStr: '30', artifactNumToKeepStr: '120'))
|
buildDiscarder(logRotator(daysToKeepStr: '30', numToKeepStr: '200', artifactDaysToKeepStr: '30', artifactNumToKeepStr: '120'))
|
||||||
}
|
}
|
||||||
stages {
|
stages {
|
||||||
stage('Prepare build scratch') {
|
|
||||||
steps {
|
|
||||||
sh 'mkdir -p /home/jenkins/agent/.cache/tmp /home/jenkins/agent/.cache/go-tmp'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
stage('Checkout') {
|
stage('Checkout') {
|
||||||
steps {
|
steps {
|
||||||
checkout scm
|
checkout scm
|
||||||
|
|||||||
@ -163,11 +163,10 @@ class MatrixBot:
|
|||||||
note = "thinking"
|
note = "thinking"
|
||||||
snippet = note[:64]
|
snippet = note[:64]
|
||||||
now = time.monotonic()
|
now = time.monotonic()
|
||||||
should_send = False
|
should_send = (
|
||||||
if snippet and snippet != last_note:
|
(snippet and snippet != last_note)
|
||||||
should_send = True
|
or now - last_sent >= max(60.0, self._settings.thinking_interval_sec * 2)
|
||||||
elif now - last_sent >= max(60.0, self._settings.thinking_interval_sec * 2):
|
)
|
||||||
should_send = True
|
|
||||||
if should_send:
|
if should_send:
|
||||||
msg = f"Still thinking — {snippet}…"
|
msg = f"Still thinking — {snippet}…"
|
||||||
await self._client.send_message(token, room_id, msg)
|
await self._client.send_message(token, room_id, msg)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user