Skip to content

Commit 459d60d

Browse files
author
John Jarvis
committed
lint cleanup, default option changes
1 parent 86ffcb1 commit 459d60d

File tree

1 file changed

+10
-42
lines changed

1 file changed

+10
-42
lines changed

manifests/mount.pp

+10-42
Original file line numberDiff line numberDiff line change
@@ -1,37 +1,6 @@
11
# Class: s3fs::mount
22
#
33
# This module installs s3fs
4-
#
5-
# Parameters:
6-
#
7-
# [*bucket*] - AWS bucket name
8-
# [*mount_point*] - Mountpoint for bucket
9-
# [*ensure*] - Set mountpoint values, ensure dir and mount are absent
10-
# [*s3url*] - 'https://s3.amazonaws.com'
11-
# [*default_acl*] - 'private'
12-
# [*uid*] - Mountpoint and mount dir owner
13-
# [*gid*] - Mountpoint and mount dir group
14-
# [*mode*] - Mountpoint and moutn dir permissions
15-
# [*atboot*] - 'true',
16-
# [*device*] - "s3fs#${bucket}",
17-
# [*fstype*] - 'fuse',
18-
# [*options*] - "allow_other,uid=${uid},gid=${gid},default_acl=${default_acl},use_cache=/tmp/aws_s3_cache,url=${s3url}",
19-
# [*remounts*] - 'false',
20-
#
21-
# Actions:
22-
#
23-
# Requires:
24-
# Class['s3fs']
25-
#
26-
# Sample Usage:
27-
#
28-
# # S3FS
29-
# s3fs::mount {'Testing':
30-
# bucket => 'testvgh1',
31-
# mount_point => '/srv/testvgh1',
32-
# uid => '1001',
33-
# gid => '1001',
34-
# }
354
# ## S3FS
365
# s3fs::mount {'Testvgh':
376
# bucket => 'testvgh',
@@ -40,25 +9,24 @@
409
# }
4110
#
4211
define s3fs::mount (
43-
$bucket = hiera('drupal::s3fs_bucket', 'drupal-stage'),
44-
$mount_point = hiera('drupal::s3fs_mount', '/opt/wwc/drupal-s3-files'),
12+
$bucket,
13+
$mount_point,
4514
$ensure = 'present',
4615
$default_acl = 'private',
47-
$uid = '33',
48-
$gid = '33',
16+
$uid = '0',
17+
$gid = '0',
4918
$mode = '0660',
50-
$atboot = 'true',
19+
$atboot = true,
5120
$fstype = 'fuse',
52-
$remounts = 'false',
21+
$remounts = false,
5322
$cache = '/mnt/aws_s3_cache',
54-
$group = 'www-data',
55-
$owner = 'www-data',
23+
$group = 'root',
24+
$owner = 'root',
5625
) {
5726

5827
include s3fs
59-
Class['s3fs'] -> S3fs::Mount["${name}"]
28+
Class['s3fs'] -> S3fs::Mount[$name]
6029

61-
# Declare this here, otherwise, uid, guid, etc.. are not initialized in the correct order.
6230
$options = "gid=$gid,uid=$uid,default_acl=${default_acl},use_cache=${cache}"
6331
$device = "s3fs#${bucket}"
6432

@@ -76,7 +44,7 @@
7644
}
7745
}
7846

79-
File["${mount_point}"] -> Mount["${mount_point}"]
47+
File[$mount_point] -> Mount[$mount_point]
8048

8149
file { $mount_point:
8250
ensure => $ensure_dir,

0 commit comments

Comments
 (0)