noshutdown-ru / vault

Is a plugin for project management system Redmine. Allows you to store various passwords/keys in one place for the project.
https://noshutdown.ru/en/redmine-plugins-vault
46 stars 29 forks source link

asset_host (NoMethodError) (Redmine 4.1.1) #70

Closed alterdaemon closed 3 years ago

alterdaemon commented 3 years ago

I am getting this in apache error log, application can't start.

App 6703 output: Error: The application encountered the following error: undefined method assets' for #<Rails::Application::Configuration:0x000055c4772c41d8><br/> App 6703 output: Did you mean? asset_host (NoMethodError)<br/> App 6703 output: /opt/bitnami/apps/redmine/htdocs/vendor/bundle/ruby/2.5.0/gems/railties-5.2.4.2/lib/rails/railtie/configuration.rb:97:in method_missing’

Problem occrus after the config is done in config/initializers/assets.rb

Rails.application.config.assets.precompile += %w( zeroclipboard.js )

alterdaemon commented 3 years ago

when I try to workaround the problem as per https://www.redmine.org/issues/32852

I am getting production.log error

ArgumentError (key must be 16 bytes):

plugins/vault/lib/vault_cipher.rb:22:in `key='
plugins/vault/lib/vault_cipher.rb:22:in `decrypt_text'
plugins/vault/lib/encryptor.rb:11:in `decrypt'
plugins/vault/app/models/vault/password.rb:14:in `decrypt!'
plugins/vault/app/controllers/keys_controller.rb:67:in `map'
plugins/vault/app/controllers/keys_controller.rb:67:in `index'
lib/redmine/sudo_mode.rb:65:in `sudo_mode'
noshutdown-ru-user commented 3 years ago

Yes pls use in plugin settings use encryption key with 16 symbols

noshutdown-ru-user commented 3 years ago

Should be fixed in 0.4.2 version, pull latest master branch version, and retry. delete config/initializers/assets.rb