hi, good morning, what's the best practice for a m...
# infra-deployment
m
hi, good morning, what's the best practice for a multi tenant support, would a setup with this https://meltano.com/docs/project.html#inheriting-plugin-definitions be enough? thanks
a
Can you say more about what you mean by multi-tenant? Do you mean some resources in AWS and some in GCP/Azure? Or something else?
cc @ken_payne
m
We want to provide integrations to several customers, that means possibly have several extractors which might be the same but for different clients
a
Ah yes - that makes sense. Thanks for clarifying. For this, you can certainly use plugin inheritance. If the number of instances you want gets larger than 10-20, you would probably want to lean more on environment variable-based config. In this model, you can have a small number of reference configurations but when invoked, you send different environment variables corresponding to each customer and their data's target landing space.
m
Thanks for clarification, but for what I have tried so far, the only way to have this kind of setup is via yaml configuration, I haven't found a way to do it with bash or via web UI. In our setup we want to let the user decide from certain available options from where to get their sources and with that we import the sources for the user. TL:DR; we want to let the users configure their extractors
you would probably want to lean more on environment variable-based config
can you point me to the documentation on this, seems like the perfect setup for us
e
@marc_garcia_sastre the docs are here: https://meltano.com/docs/configuration.html#environment-variables. Basically if you have a tap
my-tap
with a setting named
some_config
, you can set the variable
MY_TAP_SOME_CONFIG
at runtime to connect to a different database, SaaS API account, etc.
m
thats perfect, thanks
a
hey re: inheritance - is there a reason why that isn’t the default approach via the UI? (as in, when I look at the
meltano.yml
it looks like it’s added to the actual plugin’s settings instead) For each tap/target added via the ui, if it generated an inherited tap/target it’d be extremely useful to self serve with
a
@adam_rudd - Do you mean that editing within
meltano ui
causes the wrong definition to be updated? If yes, that sounds like it could actually a bug. If you can say a bit more about what you're seeing, would be much appreciated. Thanks.
a
I think it’s updating correctly; its more that any meltano config added uses the plugin entry, so if I wanted to add another tap/target of the same type (eg. S3 csv) i can’t
I’ll pop in a feature request and see if I can do a PR for the change if you folks agree. use case: • team has 2 pipelines they want to create via meltano UI • Target is s3 for both pipelines • Team creates pipeline 1 with s3 Target • When the Team goes to create pipeline 2, they cannot use the same s3 Target (its greyed out) because the plugin settings in the yaml has been attributed to pipeline 1 fix: • team has 2 pipelines they want to create via meltano UI • Target is s3 for both pipelines • Team creates pipeline 1 with s3 Target. A new inherited entry is created in the
meltano.yml
file with the pipeline specific settings • When the Team goes to create pipeline 2, they add the s3 target. Another new inherited entry is created in the
meltano.yml
file with the pipeline specific settings
s
I think you'll have problem in security in the future. All the passwords of the extractos are stored in .env file, and that can be mess.
k
Completely agree @sumit_rai - managing secrets in plain
.env
files is not ideal. Thankfully it isn't a common pattern we see 🙂 Most compute environments (including the dockerised ones) provide a way to inject env vars into services on launch from safe key stores, and there are also tools like chamber for setting environment variables from a secrets backend that you can run directly. We are also thinking about adding native support for secrets backends in meltano, and would love thoughts and feedback 🙏
a
@marc_garcia_sastre (et al) - This was a hot topic in #C01QS0RV78D today! If you missed it, you can check the recording and scan to maybe 20 or 30 minutes, until we start talking about "Environments" 🙂 cc @keegan_mccallum