Skip to content
This repository has been archived by the owner on May 15, 2024. It is now read-only.

[Data Sync] Handle database credentials #47

Closed
thiagosanchezenc opened this issue Oct 18, 2023 · 11 comments
Closed

[Data Sync] Handle database credentials #47

thiagosanchezenc opened this issue Oct 18, 2023 · 11 comments
Assignees

Comments

@thiagosanchezenc
Copy link
Contributor

thiagosanchezenc commented Oct 18, 2023

Obtain database connection in Oracle Database and Postgres Database using safe stored credentials obtained by a Secret Engine.

Background: Data Sync Engine Needs to obtain connection in databases in run time execution. Credentials must be obtained during runtime in requests to a secrets management engine.

Acceptance Criteria:

  1. Sample code connecting in Postgres and returning a result of a dummy query (like Select CURRENT_TIME a)
  2. Sample code connecting in Oracle and returning a result of a dummy query (like Select NOW() a FROM DUAL)
  3. Documentation available in confluence page.
@RMCampos
Copy link

RMCampos commented Jan 5, 2024

Handling Jenkins to access Vault to handle credentials.

@craigyu
Copy link
Collaborator

craigyu commented Jan 10, 2024

rolled over from sprint 23

@marcionemec-daitan
Copy link
Contributor

This issue is blocked by bcgov/nr-spar-data-sync#26 and bcgov/nr-spar-data-sync#27 issues, regarding the change of Jenkins Server from Cron to Polaris.

@craigyu
Copy link
Collaborator

craigyu commented Jan 31, 2024

rolled over from Sprint 24

@marcionemec-daitan
Copy link
Contributor

This issue is blocked by bcgov/nr-spar-data-sync#30 (Vault credentials gathering implementation in Jenkins Polaris).

marcionemec-daitan referenced this issue in bcgov/nr-spar-data-sync Feb 20, 2024
marcionemec-daitan referenced this issue in bcgov/nr-spar-data-sync Feb 20, 2024
marcionemec-daitan referenced this issue in bcgov/nr-spar-data-sync Feb 20, 2024
marcionemec-daitan referenced this issue in bcgov/nr-spar-data-sync Feb 20, 2024
marcionemec-daitan referenced this issue in bcgov/nr-spar-data-sync Feb 20, 2024
marcionemec-daitan referenced this issue in bcgov/nr-spar-data-sync Feb 20, 2024
marcionemec-daitan referenced this issue in bcgov/nr-spar-data-sync Feb 20, 2024
marcionemec-daitan referenced this issue in bcgov/nr-spar-data-sync Feb 20, 2024
marcionemec-daitan referenced this issue in bcgov/nr-spar-data-sync Feb 20, 2024
marcionemec-daitan referenced this issue in bcgov/nr-spar-data-sync Feb 20, 2024
marcionemec-daitan referenced this issue in bcgov/nr-spar-data-sync Feb 21, 2024
marcionemec-daitan referenced this issue in bcgov/nr-spar-data-sync Feb 21, 2024
marcionemec-daitan referenced this issue in bcgov/nr-spar-data-sync Feb 21, 2024
@SLDonnelly
Copy link

rolled over from sprint 25 to 26

marcionemec-daitan referenced this issue in bcgov/nr-spar-data-sync Mar 1, 2024
marcionemec-daitan referenced this issue in bcgov/nr-spar-data-sync Mar 1, 2024
marcionemec-daitan referenced this issue in bcgov/nr-spar-data-sync Mar 1, 2024
marcionemec-daitan referenced this issue in bcgov/nr-spar-data-sync Mar 1, 2024
marcionemec-daitan referenced this issue in bcgov/nr-spar-data-sync Mar 1, 2024
marcionemec-daitan referenced this issue in bcgov/nr-spar-data-sync Mar 1, 2024
marcionemec-daitan referenced this issue in bcgov/nr-spar-data-sync Mar 1, 2024
marcionemec-daitan referenced this issue in bcgov/nr-spar-data-sync Mar 1, 2024
marcionemec-daitan referenced this issue in bcgov/nr-spar-data-sync Mar 1, 2024
marcionemec-daitan referenced this issue in bcgov/nr-spar-data-sync Mar 1, 2024
marcionemec-daitan referenced this issue in bcgov/nr-spar-data-sync Mar 4, 2024
@marcionemec-daitan
Copy link
Contributor

Updates for this task, so far:

I finally could use the Openshift Client inside a Podman instance (at least to run "oc version" command).

I tried:

  1. Use a openshift red hat image, but I couldn't update the machine libraries because it needs a ret hat login credential to access the library/modules repositories.
  2. Use a openshift-client docker image, but it is built in a Linux Alpine base and it was hard (at least for me) to install other things and maintain this image or run this image in parallel with the podman python container acessing it. Besides, it's not an official maintained Red Hat image.
  3. Use a Python Image and install the OpenShift client by wget (using an official Red Hat release). Wget failed to retrieve the URL bevcause the proxy denied the URL access.
  4. Tried to use the Python image with the release Openshift Client already downloaded: it was successful.

@marcionemec-daitan
Copy link
Contributor

Latest error:
https://cd.io.nrs.gov.bc.ca/job/spar/job/DataSyncEngine/116/console

STEP 22/25: RUN ./oc_bin/oc login --token=$oct --server=$ocs
error: context deadline exceeded
Error: building at STEP "RUN ./oc_bin/oc login --token=$oct --server=$ocs": while running runtime: exit status 1

Requesting help to 1Team.

@marcionemec-daitan
Copy link
Contributor

This issue will need to be rolled up to the next sprint.
The Jenkins Polaris approach was put on hold because it was not possible to ensure a Postgres database port expose through portforward command. So, at this point we are trying to use a Github Workflow actions to ensure the deployment of ETL batch instances.

@RMCampos
Copy link

RMCampos commented Mar 14, 2024

Rolled over from sprint 23

@marcionemec-daitan
Copy link
Contributor

This issue should be closed, as the old repo does not exists anymore (new repo is nr-spar-data).
There are a new structure and new tasks to be included in future sprints.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.