Requesting /admin/docker/repos.json with a lot of plugins installed can take a lot of time because of the large number of calls to the 'git' CLI that are used to retrieve various information about the plugin (eg. branch, latest commit, remote URL, etc). This is not a problem in production because of memoization and the much lower number of installed plugins, but it is a problem in test environment where specs requesting this page can take 10+ seconds with ~100 installed plugins. This commit speeds up by stubbing the `find_all` method to return only the first few repositories. |
||
---|---|---|
.github/workflows | ||
admin/assets/javascripts/discourse | ||
app/controllers/docker_manager | ||
assets/stylesheets/common | ||
config | ||
lib/docker_manager | ||
scripts | ||
spec | ||
test/javascripts | ||
.discourse-compatibility | ||
.eslintrc.cjs | ||
.gitignore | ||
.prettierrc.cjs | ||
.rubocop.yml | ||
.streerc | ||
.template-lintrc.cjs | ||
Gemfile | ||
Gemfile.lock | ||
LICENSE | ||
README.md | ||
package.json | ||
plugin.rb | ||
translator.yml | ||
yarn.lock |
README.md
Docker Manager
This plugin works with the Discourse docker image. It allows you to perform upgrades via the web UI and monitor activity in the container.
Running tests
- Ruby
- Run
RAILS_ENV=test bin/rails "plugin:spec[docker_manager]"
in your discourse directory
- Run
- JS
- Run
RAILS_ENV=test bin/rails "plugin:qunit[docker_manager]"
in your discourse directory
- Run
Contributing
- Fork it
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create new Pull Request
License
MIT