-
Notifications
You must be signed in to change notification settings - Fork 38
49 lines (37 loc) · 1.58 KB
/
build-run.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
name: Start Notion backup
on:
push:
branches: [ master ]
# adds a "run workflow" button to the page
workflow_dispatch:
# will be triggered at 04:05 on every 2nd day-of-month from 2 through 30.
schedule:
- cron: '5 4 2-30/2 * *'
jobs:
build-and-run:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up JDK 1.11
uses: actions/setup-java@v1
with:
java-version: 1.11
- name: Build with Maven
run: mvn -B package --file pom.xml --no-transfer-progress
- name: Start Notion Backup
run: java -jar ./target/notion-backup-1.0-SNAPSHOT.jar
env:
NOTION_SPACE_ID: ${{ secrets.NOTION_SPACE_ID }}
NOTION_TOKEN_V2: ${{ secrets.NOTION_TOKEN_V2 }}
GOOGLE_DRIVE_ROOT_FOLDER_ID: ${{ secrets.GOOGLE_DRIVE_ROOT_FOLDER_ID }}
GOOGLE_DRIVE_SERVICE_ACCOUNT: ${{ secrets.GOOGLE_DRIVE_SERVICE_ACCOUNT }}
GOOGLE_DRIVE_SERVICE_ACCOUNT_SECRET_JSON: ${{ secrets.GOOGLE_DRIVE_SERVICE_ACCOUNT_SECRET_JSON }}
GOOGLE_DRIVE_SERVICE_ACCOUNT_SECRET_FILE_PATH: ${{ secrets.GOOGLE_DRIVE_SERVICE_ACCOUNT_SECRET_FILE_PATH }}
DROPBOX_ACCESS_TOKEN: ${{ secrets.DROPBOX_ACCESS_TOKEN }}
NEXTCLOUD_EMAIL: ${{ secrets.NEXTCLOUD_EMAIL }}
NEXTCLOUD_PASSWORD: ${{ secrets.NEXTCLOUD_PASSWORD }}
NEXTCLOUD_WEBDAV_URL: ${{ secrets.NEXTCLOUD_WEBDAV_URL }}
PCLOUD_ACCESS_TOKEN: ${{ secrets.PCLOUD_ACCESS_TOKEN }}
PCLOUD_API_HOST: ${{ secrets.PCLOUD_API_HOST }}
PCLOUD_FOLDER_ID: ${{ secrets.PCLOUD_FOLDER_ID }}
DOWNLOADS_DIRECTORY_PATH: /tmp/