File tree Expand file tree Collapse file tree 3 files changed +46
-15
lines changed Expand file tree Collapse file tree 3 files changed +46
-15
lines changed Original file line number Diff line number Diff line change 99#### Public Classes
1010
1111* [ ` python ` ] ( #python ) : Installs and manages python, python-dev and gunicorn.
12+ * [ ` python::install::dev ` ] ( #python--install--dev ) : Installs python development packages
1213* [ ` python::pip::bootstrap ` ] ( #python--pip--bootstrap ) : allow to bootstrap pip when python is managed from other module
1314
1415#### Private Classes
@@ -289,6 +290,10 @@ Data type: `Stdlib::Absolutepath`
289290
290291Default value: ` '/opt/python' `
291292
293+ ### <a name =" python--install--dev " ></a >` python::install::dev `
294+
295+ Installs python development packages
296+
292297### <a name =" python--pip--bootstrap " ></a >` python::pip::bootstrap `
293298
294299allow to bootstrap pip when python is managed from other module
Original file line number Diff line number Diff line change 5454 }
5555
5656 if $python::manage_dev_package and $pythondev {
57- package { 'python-dev' :
58- ensure => $python::dev ,
59- name => $pythondev ,
60- }
57+ include python::install::dev
6158 }
6259
6360 # Respect the $python::pip setting
180177 }
181178
182179 if $python::manage_dev_package and $pythondev {
183- package { 'python-dev' :
184- ensure => $python::dev ,
185- name => $pythondev ,
186- alias => $pythondev ,
187- provider => ' yum' ,
188- }
180+ include python::install::dev
189181 }
190182 }
191183 default: {
197189 }
198190
199191 if $python::manage_dev_package and $pythondev {
200- package { 'python-dev' :
201- ensure => $python::dev ,
202- name => $pythondev ,
203- alias => $pythondev ,
204- }
192+ include python::install::dev
205193 }
206194 }
207195 }
Original file line number Diff line number Diff line change 1+ # @summary Installs python development packages
2+ class python::install::dev {
3+ include python
4+
5+ case $python::provider {
6+ ' pip' : {
7+ package { 'python-dev' :
8+ ensure => $python::dev ,
9+ name => $python::install::pythondev ,
10+ }
11+ }
12+ ' scl' : {
13+ }
14+ ' rhscl' : {
15+ }
16+ ' anaconda' : {
17+ }
18+ default: {
19+ case $facts [' os' ][' family' ] {
20+ ' AIX' : {
21+ package { 'python-dev' :
22+ ensure => $python::dev ,
23+ name => $python::install::pythondev ,
24+ alias => $python::install::pythondev ,
25+ provider => ' yum' ,
26+ }
27+ }
28+ default: {
29+ package { 'python-dev' :
30+ ensure => $python::dev ,
31+ name => $python::install::pythondev ,
32+ alias => $python::install::pythondev ,
33+ }
34+ }
35+ }
36+ }
37+ }
38+ }
You can’t perform that action at this time.
0 commit comments