41 lines
880 B
YAML
41 lines
880 B
YAML
---
|
|
resources:
|
|
- name: every-hour
|
|
type: time
|
|
source:
|
|
interval: 1h
|
|
|
|
- name: script
|
|
type: git
|
|
source:
|
|
uri: https://gitea.redxef.at/redxef/wp-cal-integration
|
|
branch: master
|
|
|
|
jobs:
|
|
- name: update-calendar
|
|
plan:
|
|
- get: every-hour
|
|
trigger: true
|
|
- get: script
|
|
- task: run-update
|
|
config:
|
|
platform: linux
|
|
image_resource:
|
|
type: registry-image
|
|
source:
|
|
repository: alpine
|
|
tag: latest
|
|
inputs:
|
|
- name: script
|
|
path: .
|
|
params:
|
|
configuration_json: ((configuration))
|
|
run:
|
|
path: sh
|
|
args:
|
|
- -c
|
|
- |
|
|
#!/usr/bin/env sh
|
|
apk --no-cache --update add libcap jq python3 py3-pip
|
|
python3 -m pip install --break-system-packages --requirement requirements.txt
|
|
echo "$configuration_json" | ./main.py -l :verbose -c -
|