I try to build automation procedure which base on connection data from tnsnames.ora which is oracle connection base for database.
Typical TNS build looks like this but there is much more connections than 1:
"
MY_BASE=
(DESCRIPTION=
(ADDRESS=
(PROTOCOL=TCP)
(HOST=10.20.30.40)
(PORT=1234)
)
(CONNECT_DATA=
(SERVER=dedicated)
(SERVICE_NAME=MY_SERVICE)
)
)
"
I need to extract base connection data which would be: BASE_NAME HOST PORT SERVICE_NAME more or less would look like
MY_BASE 10.20.30.40 1234 MY_SERVICE
Some of connections got more than one service but I will not bother you with these cause I have no idea how to make it as variable at the end :P
My point is to make a list in jenkins automation and make it to return list of connections in a checkbox. Than I and make variables out of those connection data so I will be able to do the same thing on many databases at the same time.
More or less...
Any idea? What to read, what to find, what to learn from AWK(cause it is a BIG tool).
Best regards!