From 79b2804bcd98d503fdc301dcd3961327128f4b12 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Miguel=20Garc=C3=ADa=20Dom=C3=ADnguez?= Date: Wed, 9 Dec 2020 12:23:55 +0100 Subject: [PATCH] Add recipe for google Stackdriver handler --- .../0.1/config/keys/google_service_account.json | 12 ++++++++++++ .../config/packages/prod/mgdsoft_stackdriver.yaml | 3 +++ mgdsoft/stackdriver-bundle/0.1/manifest.json | 14 ++++++++++++++ mgdsoft/stackdriver-bundle/0.1/post-install.txt | 5 +++++ 4 files changed, 34 insertions(+) create mode 100755 mgdsoft/stackdriver-bundle/0.1/config/keys/google_service_account.json create mode 100644 mgdsoft/stackdriver-bundle/0.1/config/packages/prod/mgdsoft_stackdriver.yaml create mode 100644 mgdsoft/stackdriver-bundle/0.1/manifest.json create mode 100644 mgdsoft/stackdriver-bundle/0.1/post-install.txt diff --git a/mgdsoft/stackdriver-bundle/0.1/config/keys/google_service_account.json b/mgdsoft/stackdriver-bundle/0.1/config/keys/google_service_account.json new file mode 100755 index 00000000..42bb6c2e --- /dev/null +++ b/mgdsoft/stackdriver-bundle/0.1/config/keys/google_service_account.json @@ -0,0 +1,12 @@ +{ + "type": "service_account", + "project_id": "projectid", + "private_key_id": "281379821737219379as87d", + "private_key": "-----BEGIN PRIVATE KEY-----\n-----END PRIVATE KEY-----\n", + "client_email": "service@appspot.gserviceaccount.com", + "client_id": "110459080868243513123", + "auth_uri": "https://accounts.google.com/o/oauth2/auth", + "token_uri": "https://oauth2.googleapis.com/token", + "auth_provider_x509_cert_url": "https://www.googleapis.com/oauth2/v1/certs", + "client_x509_cert_url": "https://www.googleapis.com/robot/v1/metadata/x509/service%40appspot.gserviceaccount.com" +} diff --git a/mgdsoft/stackdriver-bundle/0.1/config/packages/prod/mgdsoft_stackdriver.yaml b/mgdsoft/stackdriver-bundle/0.1/config/packages/prod/mgdsoft_stackdriver.yaml new file mode 100644 index 00000000..bd0eaca4 --- /dev/null +++ b/mgdsoft/stackdriver-bundle/0.1/config/packages/prod/mgdsoft_stackdriver.yaml @@ -0,0 +1,3 @@ +mgdsoft_stackdriver: + credentials_json_file: "%env(resolve:GOOGLE_SERVICE_ACCOUNT)%'" + level: info diff --git a/mgdsoft/stackdriver-bundle/0.1/manifest.json b/mgdsoft/stackdriver-bundle/0.1/manifest.json new file mode 100644 index 00000000..a5c3cfc3 --- /dev/null +++ b/mgdsoft/stackdriver-bundle/0.1/manifest.json @@ -0,0 +1,14 @@ +{ + "bundles": { + "MGDSoft\\Stackdriver\\MgdsoftStackdriverBundle": ["prod"] + }, + "copy-from-recipe": { + "config/": "%CONFIG_DIR%/" + }, + "env": { + "GOOGLE_SERVICE_ACCOUNT": "%kernel.project_dir%/config/keys/google_service_account.json" + }, + "gitignore": [ + "/config/keys/google_service_account.json" + ] +} diff --git a/mgdsoft/stackdriver-bundle/0.1/post-install.txt b/mgdsoft/stackdriver-bundle/0.1/post-install.txt new file mode 100644 index 00000000..9a18293e --- /dev/null +++ b/mgdsoft/stackdriver-bundle/0.1/post-install.txt @@ -0,0 +1,5 @@ + + MGD Stackdriver installed in PROD ENV + + +