egg-minio-client

minio plugin for egg

Usage no npm install needed!

<script type="module">
  import eggMinioClient from 'https://cdn.skypack.dev/egg-minio-client';
</script>

README

egg-minio

NPM version build status Test coverage David deps Known Vulnerabilities npm download

Plugin for minio client

Install

$ npm i egg-minio --save

Usage

// {app_root}/config/plugin.js
exports.minio = {
  enable: true,
  package: "egg-minio"
};
// {app_root}/config/config.default.js
config.minio = {
  endPoint: "127.0.0.1",
  port: parseInt(9000),
  useSSL: false,
  accessKey: "accessKey",
  secretKey: "secretKey"
};

Example

// put
app.minio.putObject(this.config.ossBucketName, filename, stream);

License

MIT