outofcoffee / imposter

Scriptable, multipurpose mock server. Run standalone mock servers, or embed mocks within your tests.
https://imposter.sh
Other
364 stars 59 forks source link

Setting IMPOSTER_PLUGIN_DIR in AWS Begets '<directory> is not a valid directory' #624

Open daniel-klingensmith-jamf opened 2 weeks ago

daniel-klingensmith-jamf commented 2 weeks ago

In CDK:

'IMPOSTER_PLUGIN_DIR': `s3://imposter/3.35.2/plugins`

In CloudWatch logs:

2024-09-06 17:49:00  WARN  i.g.i.u.ClassLoaderUtil - Path s3:/imposter/3.35.2/plugins is not a valid directory

I've attempted the same with underscores instead of periods for the version (3_35_2) with the same result.

Is this directory understood by Imposter to be relative to the IMPOSTER_CONFIG_DIR value?

outofcoffee commented 2 weeks ago

Hi @daniel-klingensmith-jamf, thanks for raising this.

Presently there's no support for external plugin storage, such as S3 or a URL. The pattern for using plugins is to bundle them into the deployable (e.g. Lambda ZIP or container image), or, to use the 'imposter-all' distribution which includes (pretty much) all plugins.

Here's some info on bundling: https://docs.imposter.sh/bundle/

daniel-klingensmith-jamf commented 1 week ago

Thanks for the clarity! You may want to add more to the Environment Variables docs page to prevent others from the same mistake.