mdsol / mesos_cookbook

Chef cookbook for installing Apache Mesos
Other
78 stars 70 forks source link

added systemd specific changes, we need environment variables in systemd unit, instead of having env vars within the mesos-wrappers #142

Closed sebbrandt87 closed 2 years ago

sebbrandt87 commented 7 years ago

…f having env vars within the mesos-wrappers

sebbrandt87 commented 7 years ago

The environment variables in the mesos-wrapper are not working with systemd. Try it with LIBPROCESS_ anything. It wouldn't be set for the execution of mesos.

robsonpeixoto commented 7 years ago

What do you think about use it https://github.com/poise/poise-service?

rveznaver commented 7 years ago

Well, we use poise-service in https://github.com/mdsol/marathon_cookbook, but somehow I was never really comfortable using it with mesos as I would like to have the minimum amount of dependencies for the cookbook. IMO, I would also like to remove Java (but still not possible because of Mesos packaging).

rveznaver commented 7 years ago

Thanks for the fixes @sebbrandt87, it looks good now. Will try to fix the tests (including kitchen) in the next week and then come back to request a rebase.

sebbrandt87 commented 7 years ago

anything more I could do?

rveznaver commented 7 years ago

Found some time, fixed the apt and yum issue. Could you please rebase?

sebbrandt87 commented 7 years ago

done

sebbrandt87 commented 7 years ago

I really would like to use this cookbook, instead of working and maintaining an own one with the same features. :) Still anything I could do?

sebbrandt87 commented 7 years ago

Any help needed?

rveznaver commented 7 years ago

What do you think about using systemd_unit instead of template in the install recipe and decouple the systemd generation from the env variables?

sebbrandt87 commented 7 years ago

Sure but then: we need to pin the cookbook against chef 12.11

New in Chef Client 12.11. Changed in 12.19 to verify systemd unit-files before installation (using the external systemd-analyze verify command).

What do you mean with decouble from env variables. We need them in the unit file or within an /etc/default/mesos- / /etc/sysconfig/mesos-. We talked about that and some time ago it was decided that we write it into the unit file. :)

Edit: Ah sry it is already pinned against 12.14.x.

rveznaver commented 7 years ago

Was referring to the attributes. In example; for systemd, we could have a separate namespace that would generate a complete unit file, so we would not have any hardcoded fields to get from the env namespace (like ulimit) and we could get rid if the template file for systemd. The only thing left would be to do something like conf['systemd']['Environment'] = conf['env'].join("\n")

sebbrandt87 commented 7 years ago

sure, I can work on this. :)