-
Notifications
You must be signed in to change notification settings - Fork 210
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Replace opscode from folder names, hardcodes of chef-server.rb, chef-server-running.json, chef-secrets.json #3101
Conversation
👷 Deploy Preview for chef-server processing. 🔨 Explore the source changes: 61f45d2 🔍 Inspect the deploy log: https://app.netlify.com/sites/chef-server/deploys/6216708bbc52e800081668a0 |
@@ -78,11 +81,11 @@ | |||
# The Chef User that services run as | |||
#### | |||
# The username for the chef services user | |||
default['private_chef']['user']['username'] = 'opscode' | |||
default['private_chef']['user']['username'] = ChefUtils::Dist::Org::LEGACY_CONF_DIR |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is a username, but we're using a dirname const. If we want to change the default username, this should have its own const.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@marcparadise Would you like us to add something like ChefUtils::Dist::Server::USERNAME
to chef-utils?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@marcparadise if this works for you - https://github.com/chef/chef/pull/12513/files
At a minimum I think we need to see that the output (it can be snipped) of |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This matches what we have on the Cinc side FWIW ...
@@ -1,7 +1,7 @@ | |||
require "tempfile" | |||
require "veil" | |||
|
|||
secrets_file = ENV['SECRETS_FILE'] || "/etc/opscode/private-chef-secrets.json" | |||
secrets_file = ENV['SECRETS_FILE'] || "/etc/#{ChefUtils::Dist::Org::LEGACY_CONF_DIR}/private-chef-secrets.json" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
secrets_file = ENV['SECRETS_FILE'] || "/etc/#{ChefUtils::Dist::Org::LEGACY_CONF_DIR}/private-chef-secrets.json" | |
secrets_file = ENV['SECRETS_FILE'] || "/etc/#{ChefUtils::Dist::Org::LEGACY_CONF_DIR}/private-#{ChefUtils::Dist::Infra::SHORT}-secrets.json" |
@@ -334,7 +334,7 @@ def gen_api_fqdn | |||
|
|||
# TODO: 2017-02-28 mp: configurable location: | |||
def secrets_json | |||
'/etc/opscode/private-chef-secrets.json' | |||
"/etc/#{ChefUtils::Dist::Org::LEGACY_CONF_DIR}/private-chef-secrets.json" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"/etc/#{ChefUtils::Dist::Org::LEGACY_CONF_DIR}/private-chef-secrets.json" | |
"/etc/#{ChefUtils::Dist::Org::LEGACY_CONF_DIR}/private-#{ChefUtils::Dist::Infra::SHORT}-secrets.json" |
Signed-off-by: Aleksey Hariton <aleksey.hariton@gmail.com>
Pipeline Information - I am going to test this manually in dev VM
|
Maybe that failure will be fixed if we update the Chef gem? The const is present: https://github.com/chef/chef/blob/main/chef-utils/lib/chef-utils/dist.rb#L115 |
Yes, should we go ahead and bump it in this PR or do it in a different PR? The latest 16 release should include the constant ( |
@aleksey-hariton @lbakerchef @marcparadise @jashaik I have created #3205 to replace this PR which should have the final fixes (hopefully). This is created from our shared repo which will make it easier for our group to push any additional fixes to. |
Closing in favor to #3205 |
Replacing Chef trademarks where possible.
Related PR`s:
Description
This changes required to make open-sourcing of ChefServer possible (Cinc project).