~andreserl/maas/packaging.fixes

« back to all changes in this revision

Viewing changes to debian/maas-cluster-controller.postinst

  • Committer: Tarmac
  • Author(s): Jeroen Vermeulen
  • Date: 2012-12-13 11:12:37 UTC
  • mfrom: (152.1.1 q-pkg-bug-1089802)
  • Revision ID: tarmac-20121213111237-tbhl5xy2sbd6y4zx
[r=jtv][bug=1089802][author=jtv] Backport packaging r159: Make maas_cluster.conf non-world-readable, now that it contains the cluster UUID.

Show diffs side-by-side

added added

removed removed

Lines of Context:
69
69
if [ "$1" = "configure" ] && [ -z "$2" ]; then
70
70
    # logging
71
71
    create_log_dir
72
 
 
73
 
    # The local celery config may contain a private cluster UUID.  Only
74
 
    # maas can read it; only root can write it.
75
 
    chown root:maas /etc/maas/maas_local_celeryconfig_cluster.py
76
 
    chmod 0640 /etc/maas/maas_local_celeryconfig_cluster.py
77
 
 
78
72
    configure_maas_tgt
79
73
fi
80
74
 
97
91
fi
98
92
 
99
93
if [ "$1" = "configure" ]; then
 
94
    # These config files may contain a private cluster UUID.  Only maas
 
95
    # can read them; only root can write them
 
96
    chown root:maas \
 
97
        /etc/maas/maas_local_celeryconfig_cluster.py \
 
98
        /etc/maas/maas_cluster.conf
 
99
    chmod 0640 \
 
100
        /etc/maas/maas_local_celeryconfig_cluster.py \
 
101
        /etc/maas/maas_cluster.conf
 
102
 
100
103
    configure_cluster_uuid
101
104
fi
102
105