Skip to content

Commit

Permalink
Add recipe to push data from Jira to Google
Browse files Browse the repository at this point in the history
Signed-off-by: Rafael Sene <[email protected]>
  • Loading branch information
rpsene committed Jun 2, 2023
1 parent f57fe02 commit 3d14b0b
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 1 deletion.
23 changes: 23 additions & 0 deletions .github/workflows/daily-push-to-google.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: Daily Push To Google from Jira

on:
schedule:
- cron: '0 */8 * * *' # this will run three times a day (every 8 hours)
workflow_dispatch: # this allows the workflow to be run manually from the Actions tab

jobs:
run-container-and-send-email:
runs-on: ubuntu-latest

steps:
- name: Checkout code
uses: actions/checkout@v2

- name: Run Docker Container
run: |
docker run --rm \
-v $(pwd)/gcp_creds.json:/gcp_creds.json \
-e JIRA_TOKEN=${{ secrets.JIRA_TOKEN }} \
-e GOOGLE_SHEETS_TOKEN=${{ secrets.GOOGLE_SHEETS_TOKEN }} \
-e GOOGLE_SERVICE_ACCOUNT_CREDENTIALS="${{ secrets.GOOGLE_SERVICE_ACCOUNT_CREDENTIALS }}" \
riscvintl/jira-to-google:latest
2 changes: 1 addition & 1 deletion from-jira-to-google.py
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ def get_quarter_year_format(date):
# Function to get Google API credentials from the service account file.
# Returns the credentials object.
# """
# creds = Credentials.from_service_account_file('token.json')
# creds = Credentials.from_service_account_file('gcp_creds.json')

# # If modifying the scopes, delete the token.json file
# SCOPES = ['https://www.googleapis.com/auth/spreadsheets',
Expand Down

0 comments on commit 3d14b0b

Please sign in to comment.