-
Notifications
You must be signed in to change notification settings - Fork 45
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1155 from SUSE/move-registry-config-engine
Move registry engine config from core config to its engine
- Loading branch information
Showing
5 changed files
with
25 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# :nocov: | ||
module Registry | ||
class Application < Rails::Application | ||
# registry config needed | ||
config.autoloader = :classic | ||
config.registry_private_key = OpenSSL::PKey::RSA.new( | ||
File.read('/etc/rmt/ssl/internal-registry.key') | ||
) | ||
config.registry_public_key = config.registry_private_key.public_key | ||
config.access_policies = '/etc/rmt/access_policies.yml' | ||
end | ||
end | ||
# :nocov: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
# The test environment is used exclusively to run your application's | ||
# test suite. You never need to work with it otherwise. Remember that | ||
# your test database is "scratch space" for the test suite and is wiped | ||
# and recreated between test runs. Don't rely on the data there! | ||
|
||
Rails.application.configure do | ||
config.access_policies = 'engines/registry/spec/data/access_policies.yml' | ||
config.registry_private_key = OpenSSL::PKey::RSA.new(2048) | ||
config.registry_public_key = config.registry_private_key.public_key | ||
config.autoload_paths << Rails.root.join('engines/registry/spec/support/') | ||
end |