1

How do I set a database connection's password to use an environment variable. I cannot add these to the kettle.properties file (security policy). When I click control-space on OSX, nothing happens. If I try and paste the string ${PASSWORD} directly into the password field, it does not allow it, due to the presumably non-alphanumeric '$' char.

The other fields as shown below work fine.

The EDIT Connection dialog below shows the field in red, which is what I want to achieve logically.

Using PDI Community 8.2, on Mac OSX Mojave.

I want the field in red filled

NullPumpkinException
  • 1,396
  • 1
  • 18
  • 22

5 Answers5

2

I found one solution. Instead of creating the DB connection in Table Input Step with Edit or New, I used the Wizard option, which allowed me to paste ${SOURCE_DB_PASSWORD} variable into the password field.

The characters were obfuscated, so it's impossible to tell if you have the correct value, but it worked.

NullPumpkinException
  • 1,396
  • 1
  • 18
  • 22
1

CTRL+V doesn’t work, you need to right-click and choose paste.

nsousa
  • 4,448
  • 1
  • 10
  • 15
0

You can encrypt the password and save it on kettle.properties, in spoon directory execute:

Encr.bat -kettle yourpassword

Paste the full result with "Encrypted" in the properties file, restart spoon and test the connection.

0

In OSX, I believe you need to use the shortcut shift + cmd + space to access the environment variables.

You might need to use the 'get variables'-step to define the variables from kettle.properties.

Reitenator
  • 1,075
  • 13
  • 13
0

Just type ${Variable_Name} as you are defining for other environment variable. If open your .ktr file in Notepad++ you can see the value is your Variable_Name instead of Encrypted password. It worked for me :)

enter image description here