Some checks are pending
Build and Deploy / build (push) Waiting to run
- Updated monitor.py to support both OAuth and Service Account - Created setup-oauth-local.py for easy local authorization - Created cronjob-oauth.yaml for OAuth-based deployment - Updated README with both authentication options - OAuth is now the recommended method (no key file needed)
33 lines
923 B
YAML
33 lines
923 B
YAML
apiVersion: batch/v1
|
|
kind: CronJob
|
|
metadata:
|
|
name: gsc-monitoring-oauth
|
|
namespace: manoonoils
|
|
spec:
|
|
schedule: "0 9 * * *" # Run daily at 9 AM UTC
|
|
jobTemplate:
|
|
spec:
|
|
template:
|
|
spec:
|
|
containers:
|
|
- name: gsc-monitor
|
|
image: gcr.io/manoonoils/gsc-monitoring:latest
|
|
env:
|
|
- name: GSC_OAUTH_FILE
|
|
value: /etc/gsc-monitoring/oauth-credentials.json
|
|
- name: PYTHONUNBUFFERED
|
|
value: "1"
|
|
volumeMounts:
|
|
- name: gsc-oauth-credentials
|
|
mountPath: /etc/gsc-monitoring
|
|
readOnly: true
|
|
- name: logs
|
|
mountPath: /var/log/gsc-monitoring
|
|
volumes:
|
|
- name: gsc-oauth-credentials
|
|
secret:
|
|
secretName: gsc-oauth-credentials
|
|
- name: logs
|
|
emptyDir: {}
|
|
restartPolicy: OnFailure
|