File tree 3 files changed +13
-9
lines changed
3 files changed +13
-9
lines changed Original file line number Diff line number Diff line change @@ -50,14 +50,17 @@ A custom username can be passed to the container with the environment variable `
50
50
51
51
A custom password can be passed to the container with the environment variable ` PASS ` .
52
52
53
- # Quotas
53
+ # Quota
54
54
55
- The container supports setting of quota to limit the max size of backups, it defaults to 512GB.
55
+ * BREAKING CHANGE in v2.7* Changing quota to be configured in Gigabytes
56
+
57
+ The container supports setting of quota to limit the max size of backups, it defaults to 1024GB (1TB).
56
58
I'm unclear if this works correctly in modern versions of macOS.
57
59
58
60
The SAMBA setting of ` disk max size ` is also configured to limit the reported size of the disk to the same as the configured quota.
59
61
This is a soft limit not a hard limit.
60
62
63
+
61
64
# Building the Docker image
62
65
63
66
To build the image you need to have docker and docker buildx available, this is included by default in docker desktop
Original file line number Diff line number Diff line change @@ -6,12 +6,13 @@ export PASS="${PASS:-password}"
6
6
export PUID=" ${PUID:- 999} "
7
7
export PGID=" ${PGID:- 999} "
8
8
export LOG_LEVEL=" ${LOG_LEVEL:- 2} "
9
- export QUOTA=" ${QUOTA:- 512000 } "
9
+ export QUOTA=" ${QUOTA:- 1024 } "
10
10
11
11
calculateQuota ()
12
12
{
13
- echo " Quota is ${QUOTA} MB"
14
- export QUOTA_IN_MEGABYTES=" ${QUOTA} "
13
+ echo " Quota is ${QUOTA} GB"
14
+ export QUOTA_IN_GIGABYTES=" ${QUOTA} "
15
+ export QUOTA_IN_MEGABYTES=" $(( QUOTA_IN_GIGABYTES * 1024 )) "
15
16
export QUOTA_IN_BYTES=$(( QUOTA_IN_MEGABYTES * 1024 * 1024 ))
16
17
}
17
18
Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ def compose
12
12
ENV [ 'PGID' ] = '1234'
13
13
ENV [ 'USER' ] = 'testuser'
14
14
ENV [ 'PASS' ] = 'Password123'
15
- ENV [ 'QUOTA' ] = '123456 '
15
+ ENV [ 'QUOTA' ] = '1234 '
16
16
ENV [ 'LOG_LEVEL' ] = '4'
17
17
compose . up ( 'samba-timemachine' , detached : true )
18
18
end
@@ -35,8 +35,8 @@ def compose
35
35
it { should be_file }
36
36
it { should be_mode 644 }
37
37
it { should be_owned_by 'root' }
38
- its ( :content ) { is_expected . to match ( 'max disk size = 123456 ' ) }
39
- its ( :content ) { is_expected . to match ( 'fruit:time machine max size = 123456 MB' ) }
38
+ its ( :content ) { is_expected . to match ( 'max disk size = 1263616 ' ) }
39
+ its ( :content ) { is_expected . to match ( 'fruit:time machine max size = 1263616 MB' ) }
40
40
its ( :content ) { is_expected . to match ( 'log level = 4' ) }
41
41
end
42
42
@@ -60,7 +60,7 @@ def compose
60
60
it { should be_mode 444 }
61
61
it { should be_owned_by 'root' }
62
62
it { should be_grouped_into 'root' }
63
- its ( :content ) { is_expected . to match ( '129452998656 ' ) }
63
+ its ( :content ) { is_expected . to match ( '1324997410816 ' ) }
64
64
end
65
65
66
66
describe group ( 'timemachine' ) do
You can’t perform that action at this time.
0 commit comments