feat(k3s): add fully automatic daily FreeRide auto-updates via cron
This commit is contained in:
parent
fe0992e39a
commit
7cd0ac1047
3 changed files with 35 additions and 2 deletions
|
|
@ -253,3 +253,11 @@ data:
|
||||||
echo_transcription\": false\n },\n \"build_info\": {\n \"version\": \"0.1.0\"\
|
echo_transcription\": false\n },\n \"build_info\": {\n \"version\": \"0.1.0\"\
|
||||||
,\n \"git_commit\": \"054b55fd\",\n \"build_time\": \"2026-03-23T10:15:13+0100\"\
|
,\n \"git_commit\": \"054b55fd\",\n \"build_time\": \"2026-03-23T10:15:13+0100\"\
|
||||||
,\n \"go_version\": \"go1.26.1\"\n }\n}"
|
,\n \"go_version\": \"go1.26.1\"\n }\n}"
|
||||||
|
cron.json: "{\n \"version\": 1,\n \"jobs\": [\n {\n \"id\": \"freeride-auto-daily\"\
|
||||||
|
,\n \"name\": \"Daily FreeRide Update\",\n \"enabled\": true,\n \
|
||||||
|
\ \"schedule\": {\n \"kind\": \"cron\",\n \"expr\": \"0 3 * * *\"\
|
||||||
|
\n },\n \"payload\": {\n \"kind\": \"agent_turn\",\n \"\
|
||||||
|
message\": \"freeride auto\",\n \"command\": \"\",\n \"channel\"\
|
||||||
|
: \"cli\",\n \"to\": \"cron\"\n },\n \"state\": {},\n \"\
|
||||||
|
createdAtMs\": 1713511200000,\n \"updatedAtMs\": 1713511200000,\n \"\
|
||||||
|
deleteAfterRun\": false\n }\n ]\n}\n"
|
||||||
|
|
|
||||||
25
k3s/cron.json
Normal file
25
k3s/cron.json
Normal file
|
|
@ -0,0 +1,25 @@
|
||||||
|
{
|
||||||
|
"version": 1,
|
||||||
|
"jobs": [
|
||||||
|
{
|
||||||
|
"id": "freeride-auto-daily",
|
||||||
|
"name": "Daily FreeRide Update",
|
||||||
|
"enabled": true,
|
||||||
|
"schedule": {
|
||||||
|
"kind": "cron",
|
||||||
|
"expr": "0 3 * * *"
|
||||||
|
},
|
||||||
|
"payload": {
|
||||||
|
"kind": "agent_turn",
|
||||||
|
"message": "freeride auto",
|
||||||
|
"command": "",
|
||||||
|
"channel": "cli",
|
||||||
|
"to": "cron"
|
||||||
|
},
|
||||||
|
"state": {},
|
||||||
|
"createdAtMs": 1713511200000,
|
||||||
|
"updatedAtMs": 1713511200000,
|
||||||
|
"deleteAfterRun": false
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
@ -23,9 +23,9 @@ spec:
|
||||||
- -c
|
- -c
|
||||||
- |
|
- |
|
||||||
mkdir -p /home/picoclaw/.picoclaw
|
mkdir -p /home/picoclaw/.picoclaw
|
||||||
echo "Syncing config.json from ConfigMap..."
|
echo "Syncing config files from ConfigMap..."
|
||||||
grep "GOOGLE" /config-source/config.json
|
|
||||||
cp /config-source/config.json /home/picoclaw/.picoclaw/config.json
|
cp /config-source/config.json /home/picoclaw/.picoclaw/config.json
|
||||||
|
cp /config-source/cron.json /home/picoclaw/.picoclaw/cron.json
|
||||||
rm -f /home/picoclaw/.picoclaw/secure.yaml /home/picoclaw/.picoclaw/.security.yml
|
rm -f /home/picoclaw/.picoclaw/secure.yaml /home/picoclaw/.picoclaw/.security.yml
|
||||||
# Ensure the agent has write permissions to its home volume
|
# Ensure the agent has write permissions to its home volume
|
||||||
chown -R 1000:1000 /home/picoclaw/.picoclaw
|
chown -R 1000:1000 /home/picoclaw/.picoclaw
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue