blob: 7d56ca27ccf9b98dc88450f8c1c1cb8d0277b065 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
|
#coding:utf-8
import time
import sunhpc
class Modules(object):
"""
Configure sunhpc compute node services.
"""
def __init__(self, command):
self.cmd = command
@property
def __help__(self):
info = """
#==============================================================
# %s
#
# module_path: %s
# module_name: %s
#==============================================================
""" % (self.__doc__.strip(), self.__module__.strip(), self.__repr__())
return info
def run(self, args):
#
# self.cmd.ks.makefile
# args:
# text, type:list
# name, type:file path
# mode, owner, perms, expr, quot
#
content = [self.__help__]
# Autofs
autofs_info = """
sed -i 's/mount_nfs_default_protocol = 4/mount_nfs_default_protocol = 3/g' /etc/autofs.conf
"""
content.append(autofs_info)
self.cmd.ks.addPost(content)
def __repr__(self):
return "kickstart-services"
|