-
-
Notifications
You must be signed in to change notification settings - Fork 244
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
web UI install missing since 1.0 #215
Comments
@tomzo I think it should be a separate resource. A contribution would be greatly appreciated! |
@tomzo @johnbellone have a look at #216 might help |
@scalp42 I see you added dependency on libartifact_file "consul-ui-#{node['consul']['version']}" do
artifact_name 'consul-ui'
artifact_version node['consul']['version']
owner node['consul']['service_user']
group node['consul']['service_group']
install_path node['ai_consul']['install_path']
remote_checksum node['consul']['checksums']["#{node['consul']['version']}_web_ui"]
remote_url "https://dl.bintray.com/mitchellh/consul/#{node['consul']['version']}_web_ui.zip"
end I plan to move it into consul cookbook as new resource |
I hadn't thought of an attribute in the consul service resource. But I don't want to add a dependency on ark. I personally would probably create a consul ui service resource. |
@johnbellone I have created a However I tried writing a chefspec test in style that you have. require 'spec_helper'
require_relative '../../../libraries/consul_ui'
describe ConsulCookbook::Resource::ConsulUI do
step_into(:consul_ui)
context 'consul ui install' do
recipe do
consul_ui 'myconsul-ui' do
owner 'myconsul'
group 'myconsul'
version '0.5.1'
install_path '/opt'
end
end
it do is_expected.to create_libartifact_file('myconsul-ui')
.with(owner: 'myconsul',group: 'myconsul',
remote_url: "https://dl.bintray.com/mitchellh/consul/0.5.1_web_ui.zip",
install_path: '/opt')
end
end
end But keep getting this error:
Have you had a problem like this here? |
Let me take a look real quick. |
I am going to loop in @coderanger on this one. It looks like it may be possibly due to how the Poise Service library is working in the background. I was able to add a stub method on the I went down the thought path that this was possibly because actions isn't being called (and PoiseService::ServiceMixin is called after |
In general you can't use stuff like ServiceMixin with the fused mode because you need to get the mixin included in the provider and fused mode doesn't expose that you. |
@coderanger this isn't the mixin using fused mode. The library cookbook libartifact has a fused resource which isn't adding a matcher. When we call that resource in this cookbook service provider it fails only it RSpec with the above errors. I tried ditching libartifact fused resource and no luck. It looks like the marchers aren't being added. They are added automatically after 2.2? |
So the specific spec files aren't in git that I can see, but I think this is because you are using normal style cookbooks with the Halite spec helper. The Halite helper doesn't know to load dependent cookbooks because with full-bore Halite stuffs you are using normal |
I can push up the changes, but |
Take a look at spec_helper.rb - I assume that's what you meant @coderanger ? |
So that will get the cookbooks loaded, the next problem is that you need to tell the fake Chef run to actually load that cookbook. If you use the |
That seemed to do it. |
I could do this with |
@tomzo Yup, feel free, you'll need to add it in a |
John, |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
I've been porting my wrapper cookbook to 1.0 of consul. I get an impression that installing UI package is now not supported.
@johnbellone please confirm if this is true. I could contribute it. How would you see it implemented? Do you think it should be another resource or rather an option in
consul_service
?The text was updated successfully, but these errors were encountered: