From 2b62614b8003cad2560b1f1a8d75c37c1e3ea36f Mon Sep 17 00:00:00 2001 From: BlazeIsClone Date: Mon, 25 Sep 2023 17:37:10 +0530 Subject: [PATCH 1/2] refactor: NOTIFY_MYSQL_HOST change to hardcoded value --- .github/workflows/database.yml | 8 ++------ .github/workflows/files.yml | 8 ++------ 2 files changed, 4 insertions(+), 12 deletions(-) diff --git a/.github/workflows/database.yml b/.github/workflows/database.yml index 5a82f31..c6916f6 100644 --- a/.github/workflows/database.yml +++ b/.github/workflows/database.yml @@ -64,10 +64,6 @@ on: type: string required: true - NOTIFY_MYSQL_HOST: - type: string - required: true - NOTIFY_MYSQL_PORT: type: string required: true @@ -208,7 +204,7 @@ jobs: envs: TIMESTAMP script: | mysql \ - --host ${{ inputs.NOTIFY_MYSQL_HOST }} \ + --host localhost \ --port ${{ inputs.NOTIFY_MYSQL_PORT }} \ --user ${{ inputs.NOTIFY_MYSQL_USER }} \ -p${{ secrets.NOTIFY_MYSQL_PASS }} \ @@ -237,7 +233,7 @@ jobs: envs: TIMESTAMP script: | mysql \ - --host ${{ inputs.NOTIFY_MYSQL_HOST }} \ + --host localhost \ --port ${{ inputs.NOTIFY_MYSQL_PORT }} \ --user ${{ inputs.NOTIFY_MYSQL_USER }} \ -p${{ secrets.NOTIFY_MYSQL_PASS }} \ diff --git a/.github/workflows/files.yml b/.github/workflows/files.yml index f423c03..4ac43f3 100644 --- a/.github/workflows/files.yml +++ b/.github/workflows/files.yml @@ -52,10 +52,6 @@ on: type: string required: true - NOTIFY_MYSQL_HOST: - type: string - required: true - NOTIFY_MYSQL_PORT: type: string required: true @@ -162,7 +158,7 @@ jobs: envs: TIMESTAMP script: | mysql \ - --host ${{ inputs.NOTIFY_MYSQL_HOST }} \ + --host localhost \ --port ${{ inputs.NOTIFY_MYSQL_PORT }} \ --user ${{ inputs.NOTIFY_MYSQL_USER }} \ -p${{ secrets.NOTIFY_MYSQL_PASS }} \ @@ -191,7 +187,7 @@ jobs: envs: TIMESTAMP script: | mysql \ - --host ${{ inputs.NOTIFY_MYSQL_HOST }} \ + --host localhost \ --port ${{ inputs.NOTIFY_MYSQL_PORT }} \ --user ${{ inputs.NOTIFY_MYSQL_USER }} \ -p${{ secrets.NOTIFY_MYSQL_PASS }} \ From 52ac398816f9834fa933d0de625d649229c62630 Mon Sep 17 00:00:00 2001 From: BlazeIsClone Date: Mon, 25 Sep 2023 17:47:02 +0530 Subject: [PATCH 2/2] docs: fix titles github secrets & vars, add NOTIFY_MYSQL_SECRET_KEY --- README.md | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 9edb206..2caa352 100644 --- a/README.md +++ b/README.md @@ -11,7 +11,7 @@ Uses AWS-compatible S3 storage to store application databases and file backup sn Summary: The above will keep running every day at 1.00 AM and will retain up to 2 days of backups for us to roll back. -### Required GitHub Repository Action Secrets +### Required GitHub Repository Action Variables We use Encrypted secrets to store sensitive credentials. @@ -43,7 +43,7 @@ NOTIFY_MYSQL_USER NOTIFY_MYSQL_DATABASE ``` -### Required GitHub Repository Action Variables +### Required GitHub Repository Action Secrets We use variables for non-sensitive credentials that can be read or updated later. @@ -56,6 +56,7 @@ SERVER_SECRET_KEY MYSQL_PASS NOTIFY_MYSQL_PASS +NOTIFY_SERVER_SECRET_KEY ``` ### Using This Workflow