mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2026-10-21 22:12:36 +00:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
19555385f7 | ||
|
|
3b1dc85c6f | ||
|
|
110d5a5233 | ||
|
|
46237ea31a | ||
|
|
60dc450091 | ||
|
|
3df8f96117 | ||
|
|
67b0645808 | ||
|
|
4de060daa6 | ||
|
|
e76105e2ab | ||
|
|
a7887166cf | ||
|
|
5799a20f71 | ||
|
|
077f831749 | ||
|
|
42c849e0df | ||
|
|
9b94177380 | ||
|
|
99abddf376 | ||
|
|
c35660175d | ||
|
|
1cd3b6b4e1 | ||
|
|
10404c4275 | ||
|
|
34742be029 | ||
|
|
5c87fcc6d2 | ||
|
|
fb434318e3 | ||
|
|
5788bf2270 | ||
|
|
fcc09cef6f | ||
|
|
d156d410ef | ||
|
|
eda4c43a08 | ||
|
|
d351541757 | ||
|
|
498661e3bb | ||
|
|
9a00c17555 | ||
|
|
f7a6f6b4c0 | ||
|
|
0da2dfd640 | ||
|
|
3fd4da34a4 | ||
|
|
2422556456 | ||
|
|
6c8caea09c | ||
|
|
47c30e3add | ||
|
|
80db8b13d8 | ||
|
|
67b723f74e | ||
|
|
9f9ef1340c | ||
|
|
c935b9669e | ||
|
|
eb4ad2546f | ||
|
|
41bbf320bb | ||
|
|
982ea85d81 | ||
|
|
083d8e9ece | ||
|
|
e7a6a2733b | ||
|
|
6db49100d6 | ||
|
|
255a1c7dcd | ||
|
|
f77ca41769 | ||
|
|
1d36884845 | ||
|
|
2d1a1f5e03 | ||
|
|
7bf48ee135 | ||
|
|
6de331b014 | ||
|
|
032df784ed | ||
|
|
6ead7758ce | ||
|
|
d264f9449f | ||
|
|
083bf3a137 | ||
|
|
791ad774a2 | ||
|
|
c2aad1c7ff | ||
|
|
b541e39a2c | ||
|
|
2bc6fa90ff | ||
|
|
0ec7bc6710 | ||
|
|
4c1368d621 | ||
|
|
4e73705533 | ||
|
|
08336be92e | ||
|
|
7b78fc72b0 | ||
|
|
b7cd52636b | ||
|
|
3981d65b68 | ||
|
|
9a73319b45 | ||
|
|
b0665a15f4 | ||
|
|
dda6b90d25 | ||
|
|
4b8dcff448 | ||
|
|
b21a67bbe6 | ||
|
|
4fd29dad86 | ||
|
|
bc96682760 | ||
|
|
866c2657f0 | ||
|
|
0cb9036f66 | ||
|
|
a152f17937 | ||
|
|
85c526c583 | ||
|
|
e526a299dc | ||
|
|
182fb9e3ed | ||
|
|
5eacff9d4f | ||
|
|
50ddd8c8e2 | ||
|
|
8329cf86a7 | ||
|
|
7210558c7b | ||
|
|
c63fff9a10 | ||
|
|
bf4d7affc0 | ||
|
|
8dca561bd1 | ||
|
|
f0492ac039 | ||
|
|
d8ffeb4d0e | ||
|
|
560a057941 | ||
|
|
761ffdc405 | ||
|
|
316f326464 | ||
|
|
adfc1e0559 | ||
|
|
969f513265 | ||
|
|
ab0c6a84bf | ||
|
|
34779e8f38 | ||
|
|
c3b73ec23b | ||
|
|
7bf14452f7 | ||
|
|
94e5c0a454 | ||
|
|
a2d3f89c7b | ||
|
|
991a3dca0d | ||
|
|
4f98553ba9 | ||
|
|
2d6fcdf83a | ||
|
|
faf84d8fb6 | ||
|
|
c7abc34dbb | ||
|
|
98251fe16a | ||
|
|
40ee9b4d7b | ||
|
|
2ba08afed1 | ||
|
|
10678cde81 | ||
|
|
4ec8715f20 | ||
|
|
3ac48cd540 | ||
|
|
7f0a97c7b6 | ||
|
|
5ea9715721 | ||
|
|
df9a72b87f | ||
|
|
c7c60d1f8a | ||
|
|
e6c026db65 | ||
|
|
53e2dee177 | ||
|
|
c146c76d10 | ||
|
|
42d97a3442 | ||
|
|
488afa5002 | ||
|
|
73e3e77904 | ||
|
|
59e58c4b23 | ||
|
|
b70cb3e0b2 | ||
|
|
f7229084a9 | ||
|
|
5c3b783310 | ||
|
|
9b0da7cd7d | ||
|
|
83bffca7e6 | ||
|
|
75e4013439 | ||
|
|
ea09fb477a | ||
|
|
689f5513a9 | ||
|
|
7227cfddf5 | ||
|
|
3d7390302d | ||
|
|
2f72c24498 | ||
|
|
88ff8fc27b | ||
|
|
bea26549f2 | ||
|
|
ce2af0082e | ||
|
|
1c9f3c7ac0 | ||
|
|
96c66ca2aa | ||
|
|
f3a334965d | ||
|
|
9ccfc1cfee | ||
|
|
71a94267c9 | ||
|
|
ad16221a35 | ||
|
|
cf1586a34d | ||
|
|
3a19eea97c | ||
|
|
e87f276cf6 | ||
|
|
8805c04128 | ||
|
|
6f95c06bd5 | ||
|
|
ec03f22cc3 | ||
|
|
220797bd71 | ||
|
|
aa1ef02984 | ||
|
|
da1c755f6a | ||
|
|
6c27845be0 | ||
|
|
9e2ae3f3b2 | ||
|
|
01558a0bd5 | ||
|
|
f3c789d662 | ||
|
|
9eebe9b95e | ||
|
|
40abae7caa | ||
|
|
3d87aa767d | ||
|
|
a0ef6e3611 | ||
|
|
791aa3cb44 | ||
|
|
320a08f250 | ||
|
|
100c654ec3 | ||
|
|
947fe4cc97 | ||
|
|
7bf891c00a | ||
|
|
1f75f1f9dc | ||
|
|
3abbaccb70 | ||
|
|
177129013c | ||
|
|
4d388b9782 | ||
|
|
5eb905a5d1 | ||
|
|
043a1337df | ||
|
|
bef9c2943b | ||
|
|
79a1903021 | ||
|
|
12d9108bb4 | ||
|
|
cef2718ede | ||
|
|
9668b15f38 | ||
|
|
563a74a9eb | ||
|
|
dbb8003ce3 | ||
|
|
34240606f7 | ||
|
|
c387fe957b | ||
|
|
835e2d2ddf | ||
|
|
42f4aa824b | ||
|
|
b0b2a03ea7 | ||
|
|
641ce36f6f | ||
|
|
22f75177bf | ||
|
|
c77c0de418 | ||
|
|
a7eee8b14b | ||
|
|
1d4a61af5e | ||
|
|
c683409e92 | ||
|
|
5018b22f36 | ||
|
|
59d1435d65 | ||
|
|
5c99b8acc3 | ||
|
|
00fdab1284 | ||
|
|
4729a57cc0 | ||
|
|
d9dd72ea56 | ||
|
|
73a03cd965 | ||
|
|
5cf332357b | ||
|
|
244841f080 | ||
|
|
6e999f1176 | ||
|
|
a8b0f8864d | ||
|
|
55973e8572 | ||
|
|
c4e22b5a9a | ||
|
|
751a7073e3 | ||
|
|
e0fc2898e9 | ||
|
|
04663c3611 | ||
|
|
330d1fde7f | ||
|
|
12e6692dac | ||
|
|
84bb8e7365 | ||
|
|
4b9c42996a | ||
|
|
5ea86ef1da | ||
|
|
314c32514b | ||
|
|
7348d2ae63 | ||
|
|
00ae965d8d | ||
|
|
b485c905d4 | ||
|
|
77f90ae288 | ||
|
|
35c37562bc | ||
|
|
3c245c69d3 | ||
|
|
6fb6480a3b | ||
|
|
af71ae11aa | ||
|
|
ab97b17e62 | ||
|
|
e66865a8c5 | ||
|
|
0c8dea9de8 | ||
|
|
5160eb08f7 | ||
|
|
18bfbf62fc | ||
|
|
e1ab8b01d0 | ||
|
|
b25661c6df | ||
|
|
1b90d60765 | ||
|
|
794375ca0a | ||
|
|
fc9e246592 | ||
|
|
9cf756b188 | ||
|
|
f17fa400d5 | ||
|
|
006b4ec0f8 | ||
|
|
edbf6d297b | ||
|
|
24858507cc | ||
|
|
f5824f369c | ||
|
|
c857cc7286 | ||
|
|
d04cdcf40d | ||
|
|
b5389c3b23 | ||
|
|
608dc11a28 | ||
|
|
dc3ae5e8a6 | ||
|
|
2afb5a13af | ||
|
|
9e3060bb13 | ||
|
|
2e76834e4d | ||
|
|
54b6e0f3fd | ||
|
|
900e888695 | ||
|
|
6999325d36 | ||
|
|
3eeaffeadd | ||
|
|
d774fa6c9a | ||
|
|
2539ba0b62 | ||
|
|
5f2d7c1589 | ||
|
|
5296c397f4 | ||
|
|
c9d3fb4a30 | ||
|
|
5435027ff0 | ||
|
|
3be3c17f59 | ||
|
|
ee90edd0e3 | ||
|
|
07dd4873db | ||
|
|
235329a92a | ||
|
|
dc7e525cb9 | ||
|
|
0b834600d5 | ||
|
|
c78220a7f2 | ||
|
|
182f43ae5f | ||
|
|
309f46e3af | ||
|
|
cd4fa7561b | ||
|
|
a6bb509cb7 | ||
|
|
825d76622b | ||
|
|
dd2cc1acaf | ||
|
|
8cd7a0365b | ||
|
|
97c963bac9 | ||
|
|
3833dac3f7 | ||
|
|
29fa1b9fdc | ||
|
|
cca62fdb30 | ||
|
|
004e56c1a6 | ||
|
|
71a8c80f6f | ||
|
|
93bb7869b8 | ||
|
|
8e2c9713a3 | ||
|
|
e7d1f183cc | ||
|
|
fc1694b321 | ||
|
|
0ccdb937bb | ||
|
|
b9a2efd69b | ||
|
|
8a124ef9fc | ||
|
|
93624635b4 | ||
|
|
6c704eb2ba | ||
|
|
de7688c539 | ||
|
|
7336990639 | ||
|
|
8965a53c4d | ||
|
|
8e3075d051 | ||
|
|
822ee2475b | ||
|
|
0a7e532fb2 | ||
|
|
94700d65ba | ||
|
|
995a10e516 | ||
|
|
8de7915950 | ||
|
|
5fd4b05c5e | ||
|
|
46a09c6074 | ||
|
|
a23bcbb7ec | ||
|
|
4cbd390fbe | ||
|
|
b693a8d6b9 | ||
|
|
9d6ffa0ea1 | ||
|
|
7700bf62f0 | ||
|
|
458145425e | ||
|
|
de1ec050e8 | ||
|
|
34f764007f | ||
|
|
8e9273db99 | ||
|
|
f0b928ff5e | ||
|
|
3afa451cdc | ||
|
|
b530f12327 | ||
|
|
be4b3ed509 | ||
|
|
0548ed3a1b | ||
|
|
84d2e1bdd0 | ||
|
|
e6ef7b2387 | ||
|
|
4800d0ce26 | ||
|
|
bde2fc65b0 | ||
|
|
3d586be552 | ||
|
|
f4676824a7 | ||
|
|
8205166009 | ||
|
|
3e2acf677c | ||
|
|
bf218cd59d | ||
|
|
5ca0a551ac | ||
|
|
17e08a16f4 | ||
|
|
ce1efeb0eb | ||
|
|
e4830bd93d | ||
|
|
0a856241fe | ||
|
|
d688e10ed1 | ||
|
|
332f5ad3a8 | ||
|
|
f3d8232e14 | ||
|
|
03bb82043c | ||
|
|
2336a397dc | ||
|
|
7584f758b8 | ||
|
|
ed456253d2 | ||
|
|
f14be41439 | ||
|
|
b08fac0014 | ||
|
|
371fead8a5 | ||
|
|
8668d49c9d | ||
|
|
6b31f3c97a | ||
|
|
893f0587b1 | ||
|
|
f0d1e7bd05 | ||
|
|
332d49432d | ||
|
|
96119eab00 | ||
|
|
8a66306064 | ||
|
|
4ed2994555 | ||
|
|
6a030547a2 | ||
|
|
62c2732fd1 | ||
|
|
d4bb16e20e | ||
|
|
947add39e6 | ||
|
|
513fed323a | ||
|
|
280ab7f95c | ||
|
|
04662126bb | ||
|
|
2b9aab3442 | ||
|
|
366f522a2d | ||
|
|
ba7fbac07f | ||
|
|
e6196cdc50 | ||
|
|
a481c4a45e | ||
|
|
3799929830 | ||
|
|
ca04c59ac9 | ||
|
|
1d2dfe593c | ||
|
|
22d8684e88 | ||
|
|
d343b0db57 | ||
|
|
4f50f8c2ca | ||
|
|
69b84bb771 | ||
|
|
57e2fd3f9b | ||
|
|
4c1741fdbb | ||
|
|
b297849147 | ||
|
|
af207bbaf0 | ||
|
|
b6694279d7 | ||
|
|
ec3351a4ec | ||
|
|
1e3fdf366f | ||
|
|
e862b2529a | ||
|
|
88e006bc6d | ||
|
|
5e64b22b45 | ||
|
|
f58ea6a2ee | ||
|
|
0c12a7d12a | ||
|
|
10d6392101 | ||
|
|
41efc6e629 | ||
|
|
7b776be285 | ||
|
|
3b159db143 | ||
|
|
92d65c917c | ||
|
|
3ffbaaa071 | ||
|
|
2cecde89c3 | ||
|
|
fc51ffce2b | ||
|
|
dad88a452f | ||
|
|
4c7a3cf2fd | ||
|
|
adfd79e243 | ||
|
|
a067deaabc | ||
|
|
040443e2d1 | ||
|
|
2e9372dcf7 | ||
|
|
225b019fe0 | ||
|
|
1904448d4e | ||
|
|
5956a8b05a | ||
|
|
aa64f2ac4c | ||
|
|
c4d7ee6c5c | ||
|
|
4a1d4d7462 | ||
|
|
cee4d20bc1 | ||
|
|
ecaab0e048 | ||
|
|
603ea2db73 | ||
|
|
9887610b54 | ||
|
|
2baed2e1e9 | ||
|
|
a814f3f0a8 | ||
|
|
52fe86df45 | ||
|
|
b3d88180ca | ||
|
|
fa7c65bd4b | ||
|
|
84fdda85e7 | ||
|
|
ad5099e570 | ||
|
|
5abdc0be77 | ||
|
|
ede7a65a50 | ||
|
|
c1255d30ad | ||
|
|
eab7cf4bd3 | ||
|
|
59dd271734 | ||
|
|
4cbba2b1c6 | ||
|
|
71175461ef | ||
|
|
e066e2642c | ||
|
|
198fa58e3c | ||
|
|
49d971e602 | ||
|
|
8f2e4be074 | ||
|
|
b751debd31 | ||
|
|
2226c3c8b6 | ||
|
|
94a01fcfcb | ||
|
|
b5f4910412 | ||
|
|
f0907eb83c | ||
|
|
63da4bbb54 | ||
|
|
0c099c1bea | ||
|
|
7a135b7735 | ||
|
|
2789d10342 | ||
|
|
119d5908dd | ||
|
|
7504be58f9 | ||
|
|
96514f0f00 | ||
|
|
20ac710ceb | ||
|
|
6cd1ce8b74 | ||
|
|
f74b29416a | ||
|
|
e9760f261e | ||
|
|
e5fc35ed0c | ||
|
|
1de733fda5 | ||
|
|
2c9d4c8f43 | ||
|
|
e690a2be16 | ||
|
|
232ad2fe65 | ||
|
|
bd1f800efe | ||
|
|
7591336a22 | ||
|
|
8c6ff55226 | ||
|
|
7e600bff5f | ||
|
|
67949e25e9 | ||
|
|
a243d7e047 | ||
|
|
f7f01ac209 | ||
|
|
59cb6146a3 | ||
|
|
5496d68f6a | ||
|
|
2b8ab1534a | ||
|
|
ac574d5572 | ||
|
|
5654d0d60d | ||
|
|
0b4269b6a8 | ||
|
|
0207f5fe9b | ||
|
|
00edcf71fc | ||
|
|
574485ec69 | ||
|
|
0128239c0f | ||
|
|
35c8ea495f | ||
|
|
6a7ed1bd0e | ||
|
|
a0a6aa36fa | ||
|
|
9fdf02bcda | ||
|
|
889a39a24f | ||
|
|
85a2046411 | ||
|
|
9ca7c322b4 | ||
|
|
8c6d706328 | ||
|
|
2954bd71f8 | ||
|
|
ce9e606eb2 | ||
|
|
ee143f9ae0 | ||
|
|
5035b0a109 | ||
|
|
a443e39def | ||
|
|
64971b0d7e | ||
|
|
68b23114b9 | ||
|
|
0c47437ece | ||
|
|
9ec151fa0d | ||
|
|
2b1feb732c | ||
|
|
3adc3da291 | ||
|
|
6923af7280 | ||
|
|
64f6532fbe | ||
|
|
308d4b2dae | ||
|
|
8e4b43a017 | ||
|
|
c218ef20c7 | ||
|
|
1702ce5395 | ||
|
|
fe4794fe92 | ||
|
|
728ed21a80 | ||
|
|
9fb278c92c | ||
|
|
0cda61d539 | ||
|
|
f62df7f695 | ||
|
|
e93d4935e3 | ||
|
|
7a13816e94 | ||
|
|
d5c7dbac4a | ||
|
|
d869a07cd2 | ||
|
|
705285ec60 | ||
|
|
f2de7910fc | ||
|
|
ae98a085d3 | ||
|
|
6022db6d6a | ||
|
|
006c01a519 | ||
|
|
65af3cf4df | ||
|
|
57a95887d2 | ||
|
|
28f45f8fa6 | ||
|
|
c735608685 | ||
|
|
32e94de86a | ||
|
|
60573fd3e2 | ||
|
|
2348e8d8da | ||
|
|
0fe9d2997b | ||
|
|
bdefdee4e6 | ||
|
|
d57d4c5f8f | ||
|
|
98c68d7a79 | ||
|
|
d983aa4c7d | ||
|
|
c5ee03d6af | ||
|
|
cc278a5928 | ||
|
|
16a342eb8a | ||
|
|
796b2eb929 | ||
|
|
53b9b521c9 | ||
|
|
49952ba905 | ||
|
|
99d4594ee8 | ||
|
|
df29281536 | ||
|
|
c3db389e42 | ||
|
|
e9ce099453 | ||
|
|
8707ef00a6 | ||
|
|
13cc2ef723 | ||
|
|
63c84584bb | ||
|
|
4b28c5f6c3 | ||
|
|
da49d25950 | ||
|
|
38f73c8324 | ||
|
|
43d6678d6d | ||
|
|
8ec357b3d3 | ||
|
|
bbc77f7af4 | ||
|
|
cc36f5b01f | ||
|
|
0652805236 | ||
|
|
03a31587ce | ||
|
|
83cd0fc739 | ||
|
|
fbfc90fd1e | ||
|
|
491f7636f8 | ||
|
|
bca4a9de78 | ||
|
|
958125bd02 | ||
|
|
11a496404b | ||
|
|
7f2a8246a9 | ||
|
|
1b942dfa3c | ||
|
|
9a73b0e3c9 | ||
|
|
e281f0fa82 | ||
|
|
24fda6f47f | ||
|
|
7ce97b59d8 | ||
|
|
d1a4e19a3f | ||
|
|
3bd48c4f29 | ||
|
|
3faaa6e360 | ||
|
|
8e125339d5 | ||
|
|
68ea99190f | ||
|
|
43fd11278e | ||
|
|
cca588429b | ||
|
|
0ee208c1a4 | ||
|
|
97b7948cd9 | ||
|
|
c9205458a1 | ||
|
|
1dfcdc53b7 | ||
|
|
701cc133f3 | ||
|
|
8ecd609b48 | ||
|
|
f117f7bf54 | ||
|
|
72d4ff6b28 | ||
|
|
f811fd0903 | ||
|
|
b17b81529e | ||
|
|
e5f9ff983d | ||
|
|
44d0ac95f6 | ||
|
|
18bf556d93 | ||
|
|
21f37a0a75 | ||
|
|
5adfdd7982 | ||
|
|
05f32376eb | ||
|
|
268de45aa5 | ||
|
|
eacaa44dc2 | ||
|
|
6deee4c0b9 | ||
|
|
a31f2907f0 | ||
|
|
001a472057 | ||
|
|
05d2774117 | ||
|
|
975fbc9ee3 | ||
|
|
cd838b1197 | ||
|
|
b7ec879d32 | ||
|
|
aeda4be42c | ||
|
|
7cfaa1a365 | ||
|
|
bfb66b88b1 | ||
|
|
16f0cdc1bf | ||
|
|
1587ce779d | ||
|
|
b686e8c45b | ||
|
|
e2aaa3e2f3 | ||
|
|
ab0ebe1d3b | ||
|
|
4128c1126a | ||
|
|
8b7063634f | ||
|
|
a7383a8a1c | ||
|
|
bec3f63298 | ||
|
|
223c1b3571 | ||
|
|
ccc44059e8 | ||
|
|
8c523d50ad | ||
|
|
65a29ad42a | ||
|
|
a22f37b01c | ||
|
|
a9b41900d8 | ||
|
|
0d8936f6cd | ||
|
|
ff70ba51ac | ||
|
|
dc481c081c | ||
|
|
ca80199ccd | ||
|
|
7b56a6400d | ||
|
|
b1331ba3fe | ||
|
|
6850252e7c | ||
|
|
5a10f27c8d | ||
|
|
46e78e9b3e | ||
|
|
b4de7c09e7 | ||
|
|
b68e76bbac | ||
|
|
7107ded3cd | ||
|
|
e73044f1f0 | ||
|
|
9ac962888c | ||
|
|
ee52f29c33 | ||
|
|
ba45852ca5 | ||
|
|
4f452b71c9 | ||
|
|
3fddbefdb5 | ||
|
|
dded814a62 | ||
|
|
059e88d5df | ||
|
|
9cbb8a14b2 | ||
|
|
1d4e412f93 | ||
|
|
27cf03d031 | ||
|
|
0f85bcaba8 | ||
|
|
d0990651ce | ||
|
|
7be3ab4dc7 | ||
|
|
e2a7399f69 | ||
|
|
6ed2e2a21d | ||
|
|
72ea1a9a21 | ||
|
|
29bc6cb9a2 | ||
|
|
dc936921aa | ||
|
|
9242f3aaeb | ||
|
|
49a8dfb976 | ||
|
|
6a0bb7106b | ||
|
|
05a648bb96 | ||
|
|
c1dc5ab4ac | ||
|
|
318757ef8c | ||
|
|
de8ef28460 | ||
|
|
546efeba8f | ||
|
|
2088f28424 | ||
|
|
c08ac536ed | ||
|
|
9bcf94b2b1 | ||
|
|
a7a914f120 | ||
|
|
2d805beed4 | ||
|
|
c6c97bd83d | ||
|
|
a19c728034 | ||
|
|
19a81d25af | ||
|
|
47d775cf68 | ||
|
|
6bab20d862 | ||
|
|
e9ebe24f2e | ||
|
|
7c39a18ba5 | ||
|
|
a78d0227cd | ||
|
|
12631a3f5b | ||
|
|
95a6e0226d | ||
|
|
7eeff1d8a1 | ||
|
|
93741a6752 | ||
|
|
949ff6475e | ||
|
|
76422cbe35 | ||
|
|
68157f3630 | ||
|
|
2ead7adaff | ||
|
|
00c4e06caa | ||
|
|
f0cc130849 | ||
|
|
2836a58d87 | ||
|
|
188ecc079d | ||
|
|
95e2b83ca5 | ||
|
|
ff7dc3b44c | ||
|
|
ca35a77e85 | ||
|
|
258063de26 | ||
|
|
df1d6133a8 | ||
|
|
3b2c39f1be | ||
|
|
51c8f2518f | ||
|
|
b3e49d2758 | ||
|
|
38c8470d1d | ||
|
|
849f185a20 | ||
|
|
5f6cc9a814 | ||
|
|
2158d4fe4d | ||
|
|
69442d220b | ||
|
|
69c7b7d2a8 | ||
|
|
172da83449 | ||
|
|
01661ec6a7 | ||
|
|
0c360eb6b2 | ||
|
|
1b1ab331f6 | ||
|
|
88d68cad87 | ||
|
|
7720533f84 | ||
|
|
2d237da74a | ||
|
|
ec72547c8d | ||
|
|
05fc7db755 | ||
|
|
02e8f00138 | ||
|
|
c63713774b | ||
|
|
570d2eccec | ||
|
|
605c39ced7 | ||
|
|
ccb3df41f8 | ||
|
|
e64339e8c0 | ||
|
|
223b344c79 | ||
|
|
0e9276b947 | ||
|
|
1f301e4ba4 | ||
|
|
1057d3ac53 | ||
|
|
8461c025ef | ||
|
|
d2c8f01671 | ||
|
|
865b06b7fe | ||
|
|
d24ad92513 | ||
|
|
7bf65c1e99 | ||
|
|
5315fcb820 | ||
|
|
f316de3b5c | ||
|
|
1023bce6f0 | ||
|
|
8109594c6e | ||
|
|
6f9107862f | ||
|
|
48f88f9768 | ||
|
|
d81b20dabb | ||
|
|
e2aa3cf63b | ||
|
|
1f35d32be0 | ||
|
|
40dc283b2d | ||
|
|
72eb6d5b9d | ||
|
|
5a7c40510f | ||
|
|
bb94930196 | ||
|
|
5d5a21ba2d | ||
|
|
c45c12aedc | ||
|
|
507411bdf0 | ||
|
|
c3ffd457ef | ||
|
|
49b5e47bd1 | ||
|
|
fda2fc47b1 | ||
|
|
a539d64896 | ||
|
|
8f7d2d317f | ||
|
|
0b2a92d371 | ||
|
|
27c05f8c0b | ||
|
|
ec989b0377 | ||
|
|
9462f5129a | ||
|
|
3ada61c875 | ||
|
|
c34747c79d | ||
|
|
cb53802752 | ||
|
|
889b143fa7 | ||
|
|
f365af81c2 | ||
|
|
00ffbb4c9a | ||
|
|
53e66980b2 | ||
|
|
9921801e0c | ||
|
|
ba6923b223 | ||
|
|
708debca14 | ||
|
|
0c671885bf | ||
|
|
e2115bfbd2 | ||
|
|
0e9c04417d | ||
|
|
2c38f8738f | ||
|
|
e0c45c24f5 | ||
|
|
c587acf3ee | ||
|
|
561bea954d | ||
|
|
8ea9a2434d | ||
|
|
68b1667272 | ||
|
|
08258a819d | ||
|
|
4909bd9684 | ||
|
|
8126ab4b5d | ||
|
|
0db2517994 | ||
|
|
7937db52e1 | ||
|
|
0c66b173a4 | ||
|
|
e02a317d3d | ||
|
|
2d519c6cb6 | ||
|
|
b961fcd338 | ||
|
|
f4decf02df | ||
|
|
0f7d4556d8 | ||
|
|
333cdce485 | ||
|
|
78e8ddf910 | ||
|
|
a8617c1a39 | ||
|
|
5a0f92423e | ||
|
|
6238644c35 | ||
|
|
d1d1fc772c | ||
|
|
5571f4f70a | ||
|
|
5469019852 | ||
|
|
7667d26ebf | ||
|
|
bfac55e6c0 | ||
|
|
5516fa8e80 | ||
|
|
a51447ffcb | ||
|
|
f0afd35eec | ||
|
|
775dfbae85 | ||
|
|
ec09966fd3 | ||
|
|
5df38d610d | ||
|
|
f2cd753bf9 | ||
|
|
01336d71eb | ||
|
|
1154e23e2d | ||
|
|
057ef429ac | ||
|
|
b63b042afc | ||
|
|
0526db12e2 | ||
|
|
e50a5b8e28 | ||
|
|
db6275a0c8 | ||
|
|
9d85569c55 | ||
|
|
85832d02c0 | ||
|
|
1098ed0d78 | ||
|
|
095f66cd64 | ||
|
|
1c94b3d013 | ||
|
|
e6e57db530 | ||
|
|
f9cf9b93d3 | ||
|
|
8ff6c9a0c6 | ||
|
|
48f448ee09 | ||
|
|
69a6da7969 | ||
|
|
18228f3044 | ||
|
|
e9128e75d0 | ||
|
|
69655ba8e5 | ||
|
|
a7012d9729 | ||
|
|
02f728cb54 | ||
|
|
8d3e275735 | ||
|
|
9096f6f4f7 | ||
|
|
402315f117 | ||
|
|
a6be2520c9 | ||
|
|
713c035a6e | ||
|
|
8cfd487608 | ||
|
|
734c980040 | ||
|
|
96ce85f5ae | ||
|
|
c5f38c365d | ||
|
|
df85f7a1eb | ||
|
|
c0b12da4ef | ||
|
|
52fcce81c6 | ||
|
|
882a93dacd | ||
|
|
7412ccdf88 | ||
|
|
dcf614a8c3 | ||
|
|
eed26af266 | ||
|
|
4370a4db63 | ||
|
|
26c222f596 | ||
|
|
13e45e1605 | ||
|
|
8f5170c138 | ||
|
|
46b0cb8c86 | ||
|
|
de730b079d | ||
|
|
59732a0529 | ||
|
|
d2b3416d1c | ||
|
|
ecb234f75a | ||
|
|
270770d7d7 | ||
|
|
679f800caa | ||
|
|
0c0f77e2ae | ||
|
|
8828f485c0 | ||
|
|
d2b23f3d38 | ||
|
|
e23ca3845b | ||
|
|
286e5dd375 | ||
|
|
1e22166939 | ||
|
|
f3dc909b21 | ||
|
|
e84fad9acf | ||
|
|
1a5d29520c | ||
|
|
6b743dbbf9 | ||
|
|
b9ecf1e3a8 | ||
|
|
d84c311699 | ||
|
|
f6a9ad8001 | ||
|
|
42969c9c62 | ||
|
|
8cf0c515bf | ||
|
|
d2ddf1dbdb | ||
|
|
3afbf04007 | ||
|
|
fe60c6ef9a | ||
|
|
0ca641f33c | ||
|
|
bdc7730fdb | ||
|
|
2ae9705442 | ||
|
|
3739717092 | ||
|
|
f690643b47 | ||
|
|
6de786185d | ||
|
|
3bb640b786 | ||
|
|
02fd913b51 | ||
|
|
9e839cb5cc | ||
|
|
56ee1d5ef1 | ||
|
|
81b255df8b | ||
|
|
58bc3ecf47 | ||
|
|
2ca1839d77 | ||
|
|
89933c46d2 | ||
|
|
1c7e404abe | ||
|
|
cb1dbd3135 | ||
|
|
1161c70dab | ||
|
|
9cc84a910f | ||
|
|
767edd3c08 | ||
|
|
9df7d16791 | ||
|
|
f5a69a0e44 | ||
|
|
6ba65c3382 | ||
|
|
10c11b9fd1 | ||
|
|
5d4438a72f | ||
|
|
1ff8285d82 | ||
|
|
0d6f45cb46 | ||
|
|
a3290faf17 | ||
|
|
c6f992b2a3 | ||
|
|
899963ac20 | ||
|
|
c16e366fb2 | ||
|
|
285fdd2dd5 | ||
|
|
c090d6bb25 | ||
|
|
4deac06da0 | ||
|
|
ddff849ea6 | ||
|
|
5c6270a93a | ||
|
|
035b0bae29 | ||
|
|
1752eeb538 | ||
|
|
4b94b03d90 | ||
|
|
99b599aa8a | ||
|
|
5dede5d38d | ||
|
|
35f70c51b0 | ||
|
|
72eec84167 | ||
|
|
8dccefbba6 | ||
|
|
2b28a818f1 | ||
|
|
10464f47d0 | ||
|
|
7374b5b473 | ||
|
|
2595f269d1 | ||
|
|
ac28611817 | ||
|
|
5c14da0f1e | ||
|
|
4cc2165061 | ||
|
|
10fc478557 | ||
|
|
092932af8f | ||
|
|
bdb632fa62 | ||
|
|
2b46df13f8 | ||
|
|
60f5c0a2f5 | ||
|
|
f3746d350f | ||
|
|
a70e772a03 | ||
|
|
182288f860 | ||
|
|
84d91f143f | ||
|
|
7359193e97 | ||
|
|
cc32436d63 | ||
|
|
67537ff05b | ||
|
|
e0c7708b03 | ||
|
|
41d559f54e | ||
|
|
70effac0d3 | ||
|
|
3138805b33 | ||
|
|
a125c8fbe2 | ||
|
|
b9a67d46c5 | ||
|
|
54c8bc8673 | ||
|
|
7ab389e7ec | ||
|
|
93c37cfded | ||
|
|
b23b307e08 | ||
|
|
b938df97a2 | ||
|
|
450222dd64 | ||
|
|
8dc5def435 | ||
|
|
99155e4880 | ||
|
|
2f209675ab | ||
|
|
fb7a1be1c4 | ||
|
|
3f31c4091a | ||
|
|
2faf96f002 | ||
|
|
4be5b4ff5c | ||
|
|
e95166d739 | ||
|
|
a45bbc0b75 | ||
|
|
f0042f62dd | ||
|
|
18c40686d9 | ||
|
|
5a838dbe53 | ||
|
|
6103649ffb | ||
|
|
49c66e88a0 | ||
|
|
01adc567aa | ||
|
|
297b41266b | ||
|
|
b194f91f47 | ||
|
|
ae7129f717 | ||
|
|
9e48bff8ee | ||
|
|
272c7836c3 | ||
|
|
d013d6d968 | ||
|
|
3d624d1e16 | ||
|
|
ecce300964 | ||
|
|
da7bd62822 | ||
|
|
a6d73e0a66 | ||
|
|
ed57a55eae | ||
|
|
44b50b2fdf | ||
|
|
3df153421d | ||
|
|
30156e142a | ||
|
|
141388367e | ||
|
|
44a2538f67 | ||
|
|
e2da647fa3 | ||
|
|
233103f6b2 | ||
|
|
4ab25fa395 | ||
|
|
5dbbe19c8b | ||
|
|
5bcc77b46c | ||
|
|
f5fa0b08fd | ||
|
|
a024254ad7 | ||
|
|
d39b2689a5 | ||
|
|
3986601ee8 | ||
|
|
fa0dab6029 | ||
|
|
8fe75692ee | ||
|
|
2cb8b31ea7 | ||
|
|
8425705643 | ||
|
|
d8bda0b229 | ||
|
|
53ecae7c7b | ||
|
|
586e066897 | ||
|
|
3d9ec2e0b6 | ||
|
|
1a4db87e19 | ||
|
|
c6d4c16079 | ||
|
|
2420c60fc4 | ||
|
|
067eb15e70 | ||
|
|
b624090398 | ||
|
|
215b169562 | ||
|
|
c795183887 | ||
|
|
30dbe98dff | ||
|
|
07f20155fd | ||
|
|
90badb8201 | ||
|
|
a66112c9d2 | ||
|
|
c8884719ea | ||
|
|
253b4ed898 | ||
|
|
4a0ba3a1a9 | ||
|
|
20d33ae025 | ||
|
|
7566782c2e | ||
|
|
e9eb15e56a | ||
|
|
6f683e6572 | ||
|
|
41db292332 | ||
|
|
3668d10664 | ||
|
|
24e11d1e90 | ||
|
|
fc8dd58aea | ||
|
|
a2979aa051 | ||
|
|
08377fecb8 | ||
|
|
17477b37d5 | ||
|
|
c764596f96 | ||
|
|
cc7714fdbe | ||
|
|
facaa36d22 | ||
|
|
8d70ba2eaa | ||
|
|
1cac2f2278 | ||
|
|
9dd09bbb33 | ||
|
|
c2e0a75c1f | ||
|
|
78b1fb921c | ||
|
|
05af54ad10 | ||
|
|
d5bc87a5da | ||
|
|
d4b0dcf442 | ||
|
|
829b195084 | ||
|
|
d474ce6fe3 | ||
|
|
117f8e0bc1 | ||
|
|
f1d207a0fe | ||
|
|
b3eb4fecc7 | ||
|
|
f24bb9e688 | ||
|
|
88d52adfdd | ||
|
|
56eb522b13 | ||
|
|
055374a50b | ||
|
|
cd59573dd3 | ||
|
|
6aa1a56ec8 | ||
|
|
ebe971da2e | ||
|
|
7a81caa31e | ||
|
|
4d0cbd2700 | ||
|
|
7225cb4ac5 | ||
|
|
28a4a1f8d6 | ||
|
|
1e76fc994a | ||
|
|
ed6aa13520 | ||
|
|
ee6c67682c | ||
|
|
9357911a95 | ||
|
|
b71c3cfba4 | ||
|
|
310e31424e | ||
|
|
8b382a8209 | ||
|
|
33b87244ef | ||
|
|
40a8cb9b0a | ||
|
|
7ce3bee0c0 | ||
|
|
492a91e0b0 | ||
|
|
0e3adde47f | ||
|
|
76f24af79a | ||
|
|
5e6dfbc25f | ||
|
|
97ad3e9d02 | ||
|
|
ff26e64648 | ||
|
|
9524b08bec | ||
|
|
aabea37af1 |
@@ -0,0 +1,4 @@
|
|||||||
|
# These are supported funding model platforms
|
||||||
|
|
||||||
|
github: chrislusf
|
||||||
|
patreon: seaweedfs
|
||||||
@@ -0,0 +1,115 @@
|
|||||||
|
name: "go: build dev binaries"
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches: [ master ]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
|
||||||
|
cleanup:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
steps:
|
||||||
|
|
||||||
|
- name: Delete old release assets
|
||||||
|
uses: mknejp/delete-release-assets@v1
|
||||||
|
with:
|
||||||
|
token: ${{ github.token }}
|
||||||
|
tag: dev
|
||||||
|
fail-if-no-assets: false
|
||||||
|
assets: |
|
||||||
|
weed-*
|
||||||
|
|
||||||
|
build_dev_linux:
|
||||||
|
needs: cleanup
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
goos: [linux]
|
||||||
|
goarch: [amd64]
|
||||||
|
|
||||||
|
steps:
|
||||||
|
|
||||||
|
- name: Check out code into the Go module directory
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
|
||||||
|
- name: Set BUILD_TIME env
|
||||||
|
run: echo BUILD_TIME=$(date -u +%Y%m%d-%H%M) >> ${GITHUB_ENV}
|
||||||
|
|
||||||
|
- name: Go Release Binaries Large Disk
|
||||||
|
uses: wangyoucao577/go-release-action@v1.22
|
||||||
|
with:
|
||||||
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
goos: ${{ matrix.goos }}
|
||||||
|
goarch: ${{ matrix.goarch }}
|
||||||
|
release_tag: dev
|
||||||
|
overwrite: true
|
||||||
|
pre_command: export CGO_ENABLED=0 && export GODEBUG=http2client=0
|
||||||
|
build_flags: -tags 5BytesOffset # optional, default is
|
||||||
|
ldflags: -extldflags -static -X github.com/chrislusf/seaweedfs/weed/util.COMMIT=${{github.sha}}
|
||||||
|
# Where to run `go build .`
|
||||||
|
project_path: weed
|
||||||
|
binary_name: weed-large-disk
|
||||||
|
asset_name: "weed-large-disk-${{ env.BUILD_TIME }}-${{ matrix.goos }}-${{ matrix.goarch }}"
|
||||||
|
|
||||||
|
- name: Go Release Binaries Normal Volume Size
|
||||||
|
uses: wangyoucao577/go-release-action@v1.22
|
||||||
|
with:
|
||||||
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
goos: ${{ matrix.goos }}
|
||||||
|
goarch: ${{ matrix.goarch }}
|
||||||
|
release_tag: dev
|
||||||
|
overwrite: true
|
||||||
|
pre_command: export CGO_ENABLED=0 && export GODEBUG=http2client=0
|
||||||
|
ldflags: -extldflags -static -X github.com/chrislusf/seaweedfs/weed/util.COMMIT=${{github.sha}}
|
||||||
|
# Where to run `go build .`
|
||||||
|
project_path: weed
|
||||||
|
binary_name: weed-normal-disk
|
||||||
|
asset_name: "weed-${{ env.BUILD_TIME }}-${{ matrix.goos }}-${{ matrix.goarch }}"
|
||||||
|
|
||||||
|
build_dev_darwin:
|
||||||
|
needs: build_dev_linux
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
goos: [darwin]
|
||||||
|
goarch: [amd64, arm64]
|
||||||
|
|
||||||
|
steps:
|
||||||
|
|
||||||
|
- name: Check out code into the Go module directory
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
|
||||||
|
- name: Set BUILD_TIME env
|
||||||
|
run: echo BUILD_TIME=$(date -u +%Y%m%d-%H%M) >> ${GITHUB_ENV}
|
||||||
|
|
||||||
|
- name: Go Release Binaries Large Disk
|
||||||
|
uses: wangyoucao577/go-release-action@v1.22
|
||||||
|
with:
|
||||||
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
goos: ${{ matrix.goos }}
|
||||||
|
goarch: ${{ matrix.goarch }}
|
||||||
|
release_tag: dev
|
||||||
|
overwrite: true
|
||||||
|
pre_command: export CGO_ENABLED=0 && export GODEBUG=http2client=0
|
||||||
|
build_flags: -tags 5BytesOffset # optional, default is
|
||||||
|
ldflags: -extldflags -static -X github.com/chrislusf/seaweedfs/weed/util.COMMIT=${{github.sha}}
|
||||||
|
# Where to run `go build .`
|
||||||
|
project_path: weed
|
||||||
|
binary_name: weed-large-disk
|
||||||
|
asset_name: "weed-large-disk-${{ env.BUILD_TIME }}-${{ matrix.goos }}-${{ matrix.goarch }}"
|
||||||
|
|
||||||
|
- name: Go Release Binaries Normal Volume Size
|
||||||
|
uses: wangyoucao577/go-release-action@v1.22
|
||||||
|
with:
|
||||||
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
goos: ${{ matrix.goos }}
|
||||||
|
goarch: ${{ matrix.goarch }}
|
||||||
|
release_tag: dev
|
||||||
|
overwrite: true
|
||||||
|
pre_command: export CGO_ENABLED=0 && export GODEBUG=http2client=0
|
||||||
|
ldflags: -extldflags -static -X github.com/chrislusf/seaweedfs/weed/util.COMMIT=${{github.sha}}
|
||||||
|
# Where to run `go build .`
|
||||||
|
project_path: weed
|
||||||
|
binary_name: weed-normal-disk
|
||||||
|
asset_name: "weed-${{ env.BUILD_TIME }}-${{ matrix.goos }}-${{ matrix.goarch }}"
|
||||||
@@ -0,0 +1,54 @@
|
|||||||
|
# This is a basic workflow to help you get started with Actions
|
||||||
|
|
||||||
|
name: "go: build versioned binaries for windows"
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
tags:
|
||||||
|
- '*'
|
||||||
|
|
||||||
|
# Allows you to run this workflow manually from the Actions tab
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
|
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
|
||||||
|
jobs:
|
||||||
|
|
||||||
|
build-release-binaries_windows:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
goos: [windows]
|
||||||
|
goarch: [amd64]
|
||||||
|
|
||||||
|
# Steps represent a sequence of tasks that will be executed as part of the job
|
||||||
|
steps:
|
||||||
|
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
- name: Go Release Binaries Normal Volume Size
|
||||||
|
uses: wangyoucao577/go-release-action@v1.22
|
||||||
|
with:
|
||||||
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
goos: ${{ matrix.goos }}
|
||||||
|
goarch: ${{ matrix.goarch }}
|
||||||
|
overwrite: true
|
||||||
|
pre_command: export CGO_ENABLED=0 && export GODEBUG=http2client=0
|
||||||
|
# build_flags: -tags 5BytesOffset # optional, default is
|
||||||
|
ldflags: -extldflags -static -X github.com/chrislusf/seaweedfs/weed/util.COMMIT=${{github.sha}}
|
||||||
|
# Where to run `go build .`
|
||||||
|
project_path: weed
|
||||||
|
binary_name: weed
|
||||||
|
asset_name: "${{ matrix.goos }}_${{ matrix.goarch }}"
|
||||||
|
- name: Go Release Large Disk Binaries
|
||||||
|
uses: wangyoucao577/go-release-action@v1.22
|
||||||
|
with:
|
||||||
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
goos: ${{ matrix.goos }}
|
||||||
|
goarch: ${{ matrix.goarch }}
|
||||||
|
overwrite: true
|
||||||
|
pre_command: export CGO_ENABLED=0 && export GODEBUG=http2client=0
|
||||||
|
build_flags: -tags 5BytesOffset # optional, default is
|
||||||
|
ldflags: -extldflags -static -X github.com/chrislusf/seaweedfs/weed/util.COMMIT=${{github.sha}}
|
||||||
|
# Where to run `go build .`
|
||||||
|
project_path: weed
|
||||||
|
binary_name: weed
|
||||||
|
asset_name: "${{ matrix.goos }}_${{ matrix.goarch }}_large_disk"
|
||||||
@@ -0,0 +1,54 @@
|
|||||||
|
# This is a basic workflow to help you get started with Actions
|
||||||
|
|
||||||
|
name: "go: build versioned binaries for linux"
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
tags:
|
||||||
|
- '*'
|
||||||
|
|
||||||
|
# Allows you to run this workflow manually from the Actions tab
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
|
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
|
||||||
|
jobs:
|
||||||
|
|
||||||
|
build-release-binaries_linux:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
goos: [linux]
|
||||||
|
goarch: [amd64, arm, arm64]
|
||||||
|
|
||||||
|
# Steps represent a sequence of tasks that will be executed as part of the job
|
||||||
|
steps:
|
||||||
|
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
- name: Go Release Binaries Normal Volume Size
|
||||||
|
uses: wangyoucao577/go-release-action@v1.22
|
||||||
|
with:
|
||||||
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
goos: ${{ matrix.goos }}
|
||||||
|
goarch: ${{ matrix.goarch }}
|
||||||
|
overwrite: true
|
||||||
|
pre_command: export CGO_ENABLED=0 && export GODEBUG=http2client=0
|
||||||
|
# build_flags: -tags 5BytesOffset # optional, default is
|
||||||
|
ldflags: -extldflags -static -X github.com/chrislusf/seaweedfs/weed/util.COMMIT=${{github.sha}}
|
||||||
|
# Where to run `go build .`
|
||||||
|
project_path: weed
|
||||||
|
binary_name: weed
|
||||||
|
asset_name: "${{ matrix.goos }}_${{ matrix.goarch }}"
|
||||||
|
- name: Go Release Large Disk Binaries
|
||||||
|
uses: wangyoucao577/go-release-action@v1.22
|
||||||
|
with:
|
||||||
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
goos: ${{ matrix.goos }}
|
||||||
|
goarch: ${{ matrix.goarch }}
|
||||||
|
overwrite: true
|
||||||
|
pre_command: export CGO_ENABLED=0 && export GODEBUG=http2client=0
|
||||||
|
build_flags: -tags 5BytesOffset # optional, default is
|
||||||
|
ldflags: -extldflags -static -X github.com/chrislusf/seaweedfs/weed/util.COMMIT=${{github.sha}}
|
||||||
|
# Where to run `go build .`
|
||||||
|
project_path: weed
|
||||||
|
binary_name: weed
|
||||||
|
asset_name: "${{ matrix.goos }}_${{ matrix.goarch }}_large_disk"
|
||||||
@@ -0,0 +1,54 @@
|
|||||||
|
# This is a basic workflow to help you get started with Actions
|
||||||
|
|
||||||
|
name: "go: build versioned binaries for darwin"
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
tags:
|
||||||
|
- '*'
|
||||||
|
|
||||||
|
# Allows you to run this workflow manually from the Actions tab
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
|
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
|
||||||
|
jobs:
|
||||||
|
|
||||||
|
build-release-binaries_darwin:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
goos: [darwin]
|
||||||
|
goarch: [amd64, arm64]
|
||||||
|
|
||||||
|
# Steps represent a sequence of tasks that will be executed as part of the job
|
||||||
|
steps:
|
||||||
|
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
- name: Go Release Binaries Normal Volume Size
|
||||||
|
uses: wangyoucao577/go-release-action@v1.22
|
||||||
|
with:
|
||||||
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
goos: ${{ matrix.goos }}
|
||||||
|
goarch: ${{ matrix.goarch }}
|
||||||
|
overwrite: true
|
||||||
|
pre_command: export CGO_ENABLED=0 && export GODEBUG=http2client=0
|
||||||
|
# build_flags: -tags 5BytesOffset # optional, default is
|
||||||
|
ldflags: -extldflags -static -X github.com/chrislusf/seaweedfs/weed/util.COMMIT=${{github.sha}}
|
||||||
|
# Where to run `go build .`
|
||||||
|
project_path: weed
|
||||||
|
binary_name: weed
|
||||||
|
asset_name: "${{ matrix.goos }}_${{ matrix.goarch }}"
|
||||||
|
- name: Go Release Large Disk Binaries
|
||||||
|
uses: wangyoucao577/go-release-action@v1.22
|
||||||
|
with:
|
||||||
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
goos: ${{ matrix.goos }}
|
||||||
|
goarch: ${{ matrix.goarch }}
|
||||||
|
overwrite: true
|
||||||
|
pre_command: export CGO_ENABLED=0 && export GODEBUG=http2client=0
|
||||||
|
build_flags: -tags 5BytesOffset # optional, default is
|
||||||
|
ldflags: -extldflags -static -X github.com/chrislusf/seaweedfs/weed/util.COMMIT=${{github.sha}}
|
||||||
|
# Where to run `go build .`
|
||||||
|
project_path: weed
|
||||||
|
binary_name: weed
|
||||||
|
asset_name: "${{ matrix.goos }}_${{ matrix.goarch }}_large_disk"
|
||||||
@@ -0,0 +1,54 @@
|
|||||||
|
# This is a basic workflow to help you get started with Actions
|
||||||
|
|
||||||
|
name: "go: build versioned binaries for freebsd"
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
tags:
|
||||||
|
- '*'
|
||||||
|
|
||||||
|
# Allows you to run this workflow manually from the Actions tab
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
|
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
|
||||||
|
jobs:
|
||||||
|
|
||||||
|
build-release-binaries_freebsd:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
goos: [freebsd]
|
||||||
|
goarch: [amd64, arm, arm64]
|
||||||
|
|
||||||
|
# Steps represent a sequence of tasks that will be executed as part of the job
|
||||||
|
steps:
|
||||||
|
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
- name: Go Release Binaries Normal Volume Size
|
||||||
|
uses: wangyoucao577/go-release-action@v1.22
|
||||||
|
with:
|
||||||
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
goos: ${{ matrix.goos }}
|
||||||
|
goarch: ${{ matrix.goarch }}
|
||||||
|
overwrite: true
|
||||||
|
pre_command: export CGO_ENABLED=0 && export GODEBUG=http2client=0
|
||||||
|
# build_flags: -tags 5BytesOffset # optional, default is
|
||||||
|
ldflags: -extldflags -static -X github.com/chrislusf/seaweedfs/weed/util.COMMIT=${{github.sha}}
|
||||||
|
# Where to run `go build .`
|
||||||
|
project_path: weed
|
||||||
|
binary_name: weed
|
||||||
|
asset_name: "${{ matrix.goos }}_${{ matrix.goarch }}"
|
||||||
|
- name: Go Release Large Disk Binaries
|
||||||
|
uses: wangyoucao577/go-release-action@v1.22
|
||||||
|
with:
|
||||||
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
goos: ${{ matrix.goos }}
|
||||||
|
goarch: ${{ matrix.goarch }}
|
||||||
|
overwrite: true
|
||||||
|
pre_command: export CGO_ENABLED=0 && export GODEBUG=http2client=0
|
||||||
|
build_flags: -tags 5BytesOffset # optional, default is
|
||||||
|
ldflags: -extldflags -static -X github.com/chrislusf/seaweedfs/weed/util.COMMIT=${{github.sha}}
|
||||||
|
# Where to run `go build .`
|
||||||
|
project_path: weed
|
||||||
|
binary_name: weed
|
||||||
|
asset_name: "${{ matrix.goos }}_${{ matrix.goarch }}_large_disk"
|
||||||
@@ -1,22 +0,0 @@
|
|||||||
name: Cleanup
|
|
||||||
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
branches: [ master ]
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
|
|
||||||
build:
|
|
||||||
name: Build
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
|
|
||||||
steps:
|
|
||||||
|
|
||||||
- name: Delete old release assets
|
|
||||||
uses: mknejp/delete-release-assets@v1
|
|
||||||
with:
|
|
||||||
token: ${{ github.token }}
|
|
||||||
tag: dev
|
|
||||||
fail-if-no-assets: false
|
|
||||||
assets: |
|
|
||||||
weed-*
|
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
name: "docker: build dev containers"
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches: [ master ]
|
||||||
|
workflow_dispatch: []
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
|
||||||
|
build-dev-containers:
|
||||||
|
runs-on: [ubuntu-latest]
|
||||||
|
|
||||||
|
steps:
|
||||||
|
-
|
||||||
|
name: Checkout
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
-
|
||||||
|
name: Docker meta
|
||||||
|
id: docker_meta
|
||||||
|
uses: docker/metadata-action@v3
|
||||||
|
with:
|
||||||
|
images: |
|
||||||
|
chrislusf/seaweedfs
|
||||||
|
ghcr.io/chrislusf/seaweedfs
|
||||||
|
tags: |
|
||||||
|
type=raw,value=dev
|
||||||
|
labels: |
|
||||||
|
org.opencontainers.image.title=seaweedfs
|
||||||
|
org.opencontainers.image.description=SeaweedFS is a distributed storage system for blobs, objects, files, and data lake, to store and serve billions of files fast!
|
||||||
|
org.opencontainers.image.vendor=Chris Lu
|
||||||
|
-
|
||||||
|
name: Set up QEMU
|
||||||
|
uses: docker/setup-qemu-action@v1
|
||||||
|
-
|
||||||
|
name: Set up Docker Buildx
|
||||||
|
uses: docker/setup-buildx-action@v1
|
||||||
|
with:
|
||||||
|
buildkitd-flags: "--debug"
|
||||||
|
-
|
||||||
|
name: Login to Docker Hub
|
||||||
|
if: github.event_name != 'pull_request'
|
||||||
|
uses: docker/login-action@v1
|
||||||
|
with:
|
||||||
|
username: ${{ secrets.DOCKER_USERNAME }}
|
||||||
|
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||||
|
-
|
||||||
|
name: Login to GHCR
|
||||||
|
if: github.event_name != 'pull_request'
|
||||||
|
uses: docker/login-action@v1
|
||||||
|
with:
|
||||||
|
registry: ghcr.io
|
||||||
|
username: ${{ secrets.GHCR_USERNAME }}
|
||||||
|
password: ${{ secrets.GHCR_TOKEN }}
|
||||||
|
-
|
||||||
|
name: Build
|
||||||
|
uses: docker/build-push-action@v2
|
||||||
|
with:
|
||||||
|
context: ./docker
|
||||||
|
push: ${{ github.event_name != 'pull_request' }}
|
||||||
|
file: ./docker/Dockerfile.go_build
|
||||||
|
platforms: linux/amd64, linux/arm64
|
||||||
|
tags: ${{ steps.docker_meta.outputs.tags }}
|
||||||
|
labels: ${{ steps.docker_meta.outputs.labels }}
|
||||||
@@ -1,13 +1,16 @@
|
|||||||
name: Build Latest Containers
|
name: "docker: build latest container"
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches:
|
tags:
|
||||||
- master
|
- '*'
|
||||||
workflow_dispatch: []
|
workflow_dispatch: []
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build-latest:
|
|
||||||
|
build-latest-container:
|
||||||
runs-on: [ubuntu-latest]
|
runs-on: [ubuntu-latest]
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
-
|
-
|
||||||
name: Checkout
|
name: Checkout
|
||||||
@@ -15,66 +18,13 @@ jobs:
|
|||||||
-
|
-
|
||||||
name: Docker meta
|
name: Docker meta
|
||||||
id: docker_meta
|
id: docker_meta
|
||||||
uses: crazy-max/ghaction-docker-meta@v2
|
uses: docker/metadata-action@v3
|
||||||
with:
|
with:
|
||||||
images: |
|
images: |
|
||||||
chrislusf/seaweedfs
|
chrislusf/seaweedfs
|
||||||
ghcr.io/chrislusf/seaweedfs
|
ghcr.io/chrislusf/seaweedfs
|
||||||
tags: |
|
tags: |
|
||||||
type=raw,value=latest
|
type=raw,value=latest
|
||||||
labels: |
|
|
||||||
org.opencontainers.image.title=seaweedfs
|
|
||||||
org.opencontainers.image.vendor=Chris Lu
|
|
||||||
-
|
|
||||||
name: Set up QEMU
|
|
||||||
uses: docker/setup-qemu-action@v1
|
|
||||||
-
|
|
||||||
name: Set up Docker Buildx
|
|
||||||
uses: docker/setup-buildx-action@v1
|
|
||||||
with:
|
|
||||||
buildkitd-flags: "--debug"
|
|
||||||
-
|
|
||||||
name: Login to Docker Hub
|
|
||||||
if: github.event_name != 'pull_request'
|
|
||||||
uses: docker/login-action@v1
|
|
||||||
with:
|
|
||||||
username: ${{ secrets.DOCKER_USERNAME }}
|
|
||||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
|
||||||
-
|
|
||||||
name: Login to GHCR
|
|
||||||
if: github.event_name != 'pull_request'
|
|
||||||
uses: docker/login-action@v1
|
|
||||||
with:
|
|
||||||
registry: ghcr.io
|
|
||||||
username: ${{ secrets.GHCR_USERNAME }}
|
|
||||||
password: ${{ secrets.GHCR_TOKEN }}
|
|
||||||
-
|
|
||||||
name: Build
|
|
||||||
uses: docker/build-push-action@v2
|
|
||||||
with:
|
|
||||||
context: ./docker
|
|
||||||
push: ${{ github.event_name != 'pull_request' }}
|
|
||||||
file: ./docker/Dockerfile
|
|
||||||
platforms: linux/amd64
|
|
||||||
tags: ${{ steps.docker_meta.outputs.tags }}
|
|
||||||
labels: ${{ steps.docker_meta.outputs.labels }}
|
|
||||||
|
|
||||||
build-dev:
|
|
||||||
runs-on: [ubuntu-latest]
|
|
||||||
steps:
|
|
||||||
-
|
|
||||||
name: Checkout
|
|
||||||
uses: actions/checkout@v2
|
|
||||||
-
|
|
||||||
name: Docker meta
|
|
||||||
id: docker_meta
|
|
||||||
uses: crazy-max/ghaction-docker-meta@v2
|
|
||||||
with:
|
|
||||||
images: |
|
|
||||||
chrislusf/seaweedfs
|
|
||||||
ghcr.io/chrislusf/seaweedfs
|
|
||||||
tags: |
|
|
||||||
type=raw,value=dev
|
|
||||||
labels: |
|
labels: |
|
||||||
org.opencontainers.image.title=seaweedfs
|
org.opencontainers.image.title=seaweedfs
|
||||||
org.opencontainers.image.description=SeaweedFS is a distributed storage system for blobs, objects, files, and data lake, to store and serve billions of files fast!
|
org.opencontainers.image.description=SeaweedFS is a distributed storage system for blobs, objects, files, and data lake, to store and serve billions of files fast!
|
||||||
@@ -109,6 +59,6 @@ jobs:
|
|||||||
context: ./docker
|
context: ./docker
|
||||||
push: ${{ github.event_name != 'pull_request' }}
|
push: ${{ github.event_name != 'pull_request' }}
|
||||||
file: ./docker/Dockerfile.go_build
|
file: ./docker/Dockerfile.go_build
|
||||||
platforms: linux/amd64
|
platforms: linux/amd64, linux/arm, linux/arm64, linux/386
|
||||||
tags: ${{ steps.docker_meta.outputs.tags }}
|
tags: ${{ steps.docker_meta.outputs.tags }}
|
||||||
labels: ${{ steps.docker_meta.outputs.labels }}
|
labels: ${{ steps.docker_meta.outputs.labels }}
|
||||||
|
|||||||
@@ -1,118 +0,0 @@
|
|||||||
name: Build Release Containers
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
tags:
|
|
||||||
- '*'
|
|
||||||
workflow_dispatch: []
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
build-default:
|
|
||||||
runs-on: [ubuntu-latest]
|
|
||||||
steps:
|
|
||||||
-
|
|
||||||
name: Checkout
|
|
||||||
uses: actions/checkout@v2
|
|
||||||
-
|
|
||||||
name: Docker meta
|
|
||||||
id: docker_meta
|
|
||||||
uses: crazy-max/ghaction-docker-meta@v2
|
|
||||||
with:
|
|
||||||
images: |
|
|
||||||
chrislusf/seaweedfs
|
|
||||||
ghcr.io/chrislusf/seaweedfs
|
|
||||||
tags: |
|
|
||||||
type=ref,event=tag
|
|
||||||
flavor: |
|
|
||||||
latest=false
|
|
||||||
labels: |
|
|
||||||
org.opencontainers.image.title=seaweedfs
|
|
||||||
org.opencontainers.image.description=SeaweedFS is a distributed storage system for blobs, objects, files, and data lake, to store and serve billions of files fast!
|
|
||||||
org.opencontainers.image.vendor=Chris Lu
|
|
||||||
-
|
|
||||||
name: Set up QEMU
|
|
||||||
uses: docker/setup-qemu-action@v1
|
|
||||||
-
|
|
||||||
name: Set up Docker Buildx
|
|
||||||
uses: docker/setup-buildx-action@v1
|
|
||||||
with:
|
|
||||||
buildkitd-flags: "--debug"
|
|
||||||
-
|
|
||||||
name: Login to Docker Hub
|
|
||||||
if: github.event_name != 'pull_request'
|
|
||||||
uses: docker/login-action@v1
|
|
||||||
with:
|
|
||||||
username: ${{ secrets.DOCKER_USERNAME }}
|
|
||||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
|
||||||
-
|
|
||||||
name: Login to GHCR
|
|
||||||
if: github.event_name != 'pull_request'
|
|
||||||
uses: docker/login-action@v1
|
|
||||||
with:
|
|
||||||
registry: ghcr.io
|
|
||||||
username: ${{ secrets.GHCR_USERNAME }}
|
|
||||||
password: ${{ secrets.GHCR_TOKEN }}
|
|
||||||
-
|
|
||||||
name: Build
|
|
||||||
uses: docker/build-push-action@v2
|
|
||||||
with:
|
|
||||||
context: ./docker
|
|
||||||
push: ${{ github.event_name != 'pull_request' }}
|
|
||||||
file: ./docker/Dockerfile.go_build
|
|
||||||
platforms: linux/amd64
|
|
||||||
tags: ${{ steps.docker_meta.outputs.tags }}
|
|
||||||
labels: ${{ steps.docker_meta.outputs.labels }}
|
|
||||||
build-large:
|
|
||||||
runs-on: [ubuntu-latest]
|
|
||||||
steps:
|
|
||||||
-
|
|
||||||
name: Checkout
|
|
||||||
uses: actions/checkout@v2
|
|
||||||
-
|
|
||||||
name: Docker meta
|
|
||||||
id: docker_meta
|
|
||||||
uses: crazy-max/ghaction-docker-meta@v2
|
|
||||||
with:
|
|
||||||
images: |
|
|
||||||
chrislusf/seaweedfs
|
|
||||||
ghcr.io/chrislusf/seaweedfs
|
|
||||||
tags: |
|
|
||||||
type=ref,event=tag,suffix=_large_disk
|
|
||||||
flavor: |
|
|
||||||
latest=false
|
|
||||||
labels: |
|
|
||||||
org.opencontainers.image.title=seaweedfs
|
|
||||||
org.opencontainers.image.description=SeaweedFS is a distributed storage system for blobs, objects, files, and data lake, to store and serve billions of files fast!
|
|
||||||
org.opencontainers.image.vendor=Chris Lu
|
|
||||||
-
|
|
||||||
name: Set up QEMU
|
|
||||||
uses: docker/setup-qemu-action@v1
|
|
||||||
-
|
|
||||||
name: Set up Docker Buildx
|
|
||||||
uses: docker/setup-buildx-action@v1
|
|
||||||
with:
|
|
||||||
buildkitd-flags: "--debug"
|
|
||||||
-
|
|
||||||
name: Login to Docker Hub
|
|
||||||
if: github.event_name != 'pull_request'
|
|
||||||
uses: docker/login-action@v1
|
|
||||||
with:
|
|
||||||
username: ${{ secrets.DOCKER_USERNAME }}
|
|
||||||
password: ${{ secrets.DOCKER_PASSWORD }}
|
|
||||||
-
|
|
||||||
name: Login to GHCR
|
|
||||||
if: github.event_name != 'pull_request'
|
|
||||||
uses: docker/login-action@v1
|
|
||||||
with:
|
|
||||||
registry: ghcr.io
|
|
||||||
username: ${{ secrets.GHCR_USERNAME }}
|
|
||||||
password: ${{ secrets.GHCR_TOKEN }}
|
|
||||||
-
|
|
||||||
name: Build
|
|
||||||
uses: docker/build-push-action@v2
|
|
||||||
with:
|
|
||||||
context: ./docker
|
|
||||||
push: ${{ github.event_name != 'pull_request' }}
|
|
||||||
file: ./docker/Dockerfile.go_build_large
|
|
||||||
platforms: linux/amd64
|
|
||||||
tags: ${{ steps.docker_meta.outputs.tags }}
|
|
||||||
labels: ${{ steps.docker_meta.outputs.labels }}
|
|
||||||
@@ -0,0 +1,54 @@
|
|||||||
|
name: "docker: build release containers for normal volume"
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
tags:
|
||||||
|
- '*'
|
||||||
|
workflow_dispatch: []
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build-default-release-container:
|
||||||
|
runs-on: [ubuntu-latest]
|
||||||
|
|
||||||
|
steps:
|
||||||
|
-
|
||||||
|
name: Checkout
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
-
|
||||||
|
name: Docker meta
|
||||||
|
id: docker_meta
|
||||||
|
uses: docker/metadata-action@v3
|
||||||
|
with:
|
||||||
|
images: |
|
||||||
|
chrislusf/seaweedfs
|
||||||
|
tags: |
|
||||||
|
type=ref,event=tag
|
||||||
|
flavor: |
|
||||||
|
latest=false
|
||||||
|
labels: |
|
||||||
|
org.opencontainers.image.title=seaweedfs
|
||||||
|
org.opencontainers.image.description=SeaweedFS is a distributed storage system for blobs, objects, files, and data lake, to store and serve billions of files fast!
|
||||||
|
org.opencontainers.image.vendor=Chris Lu
|
||||||
|
-
|
||||||
|
name: Set up QEMU
|
||||||
|
uses: docker/setup-qemu-action@v1
|
||||||
|
-
|
||||||
|
name: Set up Docker Buildx
|
||||||
|
uses: docker/setup-buildx-action@v1
|
||||||
|
-
|
||||||
|
name: Login to Docker Hub
|
||||||
|
if: github.event_name != 'pull_request'
|
||||||
|
uses: docker/login-action@v1
|
||||||
|
with:
|
||||||
|
username: ${{ secrets.DOCKER_USERNAME }}
|
||||||
|
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||||
|
-
|
||||||
|
name: Build
|
||||||
|
uses: docker/build-push-action@v2
|
||||||
|
with:
|
||||||
|
context: ./docker
|
||||||
|
push: ${{ github.event_name != 'pull_request' }}
|
||||||
|
file: ./docker/Dockerfile.go_build
|
||||||
|
platforms: linux/amd64, linux/arm, linux/arm64, linux/386
|
||||||
|
tags: ${{ steps.docker_meta.outputs.tags }}
|
||||||
|
labels: ${{ steps.docker_meta.outputs.labels }}
|
||||||
@@ -0,0 +1,55 @@
|
|||||||
|
name: "docker: build release containers for large volume"
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
tags:
|
||||||
|
- '*'
|
||||||
|
workflow_dispatch: []
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
|
||||||
|
build-large-release-container:
|
||||||
|
runs-on: [ubuntu-latest]
|
||||||
|
|
||||||
|
steps:
|
||||||
|
-
|
||||||
|
name: Checkout
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
-
|
||||||
|
name: Docker meta
|
||||||
|
id: docker_meta
|
||||||
|
uses: docker/metadata-action@v3
|
||||||
|
with:
|
||||||
|
images: |
|
||||||
|
chrislusf/seaweedfs
|
||||||
|
tags: |
|
||||||
|
type=ref,event=tag,suffix=_large_disk
|
||||||
|
flavor: |
|
||||||
|
latest=false
|
||||||
|
labels: |
|
||||||
|
org.opencontainers.image.title=seaweedfs
|
||||||
|
org.opencontainers.image.description=SeaweedFS is a distributed storage system for blobs, objects, files, and data lake, to store and serve billions of files fast!
|
||||||
|
org.opencontainers.image.vendor=Chris Lu
|
||||||
|
-
|
||||||
|
name: Set up QEMU
|
||||||
|
uses: docker/setup-qemu-action@v1
|
||||||
|
-
|
||||||
|
name: Set up Docker Buildx
|
||||||
|
uses: docker/setup-buildx-action@v1
|
||||||
|
-
|
||||||
|
name: Login to Docker Hub
|
||||||
|
if: github.event_name != 'pull_request'
|
||||||
|
uses: docker/login-action@v1
|
||||||
|
with:
|
||||||
|
username: ${{ secrets.DOCKER_USERNAME }}
|
||||||
|
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||||
|
-
|
||||||
|
name: Build
|
||||||
|
uses: docker/build-push-action@v2
|
||||||
|
with:
|
||||||
|
context: ./docker
|
||||||
|
push: ${{ github.event_name != 'pull_request' }}
|
||||||
|
file: ./docker/Dockerfile.go_build_large
|
||||||
|
platforms: linux/amd64, linux/arm, linux/arm64, linux/386
|
||||||
|
tags: ${{ steps.docker_meta.outputs.tags }}
|
||||||
|
labels: ${{ steps.docker_meta.outputs.labels }}
|
||||||
@@ -0,0 +1,55 @@
|
|||||||
|
name: "docker: build release containers for rocksdb"
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
tags:
|
||||||
|
- '*'
|
||||||
|
workflow_dispatch: []
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
|
||||||
|
build-large-release-container_rocksdb:
|
||||||
|
runs-on: [ubuntu-latest]
|
||||||
|
|
||||||
|
steps:
|
||||||
|
-
|
||||||
|
name: Checkout
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
-
|
||||||
|
name: Docker meta
|
||||||
|
id: docker_meta
|
||||||
|
uses: docker/metadata-action@v3
|
||||||
|
with:
|
||||||
|
images: |
|
||||||
|
chrislusf/seaweedfs
|
||||||
|
tags: |
|
||||||
|
type=ref,event=tag,suffix=_large_disk_rocksdb
|
||||||
|
flavor: |
|
||||||
|
latest=false
|
||||||
|
labels: |
|
||||||
|
org.opencontainers.image.title=seaweedfs
|
||||||
|
org.opencontainers.image.description=SeaweedFS is a distributed storage system for blobs, objects, files, and data lake, to store and serve billions of files fast!
|
||||||
|
org.opencontainers.image.vendor=Chris Lu
|
||||||
|
-
|
||||||
|
name: Set up QEMU
|
||||||
|
uses: docker/setup-qemu-action@v1
|
||||||
|
-
|
||||||
|
name: Set up Docker Buildx
|
||||||
|
uses: docker/setup-buildx-action@v1
|
||||||
|
-
|
||||||
|
name: Login to Docker Hub
|
||||||
|
if: github.event_name != 'pull_request'
|
||||||
|
uses: docker/login-action@v1
|
||||||
|
with:
|
||||||
|
username: ${{ secrets.DOCKER_USERNAME }}
|
||||||
|
password: ${{ secrets.DOCKER_PASSWORD }}
|
||||||
|
-
|
||||||
|
name: Build
|
||||||
|
uses: docker/build-push-action@v2
|
||||||
|
with:
|
||||||
|
context: ./docker
|
||||||
|
push: ${{ github.event_name != 'pull_request' }}
|
||||||
|
file: ./docker/Dockerfile.rocksdb_large
|
||||||
|
platforms: linux/amd64
|
||||||
|
tags: ${{ steps.docker_meta.outputs.tags }}
|
||||||
|
labels: ${{ steps.docker_meta.outputs.labels }}
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
name: Go
|
name: "go: build binary"
|
||||||
|
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
@@ -6,6 +6,10 @@ on:
|
|||||||
pull_request:
|
pull_request:
|
||||||
branches: [ master ]
|
branches: [ master ]
|
||||||
|
|
||||||
|
concurrency:
|
||||||
|
group: ${{ github.head_ref }}/go
|
||||||
|
cancel-in-progress: true
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
|
|
||||||
build:
|
build:
|
||||||
|
|||||||
@@ -1,66 +0,0 @@
|
|||||||
name: Release
|
|
||||||
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
branches: [ master ]
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
|
|
||||||
build:
|
|
||||||
name: Build
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
strategy:
|
|
||||||
matrix:
|
|
||||||
goos: [linux, windows, darwin, freebsd ]
|
|
||||||
goarch: [amd64, arm]
|
|
||||||
exclude:
|
|
||||||
- goarch: arm
|
|
||||||
goos: darwin
|
|
||||||
- goarch: arm
|
|
||||||
goos: windows
|
|
||||||
|
|
||||||
steps:
|
|
||||||
|
|
||||||
- name: Check out code into the Go module directory
|
|
||||||
uses: actions/checkout@v2
|
|
||||||
|
|
||||||
- name: Wait for the deletion
|
|
||||||
uses: jakejarvis/wait-action@master
|
|
||||||
with:
|
|
||||||
time: '30s'
|
|
||||||
|
|
||||||
- name: Set BUILD_TIME env
|
|
||||||
run: echo BUILD_TIME=$(date -u +%Y-%m-%d-%H-%M) >> ${GITHUB_ENV}
|
|
||||||
|
|
||||||
- name: Go Release Binaries
|
|
||||||
uses: wangyoucao577/go-release-action@v1.17
|
|
||||||
with:
|
|
||||||
goversion: 1.16
|
|
||||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
goos: ${{ matrix.goos }}
|
|
||||||
goarch: ${{ matrix.goarch }}
|
|
||||||
release_tag: dev
|
|
||||||
overwrite: true
|
|
||||||
pre_command: export CGO_ENABLED=0
|
|
||||||
build_flags: -tags 5BytesOffset # optional, default is
|
|
||||||
ldflags: -extldflags -static -X github.com/chrislusf/seaweedfs/weed/util.COMMIT=${{github.sha}}
|
|
||||||
# Where to run `go build .`
|
|
||||||
project_path: weed
|
|
||||||
binary_name: weed-large-disk
|
|
||||||
asset_name: "weed-large-disk-${{ env.BUILD_TIME }}-${{ matrix.goos }}-${{ matrix.goarch }}"
|
|
||||||
|
|
||||||
- name: Go Release Binaries
|
|
||||||
uses: wangyoucao577/go-release-action@v1.17
|
|
||||||
with:
|
|
||||||
goversion: 1.16
|
|
||||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
goos: ${{ matrix.goos }}
|
|
||||||
goarch: ${{ matrix.goarch }}
|
|
||||||
release_tag: dev
|
|
||||||
overwrite: true
|
|
||||||
pre_command: export CGO_ENABLED=0
|
|
||||||
ldflags: -extldflags -static -X github.com/chrislusf/seaweedfs/weed/util.COMMIT=${{github.sha}}
|
|
||||||
# Where to run `go build .`
|
|
||||||
project_path: weed
|
|
||||||
binary_name: weed
|
|
||||||
asset_name: "weed-${{ env.BUILD_TIME }}-${{ matrix.goos }}-${{ matrix.goarch }}"
|
|
||||||
-46
@@ -1,46 +0,0 @@
|
|||||||
sudo: false
|
|
||||||
language: go
|
|
||||||
go:
|
|
||||||
- 1.16.x
|
|
||||||
|
|
||||||
before_install:
|
|
||||||
- export PATH=/home/travis/gopath/bin:$PATH
|
|
||||||
|
|
||||||
install:
|
|
||||||
- export CGO_ENABLED="0"
|
|
||||||
- go env
|
|
||||||
|
|
||||||
script:
|
|
||||||
- env GO111MODULE=on go test ./weed/...
|
|
||||||
|
|
||||||
before_deploy:
|
|
||||||
- make release
|
|
||||||
deploy:
|
|
||||||
provider: releases
|
|
||||||
skip_cleanup: true
|
|
||||||
api_key:
|
|
||||||
secure: ERL986+ncQ8lwAJUYDrQ8s2/FxF/cyNIwJIFCqspnWxQgGNNyokET9HapmlPSxjpFRF0q6L2WCg9OY3mSVRq4oI6hg1igOQ12KlLyN71XSJ3c8w0Ay5ho48TQ9l3f3Iu97mntBCe9l0R9pnT8wj1VI8YJxloXwUMG2yeTjA9aBI=
|
|
||||||
file:
|
|
||||||
- build/linux_arm.tar.gz
|
|
||||||
- build/linux_arm64.tar.gz
|
|
||||||
- build/linux_386.tar.gz
|
|
||||||
- build/linux_amd64.tar.gz
|
|
||||||
- build/linux_amd64_large_disk.tar.gz
|
|
||||||
- build/darwin_amd64.tar.gz
|
|
||||||
- build/darwin_amd64_large_disk.tar.gz
|
|
||||||
- build/windows_386.zip
|
|
||||||
- build/windows_amd64.zip
|
|
||||||
- build/windows_amd64_large_disk.zip
|
|
||||||
- build/freebsd_arm.tar.gz
|
|
||||||
- build/freebsd_amd64.tar.gz
|
|
||||||
- build/freebsd_386.tar.gz
|
|
||||||
- build/netbsd_arm.tar.gz
|
|
||||||
- build/netbsd_amd64.tar.gz
|
|
||||||
- build/netbsd_386.tar.gz
|
|
||||||
- build/openbsd_arm.tar.gz
|
|
||||||
- build/openbsd_amd64.tar.gz
|
|
||||||
- build/openbsd_386.tar.gz
|
|
||||||
on:
|
|
||||||
tags: true
|
|
||||||
repo: chrislusf/seaweedfs
|
|
||||||
go: 1.16.x
|
|
||||||
@@ -1,144 +0,0 @@
|
|||||||
BINARY = weed/weed
|
|
||||||
package = github.com/chrislusf/seaweedfs/weed
|
|
||||||
|
|
||||||
GO_FLAGS = #-v
|
|
||||||
SOURCE_DIR = ./weed/
|
|
||||||
|
|
||||||
appname := weed
|
|
||||||
|
|
||||||
sources := $(wildcard *.go)
|
|
||||||
|
|
||||||
COMMIT ?= $(shell git rev-parse --short HEAD)
|
|
||||||
LDFLAGS ?= -X github.com/chrislusf/seaweedfs/weed/util.COMMIT=${COMMIT}
|
|
||||||
|
|
||||||
build = CGO_ENABLED=0 GOOS=$(1) GOARCH=$(2) go build -ldflags "-extldflags -static $(LDFLAGS)" -o build/$(appname)$(3) $(SOURCE_DIR)
|
|
||||||
tar = cd build && tar -cvzf $(1)_$(2).tar.gz $(appname)$(3) && rm $(appname)$(3)
|
|
||||||
zip = cd build && zip $(1)_$(2).zip $(appname)$(3) && rm $(appname)$(3)
|
|
||||||
|
|
||||||
build_large = CGO_ENABLED=0 GOOS=$(1) GOARCH=$(2) go build -tags 5BytesOffset -ldflags "-extldflags -static $(LDFLAGS)" -o build/$(appname)$(3) $(SOURCE_DIR)
|
|
||||||
tar_large = cd build && tar -cvzf $(1)_$(2)_large_disk.tar.gz $(appname)$(3) && rm $(appname)$(3)
|
|
||||||
zip_large = cd build && zip $(1)_$(2)_large_disk.zip $(appname)$(3) && rm $(appname)$(3)
|
|
||||||
|
|
||||||
all: build
|
|
||||||
|
|
||||||
.PHONY : clean deps build linux release windows_build darwin_build linux_build bsd_build clean
|
|
||||||
|
|
||||||
clean:
|
|
||||||
go clean -i $(GO_FLAGS) $(SOURCE_DIR)
|
|
||||||
rm -f $(BINARY)
|
|
||||||
rm -rf build/
|
|
||||||
|
|
||||||
deps:
|
|
||||||
go get $(GO_FLAGS) -d $(SOURCE_DIR)
|
|
||||||
rm -rf /home/travis/gopath/src/github.com/coreos/etcd/vendor/golang.org/x/net/trace
|
|
||||||
rm -rf /home/travis/gopath/src/go.etcd.io/etcd/vendor/golang.org/x/net/trace
|
|
||||||
|
|
||||||
build: deps
|
|
||||||
go build $(GO_FLAGS) -ldflags "$(LDFLAGS)" -o $(BINARY) $(SOURCE_DIR)
|
|
||||||
|
|
||||||
install: deps
|
|
||||||
go install $(GO_FLAGS) -ldflags "$(LDFLAGS)" $(SOURCE_DIR)
|
|
||||||
|
|
||||||
linux: deps
|
|
||||||
mkdir -p linux
|
|
||||||
GOOS=linux GOARCH=amd64 go build $(GO_FLAGS) -ldflags "$(LDFLAGS)" -o linux/$(BINARY) $(SOURCE_DIR)
|
|
||||||
|
|
||||||
release: deps windows_build darwin_build linux_build bsd_build 5_byte_linux_build 5_byte_arm64_build 5_byte_darwin_build 5_byte_windows_build
|
|
||||||
|
|
||||||
##### LINUX BUILDS #####
|
|
||||||
5_byte_linux_build:
|
|
||||||
$(call build_large,linux,amd64,)
|
|
||||||
$(call tar_large,linux,amd64)
|
|
||||||
|
|
||||||
5_byte_darwin_build:
|
|
||||||
$(call build_large,darwin,amd64,)
|
|
||||||
$(call tar_large,darwin,amd64)
|
|
||||||
|
|
||||||
5_byte_windows_build:
|
|
||||||
$(call build_large,windows,amd64,.exe)
|
|
||||||
$(call zip_large,windows,amd64,.exe)
|
|
||||||
|
|
||||||
5_byte_arm_build: $(sources)
|
|
||||||
$(call build_large,linux,arm,)
|
|
||||||
$(call tar_large,linux,arm)
|
|
||||||
|
|
||||||
5_byte_arm64_build: $(sources)
|
|
||||||
$(call build_large,linux,arm64,)
|
|
||||||
$(call tar_large,linux,arm64)
|
|
||||||
|
|
||||||
linux_build: build/linux_arm.tar.gz build/linux_arm64.tar.gz build/linux_386.tar.gz build/linux_amd64.tar.gz
|
|
||||||
|
|
||||||
build/linux_386.tar.gz: $(sources)
|
|
||||||
$(call build,linux,386,)
|
|
||||||
$(call tar,linux,386)
|
|
||||||
|
|
||||||
build/linux_amd64.tar.gz: $(sources)
|
|
||||||
$(call build,linux,amd64,)
|
|
||||||
$(call tar,linux,amd64)
|
|
||||||
|
|
||||||
build/linux_arm.tar.gz: $(sources)
|
|
||||||
$(call build,linux,arm,)
|
|
||||||
$(call tar,linux,arm)
|
|
||||||
|
|
||||||
build/linux_arm64.tar.gz: $(sources)
|
|
||||||
$(call build,linux,arm64,)
|
|
||||||
$(call tar,linux,arm64)
|
|
||||||
|
|
||||||
##### DARWIN (MAC) BUILDS #####
|
|
||||||
darwin_build: build/darwin_amd64.tar.gz
|
|
||||||
|
|
||||||
build/darwin_amd64.tar.gz: $(sources)
|
|
||||||
$(call build,darwin,amd64,)
|
|
||||||
$(call tar,darwin,amd64)
|
|
||||||
|
|
||||||
##### WINDOWS BUILDS #####
|
|
||||||
windows_build: build/windows_386.zip build/windows_amd64.zip
|
|
||||||
|
|
||||||
build/windows_386.zip: $(sources)
|
|
||||||
$(call build,windows,386,.exe)
|
|
||||||
$(call zip,windows,386,.exe)
|
|
||||||
|
|
||||||
build/windows_amd64.zip: $(sources)
|
|
||||||
$(call build,windows,amd64,.exe)
|
|
||||||
$(call zip,windows,amd64,.exe)
|
|
||||||
|
|
||||||
##### BSD BUILDS #####
|
|
||||||
bsd_build: build/freebsd_arm.tar.gz build/freebsd_386.tar.gz build/freebsd_amd64.tar.gz \
|
|
||||||
build/netbsd_arm.tar.gz build/netbsd_386.tar.gz build/netbsd_amd64.tar.gz \
|
|
||||||
build/openbsd_arm.tar.gz build/openbsd_386.tar.gz build/openbsd_amd64.tar.gz
|
|
||||||
|
|
||||||
build/freebsd_386.tar.gz: $(sources)
|
|
||||||
$(call build,freebsd,386,)
|
|
||||||
$(call tar,freebsd,386)
|
|
||||||
|
|
||||||
build/freebsd_amd64.tar.gz: $(sources)
|
|
||||||
$(call build,freebsd,amd64,)
|
|
||||||
$(call tar,freebsd,amd64)
|
|
||||||
|
|
||||||
build/freebsd_arm.tar.gz: $(sources)
|
|
||||||
$(call build,freebsd,arm,)
|
|
||||||
$(call tar,freebsd,arm)
|
|
||||||
|
|
||||||
build/netbsd_386.tar.gz: $(sources)
|
|
||||||
$(call build,netbsd,386,)
|
|
||||||
$(call tar,netbsd,386)
|
|
||||||
|
|
||||||
build/netbsd_amd64.tar.gz: $(sources)
|
|
||||||
$(call build,netbsd,amd64,)
|
|
||||||
$(call tar,netbsd,amd64)
|
|
||||||
|
|
||||||
build/netbsd_arm.tar.gz: $(sources)
|
|
||||||
$(call build,netbsd,arm,)
|
|
||||||
$(call tar,netbsd,arm)
|
|
||||||
|
|
||||||
build/openbsd_386.tar.gz: $(sources)
|
|
||||||
$(call build,openbsd,386,)
|
|
||||||
$(call tar,openbsd,386)
|
|
||||||
|
|
||||||
build/openbsd_amd64.tar.gz: $(sources)
|
|
||||||
$(call build,openbsd,amd64,)
|
|
||||||
$(call tar,openbsd,amd64)
|
|
||||||
|
|
||||||
build/openbsd_arm.tar.gz: $(sources)
|
|
||||||
$(call build,openbsd,arm,)
|
|
||||||
$(call tar,openbsd,arm)
|
|
||||||
@@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
[](https://join.slack.com/t/seaweedfs/shared_invite/enQtMzI4MTMwMjU2MzA3LTEyYzZmZWYzOGQ3MDJlZWMzYmI0OTE4OTJiZjJjODBmMzUxNmYwODg0YjY3MTNlMjBmZDQ1NzQ5NDJhZWI2ZmY)
|
[](https://join.slack.com/t/seaweedfs/shared_invite/enQtMzI4MTMwMjU2MzA3LTEyYzZmZWYzOGQ3MDJlZWMzYmI0OTE4OTJiZjJjODBmMzUxNmYwODg0YjY3MTNlMjBmZDQ1NzQ5NDJhZWI2ZmY)
|
||||||
[](https://twitter.com/intent/follow?screen_name=seaweedfs)
|
[](https://twitter.com/intent/follow?screen_name=seaweedfs)
|
||||||
[](https://travis-ci.org/chrislusf/seaweedfs)
|
[](https://github.com/chrislusf/seaweedfs/actions/workflows/go.yml)
|
||||||
[](https://godoc.org/github.com/chrislusf/seaweedfs/weed)
|
[](https://godoc.org/github.com/chrislusf/seaweedfs/weed)
|
||||||
[](https://github.com/chrislusf/seaweedfs/wiki)
|
[](https://github.com/chrislusf/seaweedfs/wiki)
|
||||||
[](https://hub.docker.com/r/chrislusf/seaweedfs/)
|
[](https://hub.docker.com/r/chrislusf/seaweedfs/)
|
||||||
@@ -69,16 +69,16 @@ Table of Contents
|
|||||||
* [License](#license)
|
* [License](#license)
|
||||||
|
|
||||||
|
|
||||||
|
## Quick Start for S3 API on Docker ##
|
||||||
|
|
||||||
|
`docker run -p 8333:8333 chrislusf/seaweedfs server -s3`
|
||||||
|
|
||||||
## Quick Start with single binary ##
|
## Quick Start with single binary ##
|
||||||
* Download the latest binary from https://github.com/chrislusf/seaweedfs/releases and unzip a single binary file `weed` or `weed.exe`
|
* Download the latest binary from https://github.com/chrislusf/seaweedfs/releases and unzip a single binary file `weed` or `weed.exe`
|
||||||
* Run `weed server -dir=/some/data/dir -s3` to start one master, one volume server, one filer, and one S3 gateway.
|
* Run `weed server -dir=/some/data/dir -s3` to start one master, one volume server, one filer, and one S3 gateway.
|
||||||
|
|
||||||
Also, to increase capacity, just add more volume servers by running `weed volume -dir="/some/data/dir2" -mserver="<master_host>:9333" -port=8081` locally, or on a different machine, or on thousands of machines. That is it!
|
Also, to increase capacity, just add more volume servers by running `weed volume -dir="/some/data/dir2" -mserver="<master_host>:9333" -port=8081` locally, or on a different machine, or on thousands of machines. That is it!
|
||||||
|
|
||||||
## Quick Start for S3 API on Docker ##
|
|
||||||
|
|
||||||
`docker run -p 8333:8333 chrislusf/seaweedfs server -s3`
|
|
||||||
|
|
||||||
## Introduction ##
|
## Introduction ##
|
||||||
|
|
||||||
SeaweedFS is a simple and highly scalable distributed file system. There are two objectives:
|
SeaweedFS is a simple and highly scalable distributed file system. There are two objectives:
|
||||||
@@ -146,6 +146,8 @@ Faster and Cheaper than direct cloud storage!
|
|||||||
* [WebDAV] accesses as a mapped drive on Mac and Windows, or from mobile devices.
|
* [WebDAV] accesses as a mapped drive on Mac and Windows, or from mobile devices.
|
||||||
* [AES256-GCM Encrypted Storage][FilerDataEncryption] safely stores the encrypted data.
|
* [AES256-GCM Encrypted Storage][FilerDataEncryption] safely stores the encrypted data.
|
||||||
* [Super Large Files][SuperLargeFiles] stores large or super large files in tens of TB.
|
* [Super Large Files][SuperLargeFiles] stores large or super large files in tens of TB.
|
||||||
|
* [Cloud Drive][CloudDrive] mounts cloud storage to local cluster, cached for fast read and write with asynchronous write back.
|
||||||
|
* [Gateway to Remote Object Store][GatewayToRemoteObjectStore] mirrors bucket operations to remote object storage, in addition to [Cloud Drive][CloudDrive]
|
||||||
|
|
||||||
## Kubernetes ##
|
## Kubernetes ##
|
||||||
* [Kubernetes CSI Driver][SeaweedFsCsiDriver] A Container Storage Interface (CSI) Driver. [](https://hub.docker.com/r/chrislusf/seaweedfs-csi-driver/)
|
* [Kubernetes CSI Driver][SeaweedFsCsiDriver] A Container Storage Interface (CSI) Driver. [](https://hub.docker.com/r/chrislusf/seaweedfs-csi-driver/)
|
||||||
@@ -168,6 +170,9 @@ Faster and Cheaper than direct cloud storage!
|
|||||||
[ActiveActiveAsyncReplication]: https://github.com/chrislusf/seaweedfs/wiki/Filer-Active-Active-cross-cluster-continuous-synchronization
|
[ActiveActiveAsyncReplication]: https://github.com/chrislusf/seaweedfs/wiki/Filer-Active-Active-cross-cluster-continuous-synchronization
|
||||||
[FilerStoreReplication]: https://github.com/chrislusf/seaweedfs/wiki/Filer-Store-Replication
|
[FilerStoreReplication]: https://github.com/chrislusf/seaweedfs/wiki/Filer-Store-Replication
|
||||||
[KeyLargeValueStore]: https://github.com/chrislusf/seaweedfs/wiki/Filer-as-a-Key-Large-Value-Store
|
[KeyLargeValueStore]: https://github.com/chrislusf/seaweedfs/wiki/Filer-as-a-Key-Large-Value-Store
|
||||||
|
[CloudDrive]: https://github.com/chrislusf/seaweedfs/wiki/Cloud-Drive-Architecture
|
||||||
|
[GatewayToRemoteObjectStore]: https://github.com/chrislusf/seaweedfs/wiki/Gateway-to-Remote-Object-Storage
|
||||||
|
|
||||||
|
|
||||||
[Back to TOC](#table-of-contents)
|
[Back to TOC](#table-of-contents)
|
||||||
|
|
||||||
@@ -321,7 +326,7 @@ When requesting a file key, an optional "dataCenter" parameter can limit the ass
|
|||||||
|
|
||||||
[Back to TOC](#table-of-contents)
|
[Back to TOC](#table-of-contents)
|
||||||
|
|
||||||
## Architecture ##
|
## Object Store Architecture ##
|
||||||
|
|
||||||
Usually distributed file systems split each file into chunks, a central master keeps a mapping of filenames, chunk indices to chunk handles, and also which chunks each chunk server has.
|
Usually distributed file systems split each file into chunks, a central master keeps a mapping of filenames, chunk indices to chunk handles, and also which chunks each chunk server has.
|
||||||
|
|
||||||
@@ -496,7 +501,7 @@ git clone https://github.com/chrislusf/seaweedfs.git
|
|||||||
Step 3: download, compile, and install the project by executing the following command
|
Step 3: download, compile, and install the project by executing the following command
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
make install
|
cd seaweedfs/weed && make install
|
||||||
```
|
```
|
||||||
|
|
||||||
Once this is done, you will find the executable "weed" in your `$GOPATH/bin` directory
|
Once this is done, you will find the executable "weed" in your `$GOPATH/bin` directory
|
||||||
@@ -587,6 +592,7 @@ The text of this page is available for modification and reuse under the terms of
|
|||||||
|
|
||||||
[Back to TOC](#table-of-contents)
|
[Back to TOC](#table-of-contents)
|
||||||
|
|
||||||
## Stargazers over time ##
|
## Stargazers over time
|
||||||
|
|
||||||
|
[](https://starchart.cc/chrislusf/seaweedfs)
|
||||||
|
|
||||||
[](https://starcharts.herokuapp.com/chrislusf/seaweedfs)
|
|
||||||
|
|||||||
+6
-2
@@ -5,12 +5,16 @@
|
|||||||
|
|
||||||
<h2 align="center">Generous Backers ($50+)</h2>
|
<h2 align="center">Generous Backers ($50+)</h2>
|
||||||
|
|
||||||
- [4Sight Imaging](https://www.4sightimaging.com/)
|
|
||||||
- [Evercam Camera Management Software](https://evercam.io/)
|
- [Evercam Camera Management Software](https://evercam.io/)
|
||||||
- [Admiral](https://getadmiral.com)
|
|
||||||
|
|
||||||
<h2 align="center">Backers</h2>
|
<h2 align="center">Backers</h2>
|
||||||
|
|
||||||
- [ColorfulClouds Tech Co. Ltd.](https://caiyunai.com/)
|
- [ColorfulClouds Tech Co. Ltd.](https://caiyunai.com/)
|
||||||
- [Haravan - Ecommerce Platform](https://www.haravan.com)
|
- [Haravan - Ecommerce Platform](https://www.haravan.com)
|
||||||
- PeterCxy - Creator of Shelter App
|
- PeterCxy - Creator of Shelter App
|
||||||
|
- [Hive Games](https://playhive.com/)
|
||||||
|
- Flowm
|
||||||
|
- Yoni Nakache
|
||||||
|
- Catalin Constantin
|
||||||
|
- MingLi Yuan
|
||||||
|
- Leroy van Logchem
|
||||||
|
|||||||
@@ -1,54 +0,0 @@
|
|||||||
FROM alpine
|
|
||||||
|
|
||||||
# 'latest' or 'dev'
|
|
||||||
ARG RELEASE=latest
|
|
||||||
|
|
||||||
RUN \
|
|
||||||
ARCH=$(if [ $(uname -m) == "x86_64" ] && [ $(getconf LONG_BIT) == "64" ]; then echo "amd64"; \
|
|
||||||
elif [ $(uname -m) == "x86_64" ] && [ $(getconf LONG_BIT) == "32" ]; then echo "386"; \
|
|
||||||
elif [ $(uname -m) == "aarch64" ]; then echo "arm64"; \
|
|
||||||
elif [ $(uname -m) == "armv7l" ]; then echo "arm"; \
|
|
||||||
elif [ $(uname -m) == "armv6l" ]; then echo "arm"; fi;) && \
|
|
||||||
echo "Building for $ARCH" 1>&2 && \
|
|
||||||
SUPERCRONIC_SHA1SUM=$(echo $ARCH | sed 's/386/e0126b0102b9f388ecd55714358e3ad60d0cebdb/g' | sed 's/amd64/5ddf8ea26b56d4a7ff6faecdd8966610d5cb9d85/g' | sed 's/arm64/e2714c43e7781bf1579c85aa61259245f56dbba1/g' | sed 's/arm/47481c3341bc3a1ae91a728e0cc63c8e6d3791ad/g') && \
|
|
||||||
SUPERCRONIC_URL=https://github.com/aptible/supercronic/releases/download/v0.1.9/supercronic-linux-$ARCH && \
|
|
||||||
SUPERCRONIC=supercronic-linux-$ARCH && \
|
|
||||||
# Install SeaweedFS and Supercronic ( for cron job mode )
|
|
||||||
apk add --no-cache --virtual build-dependencies --update wget curl ca-certificates && \
|
|
||||||
apk add fuse && \
|
|
||||||
wget -P /tmp https://github.com/$(curl -s -L https://github.com/chrislusf/seaweedfs/releases/${RELEASE} | egrep -o "chrislusf/seaweedfs/releases/download/.*/linux_$ARCH.tar.gz") && \
|
|
||||||
tar -C /usr/bin/ -xzvf /tmp/linux_$ARCH.tar.gz && \
|
|
||||||
curl -fsSLO "$SUPERCRONIC_URL" && \
|
|
||||||
echo "${SUPERCRONIC_SHA1SUM} ${SUPERCRONIC}" | sha1sum -c - && \
|
|
||||||
chmod +x "$SUPERCRONIC" && \
|
|
||||||
mv "$SUPERCRONIC" "/usr/local/bin/${SUPERCRONIC}" && \
|
|
||||||
ln -s "/usr/local/bin/${SUPERCRONIC}" /usr/local/bin/supercronic && \
|
|
||||||
apk del build-dependencies && \
|
|
||||||
rm -rf /tmp/*
|
|
||||||
|
|
||||||
# volume server gprc port
|
|
||||||
EXPOSE 18080
|
|
||||||
# volume server http port
|
|
||||||
EXPOSE 8080
|
|
||||||
# filer server gprc port
|
|
||||||
EXPOSE 18888
|
|
||||||
# filer server http port
|
|
||||||
EXPOSE 8888
|
|
||||||
# master server shared gprc port
|
|
||||||
EXPOSE 19333
|
|
||||||
# master server shared http port
|
|
||||||
EXPOSE 9333
|
|
||||||
# s3 server http port
|
|
||||||
EXPOSE 8333
|
|
||||||
# webdav server http port
|
|
||||||
EXPOSE 7333
|
|
||||||
|
|
||||||
RUN mkdir -p /data/filerldb2
|
|
||||||
|
|
||||||
VOLUME /data
|
|
||||||
|
|
||||||
COPY filer.toml /etc/seaweedfs/filer.toml
|
|
||||||
COPY entrypoint.sh /entrypoint.sh
|
|
||||||
RUN chmod +x /entrypoint.sh
|
|
||||||
|
|
||||||
ENTRYPOINT ["/entrypoint.sh"]
|
|
||||||
@@ -0,0 +1,44 @@
|
|||||||
|
FROM gcc:11 as builder
|
||||||
|
RUN mkdir -p /go/src/github.com/chrislusf/
|
||||||
|
RUN git clone https://github.com/chrislusf/seaweedfs /go/src/github.com/chrislusf/seaweedfs
|
||||||
|
ARG BRANCH=${BRANCH:-master}
|
||||||
|
RUN cd /go/src/github.com/chrislusf/seaweedfs && git checkout $BRANCH
|
||||||
|
RUN cd /go/src/github.com/chrislusf/seaweedfs/weed \
|
||||||
|
&& apt-get update \
|
||||||
|
&& apt-get install -y golang-src \
|
||||||
|
&& export LDFLAGS="-X github.com/chrislusf/seaweedfs/weed/util.COMMIT=$(git rev-parse --short HEAD)" \
|
||||||
|
&& CGO_ENABLED=0 go install -ldflags "-extldflags -static ${LDFLAGS}" -compiler=gccgo -tags gccgo,noasm
|
||||||
|
|
||||||
|
FROM alpine AS final
|
||||||
|
LABEL author="Chris Lu"
|
||||||
|
COPY --from=builder /go/bin/weed /usr/bin/
|
||||||
|
RUN mkdir -p /etc/seaweedfs
|
||||||
|
COPY --from=builder /go/src/github.com/chrislusf/seaweedfs/docker/filer.toml /etc/seaweedfs/filer.toml
|
||||||
|
COPY --from=builder /go/src/github.com/chrislusf/seaweedfs/docker/entrypoint.sh /entrypoint.sh
|
||||||
|
RUN apk add fuse # for weed mount
|
||||||
|
|
||||||
|
# volume server gprc port
|
||||||
|
EXPOSE 18080
|
||||||
|
# volume server http port
|
||||||
|
EXPOSE 8080
|
||||||
|
# filer server gprc port
|
||||||
|
EXPOSE 18888
|
||||||
|
# filer server http port
|
||||||
|
EXPOSE 8888
|
||||||
|
# master server shared gprc port
|
||||||
|
EXPOSE 19333
|
||||||
|
# master server shared http port
|
||||||
|
EXPOSE 9333
|
||||||
|
# s3 server http port
|
||||||
|
EXPOSE 8333
|
||||||
|
# webdav server http port
|
||||||
|
EXPOSE 7333
|
||||||
|
|
||||||
|
RUN mkdir -p /data/filerldb2
|
||||||
|
|
||||||
|
VOLUME /data
|
||||||
|
WORKDIR /data
|
||||||
|
|
||||||
|
RUN chmod +x /entrypoint.sh
|
||||||
|
|
||||||
|
ENTRYPOINT ["/entrypoint.sh"]
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
FROM amd64/golang:1.16-alpine as builder
|
FROM golang:1.17-alpine as builder
|
||||||
RUN apk add git g++ fuse
|
RUN apk add git g++ fuse
|
||||||
RUN mkdir -p /go/src/github.com/chrislusf/
|
RUN mkdir -p /go/src/github.com/chrislusf/
|
||||||
RUN git clone https://github.com/chrislusf/seaweedfs /go/src/github.com/chrislusf/seaweedfs
|
RUN git clone https://github.com/chrislusf/seaweedfs /go/src/github.com/chrislusf/seaweedfs
|
||||||
@@ -36,6 +36,7 @@ EXPOSE 7333
|
|||||||
RUN mkdir -p /data/filerldb2
|
RUN mkdir -p /data/filerldb2
|
||||||
|
|
||||||
VOLUME /data
|
VOLUME /data
|
||||||
|
WORKDIR /data
|
||||||
|
|
||||||
RUN chmod +x /entrypoint.sh
|
RUN chmod +x /entrypoint.sh
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
FROM amd64/golang:1.16-alpine as builder
|
FROM golang:1.17-alpine as builder
|
||||||
RUN apk add git g++ fuse
|
RUN apk add git g++ fuse
|
||||||
RUN mkdir -p /go/src/github.com/chrislusf/
|
RUN mkdir -p /go/src/github.com/chrislusf/
|
||||||
RUN git clone https://github.com/chrislusf/seaweedfs /go/src/github.com/chrislusf/seaweedfs
|
RUN git clone https://github.com/chrislusf/seaweedfs /go/src/github.com/chrislusf/seaweedfs
|
||||||
@@ -36,6 +36,7 @@ EXPOSE 7333
|
|||||||
RUN mkdir -p /data/filerldb2
|
RUN mkdir -p /data/filerldb2
|
||||||
|
|
||||||
VOLUME /data
|
VOLUME /data
|
||||||
|
WORKDIR /data
|
||||||
|
|
||||||
RUN chmod +x /entrypoint.sh
|
RUN chmod +x /entrypoint.sh
|
||||||
|
|
||||||
|
|||||||
@@ -26,6 +26,7 @@ EXPOSE 7333
|
|||||||
RUN mkdir -p /data/filerldb2
|
RUN mkdir -p /data/filerldb2
|
||||||
|
|
||||||
VOLUME /data
|
VOLUME /data
|
||||||
|
WORKDIR /data
|
||||||
|
|
||||||
RUN chmod +x /entrypoint.sh
|
RUN chmod +x /entrypoint.sh
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,61 @@
|
|||||||
|
FROM golang:1.17-buster as builder
|
||||||
|
|
||||||
|
RUN apt-get update
|
||||||
|
RUN apt-get install -y build-essential libsnappy-dev zlib1g-dev libbz2-dev libgflags-dev liblz4-dev libzstd-dev
|
||||||
|
|
||||||
|
ENV ROCKSDB_VERSION v6.22.1
|
||||||
|
|
||||||
|
# build RocksDB
|
||||||
|
RUN cd /tmp && \
|
||||||
|
git clone https://github.com/facebook/rocksdb.git /tmp/rocksdb --depth 1 --single-branch --branch $ROCKSDB_VERSION && \
|
||||||
|
cd rocksdb && \
|
||||||
|
make static_lib && \
|
||||||
|
make install-static
|
||||||
|
|
||||||
|
ENV CGO_CFLAGS "-I/tmp/rocksdb/include"
|
||||||
|
ENV CGO_LDFLAGS "-L/tmp/rocksdb -lrocksdb -lstdc++ -lm -lz -lbz2 -lsnappy -llz4 -lzstd"
|
||||||
|
|
||||||
|
# build SeaweedFS
|
||||||
|
RUN mkdir -p /go/src/github.com/chrislusf/
|
||||||
|
RUN git clone https://github.com/chrislusf/seaweedfs /go/src/github.com/chrislusf/seaweedfs
|
||||||
|
ARG BRANCH=${BRANCH:-master}
|
||||||
|
RUN cd /go/src/github.com/chrislusf/seaweedfs && git checkout $BRANCH
|
||||||
|
RUN cd /go/src/github.com/chrislusf/seaweedfs/weed \
|
||||||
|
&& export LDFLAGS="-X github.com/chrislusf/seaweedfs/weed/util.COMMIT=$(git rev-parse --short HEAD)" \
|
||||||
|
&& go install -tags "5BytesOffset rocksdb" -ldflags "-extldflags -static ${LDFLAGS}"
|
||||||
|
|
||||||
|
|
||||||
|
FROM alpine AS final
|
||||||
|
LABEL author="Chris Lu"
|
||||||
|
COPY --from=builder /go/bin/weed /usr/bin/
|
||||||
|
RUN mkdir -p /etc/seaweedfs
|
||||||
|
COPY --from=builder /go/src/github.com/chrislusf/seaweedfs/docker/filer.toml /etc/seaweedfs/filer.toml
|
||||||
|
COPY --from=builder /go/src/github.com/chrislusf/seaweedfs/docker/entrypoint.sh /entrypoint.sh
|
||||||
|
RUN apk add fuse snappy gflags
|
||||||
|
|
||||||
|
# volume server gprc port
|
||||||
|
EXPOSE 18080
|
||||||
|
# volume server http port
|
||||||
|
EXPOSE 8080
|
||||||
|
# filer server gprc port
|
||||||
|
EXPOSE 18888
|
||||||
|
# filer server http port
|
||||||
|
EXPOSE 8888
|
||||||
|
# master server shared gprc port
|
||||||
|
EXPOSE 19333
|
||||||
|
# master server shared http port
|
||||||
|
EXPOSE 9333
|
||||||
|
# s3 server http port
|
||||||
|
EXPOSE 8333
|
||||||
|
# webdav server http port
|
||||||
|
EXPOSE 7333
|
||||||
|
|
||||||
|
RUN mkdir -p /data/filerldb2
|
||||||
|
|
||||||
|
VOLUME /data
|
||||||
|
|
||||||
|
WORKDIR /data
|
||||||
|
|
||||||
|
RUN chmod +x /entrypoint.sh
|
||||||
|
|
||||||
|
ENTRYPOINT ["/entrypoint.sh"]
|
||||||
@@ -13,6 +13,12 @@ build: binary
|
|||||||
docker build --no-cache -t chrislusf/seaweedfs:local -f Dockerfile.local .
|
docker build --no-cache -t chrislusf/seaweedfs:local -f Dockerfile.local .
|
||||||
rm ./weed
|
rm ./weed
|
||||||
|
|
||||||
|
build_gorocksdb:
|
||||||
|
docker build --no-cache -t chrislusf/gorocksdb -f Dockerfile.go_rocksdb .
|
||||||
|
|
||||||
|
build_rocksdb:
|
||||||
|
docker build --no-cache -t chrislusf/seaweedfs:rocksdb -f Dockerfile.rocksdb_large .
|
||||||
|
|
||||||
s3tests_build:
|
s3tests_build:
|
||||||
docker build --no-cache -t chrislusf/ceph-s3-tests:local -f Dockerfile.s3tests .
|
docker build --no-cache -t chrislusf/ceph-s3-tests:local -f Dockerfile.s3tests .
|
||||||
|
|
||||||
@@ -25,6 +31,9 @@ dev_tls: build certstrap
|
|||||||
dev_mount: build
|
dev_mount: build
|
||||||
docker-compose -f compose/local-mount-compose.yml -p seaweedfs up
|
docker-compose -f compose/local-mount-compose.yml -p seaweedfs up
|
||||||
|
|
||||||
|
run_image: build
|
||||||
|
docker run --rm -ti --device /dev/fuse --cap-add SYS_ADMIN --entrypoint /bin/sh chrislusf/seaweedfs:local
|
||||||
|
|
||||||
profile_mount: build
|
profile_mount: build
|
||||||
docker-compose -f compose/local-mount-profile-compose.yml -p seaweedfs up
|
docker-compose -f compose/local-mount-profile-compose.yml -p seaweedfs up
|
||||||
|
|
||||||
@@ -37,6 +46,9 @@ dev_registry: build
|
|||||||
dev_replicate: build
|
dev_replicate: build
|
||||||
docker-compose -f compose/local-replicate-compose.yml -p seaweedfs up
|
docker-compose -f compose/local-replicate-compose.yml -p seaweedfs up
|
||||||
|
|
||||||
|
dev_auditlog: build
|
||||||
|
docker-compose -f compose/local-auditlog-compose.yml -p seaweedfs up
|
||||||
|
|
||||||
cluster: build
|
cluster: build
|
||||||
docker-compose -f compose/local-cluster-compose.yml -p seaweedfs up
|
docker-compose -f compose/local-cluster-compose.yml -p seaweedfs up
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,4 @@
|
|||||||
|
{
|
||||||
|
"fluent_port": 24224,
|
||||||
|
"fluent_host": "fluent"
|
||||||
|
}
|
||||||
@@ -0,0 +1,36 @@
|
|||||||
|
version: '2'
|
||||||
|
|
||||||
|
services:
|
||||||
|
s3:
|
||||||
|
image: chrislusf/seaweedfs:local
|
||||||
|
ports:
|
||||||
|
- 8333:8333
|
||||||
|
- 9333:9333
|
||||||
|
- 19333:19333
|
||||||
|
- 8084:8080
|
||||||
|
- 18084:18080
|
||||||
|
- 8888:8888
|
||||||
|
- 18888:18888
|
||||||
|
- 8000:8000
|
||||||
|
command: "server -ip=s3 -filer -s3 -s3.config=/etc/seaweedfs/s3.json -s3.port=8000 -s3.auditLogConfig=/etc/seaweedfs/fluent.json -volume.max=0 -master.volumeSizeLimitMB=8 -volume.preStopSeconds=1"
|
||||||
|
volumes:
|
||||||
|
- ./fluent.json:/etc/seaweedfs/fluent.json
|
||||||
|
- ./s3.json:/etc/seaweedfs/s3.json
|
||||||
|
depends_on:
|
||||||
|
- fluent
|
||||||
|
fluent:
|
||||||
|
image: fluent/fluentd:v1.14
|
||||||
|
ports:
|
||||||
|
- 24224:24224
|
||||||
|
#s3tests:
|
||||||
|
# image: chrislusf/ceph-s3-tests:local
|
||||||
|
# volumes:
|
||||||
|
# - ./s3tests.conf:/opt/s3-tests/s3tests.conf
|
||||||
|
# environment:
|
||||||
|
# S3TEST_CONF: "s3tests.conf"
|
||||||
|
# NOSETESTS_OPTIONS: "--verbose --logging-level=ERROR --with-xunit --failure-detail s3tests_boto3.functional.test_s3"
|
||||||
|
# NOSETESTS_ATTR: "!tagging,!fails_on_aws,!encryption,!bucket-policy,!versioning,!fails_on_rgw,!bucket-policy,!fails_with_subdomain,!policy_status,!object-lock,!lifecycle,!cors,!user-policy"
|
||||||
|
# NOSETESTS_EXCLUDE: "(get_bucket_encryption|put_bucket_encryption|bucket_list_delimiter_basic|bucket_listv2_delimiter_basic|bucket_listv2_encoding_basic|bucket_list_encoding_basic|bucket_list_delimiter_prefix|bucket_listv2_delimiter_prefix_ends_with_delimiter|bucket_list_delimiter_prefix_ends_with_delimiter|bucket_list_delimiter_alt|bucket_listv2_delimiter_alt|bucket_list_delimiter_prefix_underscore|bucket_list_delimiter_percentage|bucket_listv2_delimiter_percentage|bucket_list_delimiter_whitespace|bucket_listv2_delimiter_whitespace|bucket_list_delimiter_dot|bucket_listv2_delimiter_dot|bucket_list_delimiter_unreadable|bucket_listv2_delimiter_unreadable|bucket_listv2_fetchowner_defaultempty|bucket_listv2_fetchowner_empty|bucket_list_prefix_delimiter_alt|bucket_listv2_prefix_delimiter_alt|bucket_list_prefix_delimiter_prefix_not_exist|bucket_listv2_prefix_delimiter_prefix_not_exist|bucket_list_prefix_delimiter_delimiter_not_exist|bucket_listv2_prefix_delimiter_delimiter_not_exist|bucket_list_prefix_delimiter_prefix_delimiter_not_exist|bucket_listv2_prefix_delimiter_prefix_delimiter_not_exist|bucket_list_maxkeys_none|bucket_listv2_maxkeys_none|bucket_list_maxkeys_invalid|bucket_listv2_continuationtoken_empty|bucket_list_return_data|bucket_list_objects_anonymous|bucket_listv2_objects_anonymous|bucket_notexist|bucketv2_notexist|bucket_delete_nonempty|bucket_concurrent_set_canned_acl|object_write_to_nonexist_bucket|object_requestid_matches_header_on_error|object_set_get_metadata_none_to_good|object_set_get_metadata_none_to_empty|object_set_get_metadata_overwrite_to_empty|post_object_anonymous_request|post_object_authenticated_request|post_object_authenticated_no_content_type|post_object_authenticated_request_bad_access_key|post_object_set_success_code|post_object_set_invalid_success_code|post_object_upload_larger_than_chunk|post_object_set_key_from_filename|post_object_ignored_header|post_object_case_insensitive_condition_fields|post_object_escaped_field_values|post_object_success_redirect_action|post_object_invalid_signature|post_object_invalid_access_key|post_object_missing_policy_condition|post_object_user_specified_header|post_object_request_missing_policy_specified_field|post_object_expired_policy|post_object_invalid_request_field_value|get_object_ifunmodifiedsince_good|put_object_ifmatch_failed|object_raw_get_bucket_gone|object_delete_key_bucket_gone|object_raw_get_bucket_acl|object_raw_get_object_acl|object_raw_response_headers|object_raw_authenticated_bucket_gone|object_raw_get_x_amz_expires_out_max_range|object_raw_get_x_amz_expires_out_positive_range|object_anon_put_write_access|object_raw_put_authenticated_expired|bucket_create_exists|bucket_create_naming_bad_short_one|bucket_create_naming_bad_short_two|bucket_get_location|bucket_acl_default|bucket_acl_canned|bucket_acl_canned_publicreadwrite|bucket_acl_canned_authenticatedread|object_acl_default|object_acl_canned_during_create|object_acl_canned|object_acl_canned_publicreadwrite|object_acl_canned_authenticatedread|object_acl_canned_bucketownerread|object_acl_canned_bucketownerfullcontrol|object_acl_full_control_verify_attributes|bucket_acl_canned_private_to_private|bucket_acl_grant_nonexist_user|bucket_acl_no_grants|bucket_acl_grant_email_not_exist|bucket_acl_revoke_all|bucket_recreate_not_overriding|object_copy_verify_contenttype|object_copy_to_itself_with_metadata|object_copy_not_owned_bucket|object_copy_not_owned_object_bucket|object_copy_retaining_metadata|object_copy_replacing_metadata|multipart_upload_empty|multipart_copy_invalid_range|multipart_copy_special_names|multipart_upload_resend_part|multipart_upload_size_too_small|abort_multipart_upload_not_found|multipart_upload_missing_part|multipart_upload_incorrect_etag|100_continue|ranged_request_invalid_range|ranged_request_empty_object|access_bucket)"
|
||||||
|
# depends_on:
|
||||||
|
# - s3
|
||||||
|
# - fluent
|
||||||
@@ -6,25 +6,37 @@ services:
|
|||||||
ports:
|
ports:
|
||||||
- 9333:9333
|
- 9333:9333
|
||||||
- 19333:19333
|
- 19333:19333
|
||||||
command: "master -ip=master0 -port=9333 -peers=master0:9333,master1:9334,master2:9335 -mdir=/data/m1"
|
command: "-v=1 master -volumeSizeLimitMB 100 -resumeState=false -ip=master0 -port=9333 -peers=master0:9333,master1:9334,master2:9335 -mdir=/tmp"
|
||||||
|
environment:
|
||||||
|
WEED_MASTER_VOLUME_GROWTH_COPY_1: 1
|
||||||
|
WEED_MASTER_VOLUME_GROWTH_COPY_2: 2
|
||||||
|
WEED_MASTER_VOLUME_GROWTH_COPY_OTHER: 1
|
||||||
master1:
|
master1:
|
||||||
image: chrislusf/seaweedfs:local
|
image: chrislusf/seaweedfs:local
|
||||||
ports:
|
ports:
|
||||||
- 9334:9334
|
- 9334:9334
|
||||||
- 19334:19334
|
- 19334:19334
|
||||||
command: "master -ip=master1 -port=9334 -peers=master0:9333,master1:9334,master2:9335 -mdir=/data/m2"
|
command: "-v=1 master -volumeSizeLimitMB 100 -resumeState=false -ip=master1 -port=9334 -peers=master0:9333,master1:9334,master2:9335 -mdir=/tmp"
|
||||||
|
environment:
|
||||||
|
WEED_MASTER_VOLUME_GROWTH_COPY_1: 1
|
||||||
|
WEED_MASTER_VOLUME_GROWTH_COPY_2: 2
|
||||||
|
WEED_MASTER_VOLUME_GROWTH_COPY_OTHER: 1
|
||||||
master2:
|
master2:
|
||||||
image: chrislusf/seaweedfs:local
|
image: chrislusf/seaweedfs:local
|
||||||
ports:
|
ports:
|
||||||
- 9335:9335
|
- 9335:9335
|
||||||
- 19335:19335
|
- 19335:19335
|
||||||
command: "master -ip=master2 -port=9335 -peers=master0:9333,master1:9334,master2:9335 -mdir=/data/m3"
|
command: "-v=1 master -volumeSizeLimitMB 100 -resumeState=false -ip=master2 -port=9335 -peers=master0:9333,master1:9334,master2:9335 -mdir=/tmp"
|
||||||
|
environment:
|
||||||
|
WEED_MASTER_VOLUME_GROWTH_COPY_1: 1
|
||||||
|
WEED_MASTER_VOLUME_GROWTH_COPY_2: 2
|
||||||
|
WEED_MASTER_VOLUME_GROWTH_COPY_OTHER: 1
|
||||||
volume1:
|
volume1:
|
||||||
image: chrislusf/seaweedfs:local
|
image: chrislusf/seaweedfs:local
|
||||||
ports:
|
ports:
|
||||||
- 8080:8080
|
- 8080:8080
|
||||||
- 18080:18080
|
- 18080:18080
|
||||||
command: 'volume -mserver="master0:9333,master1:9334,master2:9335" -port=8080 -ip=volume1 -publicUrl=localhost:8080 -preStopSeconds=1 -disk=ssd1'
|
command: 'volume -dataCenter dc1 -rack v1 -mserver="master0:9333,master1:9334,master2:9335" -port=8080 -ip=volume1 -publicUrl=localhost:8080 -preStopSeconds=1'
|
||||||
depends_on:
|
depends_on:
|
||||||
- master0
|
- master0
|
||||||
- master1
|
- master1
|
||||||
@@ -34,7 +46,7 @@ services:
|
|||||||
ports:
|
ports:
|
||||||
- 8082:8082
|
- 8082:8082
|
||||||
- 18082:18082
|
- 18082:18082
|
||||||
command: 'volume -mserver="master0:9333,master1:9334,master2:9335" -port=8082 -ip=volume2 -publicUrl=localhost:8082 -preStopSeconds=1 -disk=ssd1'
|
command: 'volume -dataCenter dc2 -rack v2 -mserver="master0:9333,master1:9334,master2:9335" -port=8082 -ip=volume2 -publicUrl=localhost:8082 -preStopSeconds=1'
|
||||||
depends_on:
|
depends_on:
|
||||||
- master0
|
- master0
|
||||||
- master1
|
- master1
|
||||||
@@ -44,7 +56,7 @@ services:
|
|||||||
ports:
|
ports:
|
||||||
- 8083:8083
|
- 8083:8083
|
||||||
- 18083:18083
|
- 18083:18083
|
||||||
command: 'volume -mserver="master0:9333,master1:9334,master2:9335" -port=8083 -ip=volume3 -publicUrl=localhost:8083 -preStopSeconds=1'
|
command: 'volume -dataCenter dc3 -rack v3 -mserver="master0:9333,master1:9334,master2:9335" -port=8083 -ip=volume3 -publicUrl=localhost:8083 -preStopSeconds=1'
|
||||||
depends_on:
|
depends_on:
|
||||||
- master0
|
- master0
|
||||||
- master1
|
- master1
|
||||||
@@ -54,7 +66,8 @@ services:
|
|||||||
ports:
|
ports:
|
||||||
- 8888:8888
|
- 8888:8888
|
||||||
- 18888:18888
|
- 18888:18888
|
||||||
command: 'filer -master="master0:9333,master1:9334,master2:9335"'
|
- 8111:8111
|
||||||
|
command: 'filer -defaultReplicaPlacement 100 -iam -master="master0:9333,master1:9334,master2:9335"'
|
||||||
depends_on:
|
depends_on:
|
||||||
- master0
|
- master0
|
||||||
- master1
|
- master1
|
||||||
@@ -65,11 +78,11 @@ services:
|
|||||||
image: chrislusf/seaweedfs:local
|
image: chrislusf/seaweedfs:local
|
||||||
ports:
|
ports:
|
||||||
- 8333:8333
|
- 8333:8333
|
||||||
command: 's3 -filer="filer:8888"'
|
command: '-v=9 s3 -filer="filer:8888"'
|
||||||
depends_on:
|
depends_on:
|
||||||
- master0
|
- master0
|
||||||
- master1
|
- master1
|
||||||
- master2
|
- master2
|
||||||
- volume1
|
- volume1
|
||||||
- volume2
|
- volume2
|
||||||
- filer
|
- filer
|
||||||
@@ -38,7 +38,7 @@ services:
|
|||||||
S3TEST_CONF: "s3tests.conf"
|
S3TEST_CONF: "s3tests.conf"
|
||||||
NOSETESTS_OPTIONS: "--verbose --logging-level=ERROR --with-xunit --failure-detail s3tests_boto3.functional.test_s3"
|
NOSETESTS_OPTIONS: "--verbose --logging-level=ERROR --with-xunit --failure-detail s3tests_boto3.functional.test_s3"
|
||||||
NOSETESTS_ATTR: "!tagging,!fails_on_aws,!encryption,!bucket-policy,!versioning,!fails_on_rgw,!bucket-policy,!fails_with_subdomain,!policy_status,!object-lock,!lifecycle,!cors,!user-policy"
|
NOSETESTS_ATTR: "!tagging,!fails_on_aws,!encryption,!bucket-policy,!versioning,!fails_on_rgw,!bucket-policy,!fails_with_subdomain,!policy_status,!object-lock,!lifecycle,!cors,!user-policy"
|
||||||
NOSETESTS_EXCLUDE: "(bucket_list_delimiter_basic|bucket_listv2_delimiter_basic|bucket_listv2_encoding_basic|bucket_list_encoding_basic|bucket_list_delimiter_prefix|bucket_listv2_delimiter_prefix_ends_with_delimiter|bucket_list_delimiter_prefix_ends_with_delimiter|bucket_list_delimiter_alt|bucket_listv2_delimiter_alt|bucket_list_delimiter_prefix_underscore|bucket_list_delimiter_percentage|bucket_listv2_delimiter_percentage|bucket_list_delimiter_whitespace|bucket_listv2_delimiter_whitespace|bucket_list_delimiter_dot|bucket_listv2_delimiter_dot|bucket_list_delimiter_unreadable|bucket_listv2_delimiter_unreadable|bucket_listv2_fetchowner_defaultempty|bucket_listv2_fetchowner_empty|bucket_list_prefix_delimiter_alt|bucket_listv2_prefix_delimiter_alt|bucket_list_prefix_delimiter_prefix_not_exist|bucket_listv2_prefix_delimiter_prefix_not_exist|bucket_list_prefix_delimiter_delimiter_not_exist|bucket_listv2_prefix_delimiter_delimiter_not_exist|bucket_list_prefix_delimiter_prefix_delimiter_not_exist|bucket_listv2_prefix_delimiter_prefix_delimiter_not_exist|bucket_list_maxkeys_none|bucket_listv2_maxkeys_none|bucket_list_maxkeys_invalid|bucket_listv2_continuationtoken_empty|bucket_list_return_data|bucket_list_objects_anonymous|bucket_listv2_objects_anonymous|bucket_notexist|bucketv2_notexist|bucket_delete_nonempty|bucket_concurrent_set_canned_acl|object_write_to_nonexist_bucket|object_requestid_matches_header_on_error|object_set_get_metadata_none_to_good|object_set_get_metadata_none_to_empty|object_set_get_metadata_overwrite_to_empty|post_object_anonymous_request|post_object_authenticated_request|post_object_authenticated_no_content_type|post_object_authenticated_request_bad_access_key|post_object_set_success_code|post_object_set_invalid_success_code|post_object_upload_larger_than_chunk|post_object_set_key_from_filename|post_object_ignored_header|post_object_case_insensitive_condition_fields|post_object_escaped_field_values|post_object_success_redirect_action|post_object_invalid_signature|post_object_invalid_access_key|post_object_missing_policy_condition|post_object_user_specified_header|post_object_request_missing_policy_specified_field|post_object_expired_policy|post_object_invalid_request_field_value|get_object_ifunmodifiedsince_good|put_object_ifmatch_failed|object_raw_get_bucket_gone|object_delete_key_bucket_gone|object_raw_get_bucket_acl|object_raw_get_object_acl|object_raw_response_headers|object_raw_authenticated_bucket_gone|object_raw_get_x_amz_expires_out_max_range|object_raw_get_x_amz_expires_out_positive_range|object_anon_put_write_access|object_raw_put_authenticated_expired|bucket_create_exists|bucket_create_naming_bad_short_one|bucket_create_naming_bad_short_two|bucket_get_location|bucket_acl_default|bucket_acl_canned|bucket_acl_canned_publicreadwrite|bucket_acl_canned_authenticatedread|object_acl_default|object_acl_canned_during_create|object_acl_canned|object_acl_canned_publicreadwrite|object_acl_canned_authenticatedread|object_acl_canned_bucketownerread|object_acl_canned_bucketownerfullcontrol|object_acl_full_control_verify_attributes|bucket_acl_canned_private_to_private|bucket_acl_grant_nonexist_user|bucket_acl_no_grants|bucket_acl_grant_email_not_exist|bucket_acl_revoke_all|bucket_recreate_not_overriding|object_copy_verify_contenttype|object_copy_to_itself_with_metadata|object_copy_not_owned_bucket|object_copy_not_owned_object_bucket|object_copy_retaining_metadata|object_copy_replacing_metadata|multipart_upload_empty|multipart_copy_invalid_range|multipart_copy_special_names|multipart_upload_resend_part|multipart_upload_size_too_small|abort_multipart_upload_not_found|multipart_upload_missing_part|multipart_upload_incorrect_etag|100_continue|ranged_request_invalid_range|ranged_request_empty_object|access_bucket)"
|
NOSETESTS_EXCLUDE: "(get_bucket_encryption|put_bucket_encryption|bucket_list_delimiter_basic|bucket_listv2_delimiter_basic|bucket_listv2_encoding_basic|bucket_list_encoding_basic|bucket_list_delimiter_prefix|bucket_listv2_delimiter_prefix_ends_with_delimiter|bucket_list_delimiter_prefix_ends_with_delimiter|bucket_list_delimiter_alt|bucket_listv2_delimiter_alt|bucket_list_delimiter_prefix_underscore|bucket_list_delimiter_percentage|bucket_listv2_delimiter_percentage|bucket_list_delimiter_whitespace|bucket_listv2_delimiter_whitespace|bucket_list_delimiter_dot|bucket_listv2_delimiter_dot|bucket_list_delimiter_unreadable|bucket_listv2_delimiter_unreadable|bucket_listv2_fetchowner_defaultempty|bucket_listv2_fetchowner_empty|bucket_list_prefix_delimiter_alt|bucket_listv2_prefix_delimiter_alt|bucket_list_prefix_delimiter_prefix_not_exist|bucket_listv2_prefix_delimiter_prefix_not_exist|bucket_list_prefix_delimiter_delimiter_not_exist|bucket_listv2_prefix_delimiter_delimiter_not_exist|bucket_list_prefix_delimiter_prefix_delimiter_not_exist|bucket_listv2_prefix_delimiter_prefix_delimiter_not_exist|bucket_list_maxkeys_none|bucket_listv2_maxkeys_none|bucket_list_maxkeys_invalid|bucket_listv2_continuationtoken_empty|bucket_list_return_data|bucket_list_objects_anonymous|bucket_listv2_objects_anonymous|bucket_notexist|bucketv2_notexist|bucket_delete_nonempty|bucket_concurrent_set_canned_acl|object_write_to_nonexist_bucket|object_requestid_matches_header_on_error|object_set_get_metadata_none_to_good|object_set_get_metadata_none_to_empty|object_set_get_metadata_overwrite_to_empty|post_object_anonymous_request|post_object_authenticated_request|post_object_authenticated_no_content_type|post_object_authenticated_request_bad_access_key|post_object_set_success_code|post_object_set_invalid_success_code|post_object_upload_larger_than_chunk|post_object_set_key_from_filename|post_object_ignored_header|post_object_case_insensitive_condition_fields|post_object_escaped_field_values|post_object_success_redirect_action|post_object_invalid_signature|post_object_invalid_access_key|post_object_missing_policy_condition|post_object_user_specified_header|post_object_request_missing_policy_specified_field|post_object_expired_policy|post_object_invalid_request_field_value|get_object_ifunmodifiedsince_good|put_object_ifmatch_failed|object_raw_get_bucket_gone|object_delete_key_bucket_gone|object_raw_get_bucket_acl|object_raw_get_object_acl|object_raw_response_headers|object_raw_authenticated_bucket_gone|object_raw_get_x_amz_expires_out_max_range|object_raw_get_x_amz_expires_out_positive_range|object_anon_put_write_access|object_raw_put_authenticated_expired|bucket_create_exists|bucket_create_naming_bad_short_one|bucket_create_naming_bad_short_two|bucket_get_location|bucket_acl_default|bucket_acl_canned|bucket_acl_canned_publicreadwrite|bucket_acl_canned_authenticatedread|object_acl_default|object_acl_canned_during_create|object_acl_canned|object_acl_canned_publicreadwrite|object_acl_canned_authenticatedread|object_acl_canned_bucketownerread|object_acl_canned_bucketownerfullcontrol|object_acl_full_control_verify_attributes|bucket_acl_canned_private_to_private|bucket_acl_grant_nonexist_user|bucket_acl_no_grants|bucket_acl_grant_email_not_exist|bucket_acl_revoke_all|bucket_recreate_not_overriding|object_copy_verify_contenttype|object_copy_to_itself_with_metadata|object_copy_not_owned_bucket|object_copy_not_owned_object_bucket|object_copy_retaining_metadata|object_copy_replacing_metadata|multipart_upload_empty|multipart_copy_invalid_range|multipart_copy_special_names|multipart_upload_resend_part|multipart_upload_size_too_small|abort_multipart_upload_not_found|multipart_upload_missing_part|multipart_upload_incorrect_etag|100_continue|ranged_request_invalid_range|ranged_request_empty_object|access_bucket)"
|
||||||
depends_on:
|
depends_on:
|
||||||
- master
|
- master
|
||||||
- volume
|
- volume
|
||||||
|
|||||||
@@ -57,16 +57,6 @@ case "$1" in
|
|||||||
exec /usr/bin/weed s3 $ARGS $@
|
exec /usr/bin/weed s3 $ARGS $@
|
||||||
;;
|
;;
|
||||||
|
|
||||||
'cronjob')
|
|
||||||
MASTER=${WEED_MASTER-localhost:9333}
|
|
||||||
FIX_REPLICATION_CRON_SCHEDULE=${CRON_SCHEDULE-*/7 * * * * *}
|
|
||||||
echo "$FIX_REPLICATION_CRON_SCHEDULE" 'echo "lock; volume.fix.replication; unlock" | weed shell -master='$MASTER > /crontab
|
|
||||||
BALANCING_CRON_SCHEDULE=${CRON_SCHEDULE-25 * * * * *}
|
|
||||||
echo "$BALANCING_CRON_SCHEDULE" 'echo "lock; volume.balance -collection ALL_COLLECTIONS -force; unlock" | weed shell -master='$MASTER >> /crontab
|
|
||||||
echo "Running Crontab:"
|
|
||||||
cat /crontab
|
|
||||||
exec supercronic /crontab
|
|
||||||
;;
|
|
||||||
*)
|
*)
|
||||||
exec /usr/bin/weed $@
|
exec /usr/bin/weed $@
|
||||||
;;
|
;;
|
||||||
|
|||||||
@@ -28,16 +28,6 @@ services:
|
|||||||
depends_on:
|
depends_on:
|
||||||
- master
|
- master
|
||||||
- volume
|
- volume
|
||||||
cronjob:
|
|
||||||
image: chrislusf/seaweedfs # use a remote image
|
|
||||||
command: 'cronjob'
|
|
||||||
environment:
|
|
||||||
# Run re-replication every 2 minutes
|
|
||||||
CRON_SCHEDULE: '*/2 * * * * *' # Default: '*/5 * * * * *'
|
|
||||||
WEED_MASTER: master:9333 # Default: localhost:9333
|
|
||||||
depends_on:
|
|
||||||
- master
|
|
||||||
- volume
|
|
||||||
s3:
|
s3:
|
||||||
image: chrislusf/seaweedfs # use a remote image
|
image: chrislusf/seaweedfs # use a remote image
|
||||||
ports:
|
ports:
|
||||||
|
|||||||
@@ -1,25 +1,33 @@
|
|||||||
module github.com/chrislusf/seaweedfs
|
module github.com/chrislusf/seaweedfs
|
||||||
|
|
||||||
go 1.16
|
go 1.17
|
||||||
|
|
||||||
require (
|
require (
|
||||||
cloud.google.com/go v0.58.0 // indirect
|
cloud.google.com/go v0.94.1 // indirect
|
||||||
cloud.google.com/go/pubsub v1.3.1
|
cloud.google.com/go/pubsub v1.3.1
|
||||||
cloud.google.com/go/storage v1.9.0
|
cloud.google.com/go/storage v1.16.1
|
||||||
github.com/Azure/azure-pipeline-go v0.2.2 // indirect
|
github.com/Azure/azure-pipeline-go v0.2.3
|
||||||
github.com/Azure/azure-storage-blob-go v0.9.0
|
github.com/Azure/azure-storage-blob-go v0.14.0
|
||||||
|
github.com/DataDog/zstd v1.3.6-0.20190409195224-796139022798 // indirect
|
||||||
github.com/OneOfOne/xxhash v1.2.2
|
github.com/OneOfOne/xxhash v1.2.2
|
||||||
github.com/Shopify/sarama v1.23.1
|
github.com/Shopify/sarama v1.23.1
|
||||||
github.com/aws/aws-sdk-go v1.34.30
|
github.com/aws/aws-sdk-go v1.35.3
|
||||||
|
github.com/beorn7/perks v1.0.1 // indirect
|
||||||
github.com/buraksezer/consistent v0.0.0-20191006190839-693edf70fd72
|
github.com/buraksezer/consistent v0.0.0-20191006190839-693edf70fd72
|
||||||
github.com/bwmarrin/snowflake v0.3.0
|
github.com/bwmarrin/snowflake v0.3.0
|
||||||
github.com/cespare/xxhash v1.1.0
|
github.com/cespare/xxhash v1.1.0
|
||||||
|
github.com/cespare/xxhash/v2 v2.1.1 // indirect
|
||||||
github.com/chrislusf/raft v1.0.7
|
github.com/chrislusf/raft v1.0.7
|
||||||
|
github.com/colinmarc/hdfs/v2 v2.2.0
|
||||||
github.com/coreos/go-semver v0.3.0 // indirect
|
github.com/coreos/go-semver v0.3.0 // indirect
|
||||||
github.com/dgrijalva/jwt-go v3.2.0+incompatible
|
github.com/coreos/go-systemd/v22 v22.3.2 // indirect
|
||||||
|
github.com/davecgh/go-spew v1.1.1 // indirect
|
||||||
|
github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f // indirect
|
||||||
github.com/disintegration/imaging v1.6.2
|
github.com/disintegration/imaging v1.6.2
|
||||||
github.com/dustin/go-humanize v1.0.0
|
github.com/dustin/go-humanize v1.0.0
|
||||||
github.com/eapache/go-resiliency v1.2.0 // indirect
|
github.com/eapache/go-resiliency v1.2.0 // indirect
|
||||||
|
github.com/eapache/go-xerial-snappy v0.0.0-20180814174437-776d5712da21 // indirect
|
||||||
|
github.com/eapache/queue v1.1.0 // indirect
|
||||||
github.com/facebookgo/clock v0.0.0-20150410010913-600d898af40a
|
github.com/facebookgo/clock v0.0.0-20150410010913-600d898af40a
|
||||||
github.com/facebookgo/ensure v0.0.0-20200202191622-63f1cf65ac4c // indirect
|
github.com/facebookgo/ensure v0.0.0-20200202191622-63f1cf65ac4c // indirect
|
||||||
github.com/facebookgo/stack v0.0.0-20160209184415-751773369052 // indirect
|
github.com/facebookgo/stack v0.0.0-20160209184415-751773369052 // indirect
|
||||||
@@ -27,80 +35,161 @@ require (
|
|||||||
github.com/facebookgo/subset v0.0.0-20200203212716-c811ad88dec4 // indirect
|
github.com/facebookgo/subset v0.0.0-20200203212716-c811ad88dec4 // indirect
|
||||||
github.com/fclairamb/ftpserverlib v0.8.0
|
github.com/fclairamb/ftpserverlib v0.8.0
|
||||||
github.com/frankban/quicktest v1.7.2 // indirect
|
github.com/frankban/quicktest v1.7.2 // indirect
|
||||||
|
github.com/fsnotify/fsnotify v1.4.9 // indirect
|
||||||
github.com/go-errors/errors v1.1.1 // indirect
|
github.com/go-errors/errors v1.1.1 // indirect
|
||||||
github.com/go-redis/redis/v8 v8.4.4
|
github.com/go-redis/redis/v8 v8.4.4
|
||||||
|
github.com/go-redsync/redsync/v4 v4.4.1
|
||||||
github.com/go-sql-driver/mysql v1.5.0
|
github.com/go-sql-driver/mysql v1.5.0
|
||||||
github.com/gocql/gocql v0.0.0-20190829130954-e163eff7a8c6
|
github.com/go-stack/stack v1.8.0 // indirect
|
||||||
github.com/gogo/protobuf v1.2.2-0.20190730201129-28a6bbf47e48 // indirect
|
github.com/go-zookeeper/zk v1.0.2 // indirect
|
||||||
github.com/golang/groupcache v0.0.0-20200121045136-8c9f03a8e57e
|
github.com/gocql/gocql v0.0.0-20210707082121-9a3953d1826d
|
||||||
github.com/golang/protobuf v1.4.2
|
github.com/golang-jwt/jwt v3.2.1+incompatible
|
||||||
|
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da
|
||||||
|
github.com/golang/protobuf v1.5.2
|
||||||
|
github.com/golang/snappy v0.0.4 // indirect
|
||||||
github.com/google/btree v1.0.0
|
github.com/google/btree v1.0.0
|
||||||
github.com/google/uuid v1.1.1
|
github.com/google/go-cmp v0.5.6 // indirect
|
||||||
|
github.com/google/uuid v1.3.0
|
||||||
|
github.com/google/wire v0.4.0 // indirect
|
||||||
|
github.com/googleapis/gax-go v2.0.2+incompatible // indirect
|
||||||
|
github.com/googleapis/gax-go/v2 v2.1.0 // indirect
|
||||||
github.com/gorilla/mux v1.7.4
|
github.com/gorilla/mux v1.7.4
|
||||||
github.com/gorilla/websocket v1.4.1 // indirect
|
github.com/grpc-ecosystem/go-grpc-middleware v1.1.0
|
||||||
github.com/grpc-ecosystem/go-grpc-middleware v1.0.1-0.20190118093823-f849b5445de4
|
github.com/hailocab/go-hostpool v0.0.0-20160125115350-e80d13ce29ed // indirect
|
||||||
github.com/grpc-ecosystem/grpc-gateway v1.11.0 // indirect
|
github.com/hashicorp/errwrap v1.0.0 // indirect
|
||||||
|
github.com/hashicorp/go-multierror v1.1.0 // indirect
|
||||||
|
github.com/hashicorp/go-uuid v1.0.2 // indirect
|
||||||
|
github.com/hashicorp/hcl v1.0.0 // indirect
|
||||||
github.com/jcmturner/gofork v1.0.0 // indirect
|
github.com/jcmturner/gofork v1.0.0 // indirect
|
||||||
|
github.com/jcmturner/gokrb5/v8 v8.4.1
|
||||||
github.com/jinzhu/copier v0.2.8
|
github.com/jinzhu/copier v0.2.8
|
||||||
github.com/json-iterator/go v1.1.10
|
github.com/jmespath/go-jmespath v0.4.0 // indirect
|
||||||
github.com/karlseguin/ccache v2.0.3+incompatible // indirect
|
github.com/json-iterator/go v1.1.11
|
||||||
github.com/karlseguin/ccache/v2 v2.0.7
|
github.com/karlseguin/ccache/v2 v2.0.7
|
||||||
github.com/klauspost/compress v1.10.9 // indirect
|
github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51 // indirect
|
||||||
|
github.com/klauspost/compress v1.13.6 // indirect
|
||||||
github.com/klauspost/cpuid v1.2.1 // indirect
|
github.com/klauspost/cpuid v1.2.1 // indirect
|
||||||
github.com/klauspost/crc32 v1.2.0
|
|
||||||
github.com/klauspost/reedsolomon v1.9.2
|
github.com/klauspost/reedsolomon v1.9.2
|
||||||
|
github.com/konsorten/go-windows-terminal-sequences v1.0.3 // indirect
|
||||||
github.com/kurin/blazer v0.5.3
|
github.com/kurin/blazer v0.5.3
|
||||||
github.com/lib/pq v1.10.0
|
github.com/lib/pq v1.10.0
|
||||||
github.com/lunixbochs/vtclean v1.0.0 // indirect
|
github.com/linxGnu/grocksdb v1.6.38
|
||||||
github.com/magiconair/properties v1.8.1 // indirect
|
github.com/magiconair/properties v1.8.1 // indirect
|
||||||
github.com/mattn/go-colorable v0.1.2 // indirect
|
github.com/mailru/easyjson v0.7.1 // indirect
|
||||||
github.com/mattn/go-runewidth v0.0.4 // indirect
|
github.com/mattn/go-ieproxy v0.0.1 // indirect
|
||||||
|
github.com/mattn/go-isatty v0.0.12 // indirect
|
||||||
|
github.com/matttproud/golang_protobuf_extensions v1.0.1 // indirect
|
||||||
|
github.com/mitchellh/mapstructure v1.1.2 // indirect
|
||||||
|
github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect
|
||||||
|
github.com/modern-go/reflect2 v1.0.1 // indirect
|
||||||
|
github.com/nats-io/jwt v1.0.1 // indirect
|
||||||
|
github.com/nats-io/nats.go v1.10.0 // indirect
|
||||||
|
github.com/nats-io/nkeys v0.2.0 // indirect
|
||||||
|
github.com/nats-io/nuid v1.0.1 // indirect
|
||||||
github.com/olivere/elastic/v7 v7.0.19
|
github.com/olivere/elastic/v7 v7.0.19
|
||||||
|
github.com/pelletier/go-toml v1.7.0 // indirect
|
||||||
github.com/peterh/liner v1.1.0
|
github.com/peterh/liner v1.1.0
|
||||||
github.com/pierrec/lz4 v2.2.7+incompatible // indirect
|
github.com/pierrec/lz4 v2.2.7+incompatible // indirect
|
||||||
|
github.com/pkg/errors v0.9.1 // indirect
|
||||||
|
github.com/pmezard/go-difflib v1.0.0 // indirect
|
||||||
|
github.com/posener/complete v1.2.3
|
||||||
github.com/pquerna/cachecontrol v0.1.0
|
github.com/pquerna/cachecontrol v0.1.0
|
||||||
github.com/prometheus/client_golang v1.3.0
|
github.com/prometheus/client_golang v1.11.0
|
||||||
|
github.com/prometheus/client_model v0.2.0 // indirect
|
||||||
|
github.com/prometheus/common v0.26.0 // indirect
|
||||||
|
github.com/prometheus/procfs v0.6.0 // indirect
|
||||||
github.com/rcrowley/go-metrics v0.0.0-20190826022208-cac0b30c2563 // indirect
|
github.com/rcrowley/go-metrics v0.0.0-20190826022208-cac0b30c2563 // indirect
|
||||||
github.com/seaweedfs/fuse v1.1.7
|
github.com/remyoudompheng/bigfft v0.0.0-20200410134404-eec4a21b6bb0 // indirect
|
||||||
|
github.com/seaweedfs/fuse v1.2.1
|
||||||
github.com/seaweedfs/goexif v1.0.2
|
github.com/seaweedfs/goexif v1.0.2
|
||||||
github.com/skip2/go-qrcode v0.0.0-20200617195104-da1b6568686e
|
github.com/sirupsen/logrus v1.6.0 // indirect
|
||||||
github.com/spaolacci/murmur3 v1.1.0 // indirect
|
github.com/spaolacci/murmur3 v1.1.0 // indirect
|
||||||
|
github.com/spf13/afero v1.6.0 // indirect
|
||||||
|
github.com/spf13/cast v1.3.0 // indirect
|
||||||
github.com/spf13/jwalterweatherman v1.1.0 // indirect
|
github.com/spf13/jwalterweatherman v1.1.0 // indirect
|
||||||
github.com/spf13/viper v1.4.0
|
github.com/spf13/viper v1.4.0
|
||||||
github.com/streadway/amqp v0.0.0-20200108173154-1c71cc93ed71
|
github.com/streadway/amqp v0.0.0-20200108173154-1c71cc93ed71
|
||||||
github.com/stretchr/testify v1.6.1
|
github.com/stretchr/testify v1.7.0
|
||||||
github.com/syndtr/goleveldb v1.0.0
|
github.com/stvp/tempredis v0.0.0-20181119212430-b82af8480203
|
||||||
github.com/tecbot/gorocksdb v0.0.0-20191217155057-f0fad39f321c
|
github.com/syndtr/goleveldb v1.0.1-0.20190318030020-c3a204f8e965
|
||||||
github.com/tidwall/gjson v1.3.2
|
github.com/tidwall/gjson v1.10.2
|
||||||
github.com/tidwall/match v1.0.1
|
github.com/tidwall/match v1.1.1
|
||||||
|
github.com/tidwall/pretty v1.2.0 // indirect
|
||||||
github.com/tsuna/gohbase v0.0.0-20201125011725-348991136365
|
github.com/tsuna/gohbase v0.0.0-20201125011725-348991136365
|
||||||
|
github.com/tylertreat/BoomFilters v0.0.0-20210315201527-1a82519a3e43
|
||||||
github.com/valyala/bytebufferpool v1.0.0
|
github.com/valyala/bytebufferpool v1.0.0
|
||||||
github.com/viant/assertly v0.5.4 // indirect
|
github.com/viant/assertly v0.5.4 // indirect
|
||||||
github.com/viant/ptrie v0.3.0
|
github.com/viant/ptrie v0.3.0
|
||||||
github.com/viant/toolbox v0.33.2 // indirect
|
github.com/viant/toolbox v0.33.2 // indirect
|
||||||
github.com/willf/bitset v1.1.10 // indirect
|
github.com/xdg-go/pbkdf2 v1.0.0 // indirect
|
||||||
github.com/willf/bloom v2.0.3+incompatible
|
github.com/xdg-go/scram v1.0.2 // indirect
|
||||||
github.com/wsxiaoys/terminal v0.0.0-20160513160801-0940f3fc43a0 // indirect
|
github.com/xdg-go/stringprep v1.0.2 // indirect
|
||||||
go.etcd.io/etcd v3.3.15+incompatible
|
github.com/youmark/pkcs8 v0.0.0-20181117223130-1be2e3e5546d // indirect
|
||||||
go.mongodb.org/mongo-driver v1.3.2
|
go.etcd.io/etcd/client/v3 v3.5.0
|
||||||
|
go.mongodb.org/mongo-driver v1.8.0
|
||||||
|
go.opencensus.io v0.23.0 // indirect
|
||||||
|
go.opentelemetry.io/otel v0.15.0 // indirect
|
||||||
gocloud.dev v0.20.0
|
gocloud.dev v0.20.0
|
||||||
gocloud.dev/pubsub/natspubsub v0.20.0
|
gocloud.dev/pubsub/natspubsub v0.20.0
|
||||||
gocloud.dev/pubsub/rabbitpubsub v0.20.0
|
gocloud.dev/pubsub/rabbitpubsub v0.20.0
|
||||||
golang.org/x/image v0.0.0-20200119044424-58c23975cae1 // indirect
|
golang.org/x/crypto v0.0.0-20201216223049-8b5274cf687f // indirect
|
||||||
golang.org/x/net v0.0.0-20201202161906-c7110b5ffcbb
|
golang.org/x/image v0.0.0-20200119044424-58c23975cae1
|
||||||
golang.org/x/sys v0.0.0-20210124154548-22da62e12c0c
|
golang.org/x/net v0.0.0-20210813160813-60bc85c4be6d
|
||||||
golang.org/x/tools v0.0.0-20201124115921-2c860bdd6e78
|
golang.org/x/oauth2 v0.0.0-20210819190943-2bc19b11175f // indirect
|
||||||
google.golang.org/api v0.26.0
|
golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e
|
||||||
google.golang.org/grpc v1.29.1
|
golang.org/x/text v0.3.7 // indirect
|
||||||
google.golang.org/protobuf v1.24.0
|
golang.org/x/tools v0.1.6-0.20210726203631-07bc1bf47fb2
|
||||||
gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15 // indirect
|
golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1 // indirect
|
||||||
|
google.golang.org/api v0.57.0
|
||||||
|
google.golang.org/appengine v1.6.7 // indirect
|
||||||
|
google.golang.org/genproto v0.0.0-20210921142501-181ce0d877f6 // indirect
|
||||||
|
google.golang.org/grpc v1.40.0
|
||||||
|
google.golang.org/protobuf v1.27.1
|
||||||
|
gopkg.in/inf.v0 v0.9.1 // indirect
|
||||||
|
gopkg.in/jcmturner/aescts.v1 v1.0.1 // indirect
|
||||||
|
gopkg.in/jcmturner/dnsutils.v1 v1.0.1 // indirect
|
||||||
gopkg.in/jcmturner/goidentity.v3 v3.0.0 // indirect
|
gopkg.in/jcmturner/goidentity.v3 v3.0.0 // indirect
|
||||||
gopkg.in/jcmturner/gokrb5.v7 v7.3.0 // indirect
|
gopkg.in/jcmturner/gokrb5.v7 v7.3.0 // indirect
|
||||||
gopkg.in/karlseguin/expect.v1 v1.0.1 // indirect
|
gopkg.in/jcmturner/rpc.v1 v1.1.0 // indirect
|
||||||
|
modernc.org/b v1.0.0 // indirect
|
||||||
|
modernc.org/cc/v3 v3.33.5 // indirect
|
||||||
|
modernc.org/ccgo/v3 v3.9.4 // indirect
|
||||||
|
modernc.org/libc v1.9.5 // indirect
|
||||||
|
modernc.org/mathutil v1.2.2 // indirect
|
||||||
|
modernc.org/memory v1.0.4 // indirect
|
||||||
|
modernc.org/opt v0.1.1 // indirect
|
||||||
modernc.org/sqlite v1.10.7
|
modernc.org/sqlite v1.10.7
|
||||||
|
modernc.org/strutil v1.1.0 // indirect
|
||||||
|
modernc.org/token v1.0.0 // indirect
|
||||||
)
|
)
|
||||||
|
|
||||||
// replace github.com/seaweedfs/fuse => /Users/chris/go/src/github.com/seaweedfs/fuse
|
require (
|
||||||
// replace github.com/chrislusf/raft => /Users/chris/go/src/github.com/chrislusf/raft
|
cloud.google.com/go/kms v1.0.0 // indirect
|
||||||
|
github.com/apache/thrift v0.15.0 // indirect
|
||||||
|
github.com/d4l3k/messagediff v1.2.1 // indirect
|
||||||
|
github.com/fluent/fluent-logger-golang v1.8.0 // indirect
|
||||||
|
github.com/gogo/protobuf v1.3.2 // indirect
|
||||||
|
github.com/gorilla/websocket v1.4.2 // indirect
|
||||||
|
github.com/jcmturner/aescts/v2 v2.0.0 // indirect
|
||||||
|
github.com/jcmturner/dnsutils/v2 v2.0.0 // indirect
|
||||||
|
github.com/jcmturner/goidentity/v6 v6.0.1 // indirect
|
||||||
|
github.com/jcmturner/rpc/v2 v2.0.2 // indirect
|
||||||
|
github.com/mattn/go-runewidth v0.0.7 // indirect
|
||||||
|
github.com/mattn/go-sqlite3 v2.0.1+incompatible // indirect
|
||||||
|
github.com/miekg/dns v1.1.44 // indirect
|
||||||
|
github.com/philhofer/fwd v1.1.1 // indirect
|
||||||
|
github.com/spf13/pflag v1.0.5 // indirect
|
||||||
|
github.com/tinylib/msgp v1.1.6 // indirect
|
||||||
|
go.etcd.io/etcd/api/v3 v3.5.0 // indirect
|
||||||
|
go.etcd.io/etcd/client/pkg/v3 v3.5.0 // indirect
|
||||||
|
go.uber.org/atomic v1.7.0 // indirect
|
||||||
|
go.uber.org/multierr v1.7.0 // indirect
|
||||||
|
go.uber.org/zap v1.17.0 // indirect
|
||||||
|
golang.org/x/mod v0.4.2 // indirect
|
||||||
|
golang.org/x/sync v0.0.0-20210220032951-036812b2e83c // indirect
|
||||||
|
gopkg.in/yaml.v2 v2.4.0 // indirect
|
||||||
|
gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b // indirect
|
||||||
|
)
|
||||||
|
|
||||||
replace go.etcd.io/etcd => go.etcd.io/etcd v0.5.0-alpha.5.0.20200425165423-262c93980547
|
// replace github.com/seaweedfs/fuse => /Users/chrislu/go/src/github.com/seaweedfs/fuse
|
||||||
|
// replace github.com/chrislusf/raft => /Users/chrislu/go/src/github.com/chrislusf/raft
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
apiVersion: v1
|
apiVersion: v1
|
||||||
description: SeaweedFS
|
description: SeaweedFS
|
||||||
name: seaweedfs
|
name: seaweedfs
|
||||||
appVersion: "2.51"
|
appVersion: "2.85"
|
||||||
version: "2.51"
|
version: "2.85"
|
||||||
@@ -113,21 +113,6 @@ Inject extra environment vars in the format key:value, if populated
|
|||||||
{{- end -}}
|
{{- end -}}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
|
|
||||||
{{/* Return the proper cronjob image */}}
|
|
||||||
{{- define "cronjob.image" -}}
|
|
||||||
{{- if .Values.cronjob.imageOverride -}}
|
|
||||||
{{- $imageOverride := .Values.cronjob.imageOverride -}}
|
|
||||||
{{- printf "%s" $imageOverride -}}
|
|
||||||
{{- else -}}
|
|
||||||
{{- $registryName := default .Values.image.registry .Values.global.localRegistry | toString -}}
|
|
||||||
{{- $repositoryName := .Values.image.repository | toString -}}
|
|
||||||
{{- $name := .Values.global.imageName | toString -}}
|
|
||||||
{{- $tag := .Chart.AppVersion | toString -}}
|
|
||||||
{{- printf "%s%s%s:%s" $registryName $repositoryName $name $tag -}}
|
|
||||||
{{- end -}}
|
|
||||||
{{- end -}}
|
|
||||||
|
|
||||||
|
|
||||||
{{/* check if any PVC exists */}}
|
{{/* check if any PVC exists */}}
|
||||||
{{- define "volume.pvc_exists" -}}
|
{{- define "volume.pvc_exists" -}}
|
||||||
{{- if or (or (eq .Values.volume.data.type "persistentVolumeClaim") (and (eq .Values.volume.idx.type "persistentVolumeClaim") .Values.volume.dir_idx )) (eq .Values.volume.logs.type "persistentVolumeClaim") -}}
|
{{- if or (or (eq .Values.volume.data.type "persistentVolumeClaim") (and (eq .Values.volume.idx.type "persistentVolumeClaim") .Values.volume.dir_idx )) (eq .Values.volume.logs.type "persistentVolumeClaim") -}}
|
||||||
+2
@@ -1,4 +1,5 @@
|
|||||||
{{- if .Values.filer.metricsPort }}
|
{{- if .Values.filer.metricsPort }}
|
||||||
|
{{- if .Values.global.monitoring.enabled }}
|
||||||
apiVersion: monitoring.coreos.com/v1
|
apiVersion: monitoring.coreos.com/v1
|
||||||
kind: ServiceMonitor
|
kind: ServiceMonitor
|
||||||
metadata:
|
metadata:
|
||||||
@@ -15,4 +16,5 @@ spec:
|
|||||||
selector:
|
selector:
|
||||||
app: {{ template "seaweedfs.name" . }}
|
app: {{ template "seaweedfs.name" . }}
|
||||||
component: filer
|
component: filer
|
||||||
|
{{- end }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
+3
-5
@@ -133,11 +133,6 @@ spec:
|
|||||||
-encryptVolumeData \
|
-encryptVolumeData \
|
||||||
{{- end }}
|
{{- end }}
|
||||||
-ip=${POD_IP} \
|
-ip=${POD_IP} \
|
||||||
{{- if .Values.filer.enable_peers }}
|
|
||||||
{{- if gt (.Values.filer.replicas | int) 1 }}
|
|
||||||
-peers=$(echo -n "{{ range $index := until (.Values.filer.replicas | int) }}${SEAWEEDFS_FULLNAME}-filer-{{ $index }}.${SEAWEEDFS_FULLNAME}-filer:{{ $.Values.filer.port }}{{ if lt $index (sub ($.Values.filer.replicas | int) 1) }},{{ end }}{{ end }}" | sed "s/$HOSTNAME.${SEAWEEDFS_FULLNAME}-filer:{{ $.Values.filer.port }}//" | sed 's/,$//; 's/^,//'; s/,,/,/;' ) \
|
|
||||||
{{- end }}
|
|
||||||
{{- end }}
|
|
||||||
{{- if .Values.filer.s3.enabled }}
|
{{- if .Values.filer.s3.enabled }}
|
||||||
-s3 \
|
-s3 \
|
||||||
-s3.port={{ .Values.filer.s3.port }} \
|
-s3.port={{ .Values.filer.s3.port }} \
|
||||||
@@ -154,6 +149,9 @@ spec:
|
|||||||
{{- if .Values.filer.s3.enableAuth }}
|
{{- if .Values.filer.s3.enableAuth }}
|
||||||
-s3.config=/etc/sw/seaweedfs_s3_config \
|
-s3.config=/etc/sw/seaweedfs_s3_config \
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
{{- if .Values.filer.s3.auditLogConfig }}
|
||||||
|
-s3.auditLogConfig=/etc/sw/filer_s3_auditLogConfig.json \
|
||||||
|
{{- end }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
-master={{ range $index := until (.Values.master.replicas | int) }}${SEAWEEDFS_FULLNAME}-master-{{ $index }}.${SEAWEEDFS_FULLNAME}-master:{{ $.Values.master.port }}{{ if lt $index (sub ($.Values.master.replicas | int) 1) }},{{ end }}{{ end }}
|
-master={{ range $index := until (.Values.master.replicas | int) }}${SEAWEEDFS_FULLNAME}-master-{{ $index }}.${SEAWEEDFS_FULLNAME}-master:{{ $.Values.master.port }}{{ if lt $index (sub ($.Values.master.replicas | int) 1) }},{{ end }}{{ end }}
|
||||||
{{- if or (.Values.global.enableSecurity) (.Values.filer.extraVolumeMounts) }}
|
{{- if or (.Values.global.enableSecurity) (.Values.filer.extraVolumeMounts) }}
|
||||||
@@ -0,0 +1,67 @@
|
|||||||
|
{{- if .Values.filer.ingress.enabled }}
|
||||||
|
{{- if semverCompare ">=1.19-0" .Capabilities.KubeVersion.GitVersion }}
|
||||||
|
apiVersion: networking.k8s.io/v1
|
||||||
|
{{- else if semverCompare ">=1.14-0" .Capabilities.KubeVersion.GitVersion }}
|
||||||
|
apiVersion: networking.k8s.io/v1beta1
|
||||||
|
{{- else }}
|
||||||
|
apiVersion: extensions/v1beta1
|
||||||
|
{{- end }}
|
||||||
|
kind: Ingress
|
||||||
|
metadata:
|
||||||
|
name: ingress-{{ template "seaweedfs.name" . }}-filer
|
||||||
|
namespace: {{ .Release.Namespace }}
|
||||||
|
annotations:
|
||||||
|
{{ omit .Values.filer.ingress.annotations "kubernetes.io/ingress.class" | toYaml | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
ingressClassName: {{ .Values.filer.ingress.className | quote }}
|
||||||
|
rules:
|
||||||
|
- http:
|
||||||
|
paths:
|
||||||
|
- path: /sw-filer/?(.*)
|
||||||
|
pathType: ImplementationSpecific
|
||||||
|
backend:
|
||||||
|
{{- if semverCompare ">=1.19-0" .Capabilities.KubeVersion.GitVersion }}
|
||||||
|
service:
|
||||||
|
name: {{ template "seaweedfs.name" . }}-filer
|
||||||
|
port:
|
||||||
|
number: {{ .Values.filer.port }}
|
||||||
|
#name:
|
||||||
|
{{- else }}
|
||||||
|
serviceName: {{ template "seaweedfs.name" . }}-filer
|
||||||
|
servicePort: {{ .Values.filer.port }}
|
||||||
|
{{- end }}
|
||||||
|
{{- end }}
|
||||||
|
---
|
||||||
|
{{- if .Values.master.ingress.enabled }}
|
||||||
|
{{- if semverCompare ">=1.19-0" .Capabilities.KubeVersion.GitVersion }}
|
||||||
|
apiVersion: networking.k8s.io/v1
|
||||||
|
{{- else if semverCompare ">=1.14-0" .Capabilities.KubeVersion.GitVersion }}
|
||||||
|
apiVersion: networking.k8s.io/v1beta1
|
||||||
|
{{- else }}
|
||||||
|
apiVersion: extensions/v1beta1
|
||||||
|
{{- end }}
|
||||||
|
kind: Ingress
|
||||||
|
metadata:
|
||||||
|
name: ingress-{{ template "seaweedfs.name" . }}-master
|
||||||
|
namespace: {{ .Release.Namespace }}
|
||||||
|
annotations:
|
||||||
|
{{ omit .Values.master.ingress.annotations "kubernetes.io/ingress.class" | toYaml | nindent 4 }}
|
||||||
|
spec:
|
||||||
|
ingressClassName: {{ .Values.master.ingress.className | quote }}
|
||||||
|
rules:
|
||||||
|
- http:
|
||||||
|
paths:
|
||||||
|
- path: /sw-master/?(.*)
|
||||||
|
pathType: ImplementationSpecific
|
||||||
|
backend:
|
||||||
|
{{- if semverCompare ">=1.19-0" .Capabilities.KubeVersion.GitVersion }}
|
||||||
|
service:
|
||||||
|
name: {{ template "seaweedfs.name" . }}-master
|
||||||
|
port:
|
||||||
|
number: {{ .Values.master.port }}
|
||||||
|
#name:
|
||||||
|
{{- else }}
|
||||||
|
serviceName: {{ template "seaweedfs.name" . }}-master
|
||||||
|
servicePort: {{ .Values.master.port }}
|
||||||
|
{{- end }}
|
||||||
|
{{- end }}
|
||||||
+3
@@ -93,6 +93,9 @@ spec:
|
|||||||
{{- if .Values.s3.enableAuth }}
|
{{- if .Values.s3.enableAuth }}
|
||||||
-config=/etc/sw/seaweedfs_s3_config \
|
-config=/etc/sw/seaweedfs_s3_config \
|
||||||
{{- end }}
|
{{- end }}
|
||||||
|
{{- if .Values.s3.auditLogConfig }}
|
||||||
|
-auditLogConfig=/etc/sw/s3_auditLogConfig.json \
|
||||||
|
{{- end }}
|
||||||
-filer={{ template "seaweedfs.name" . }}-filer-client:{{ .Values.filer.port }}
|
-filer={{ template "seaweedfs.name" . }}-filer-client:{{ .Values.filer.port }}
|
||||||
volumeMounts:
|
volumeMounts:
|
||||||
- name: logs
|
- name: logs
|
||||||
+2
@@ -1,4 +1,5 @@
|
|||||||
{{- if .Values.s3.metricsPort }}
|
{{- if .Values.s3.metricsPort }}
|
||||||
|
{{- if .Values.global.monitoring.enabled }}
|
||||||
apiVersion: monitoring.coreos.com/v1
|
apiVersion: monitoring.coreos.com/v1
|
||||||
kind: ServiceMonitor
|
kind: ServiceMonitor
|
||||||
metadata:
|
metadata:
|
||||||
@@ -15,4 +16,5 @@ spec:
|
|||||||
selector:
|
selector:
|
||||||
app: {{ template "seaweedfs.name" . }}
|
app: {{ template "seaweedfs.name" . }}
|
||||||
component: s3
|
component: s3
|
||||||
|
{{- end }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
+8
@@ -18,4 +18,12 @@ stringData:
|
|||||||
read_access_key_id: {{ $access_key_read }}
|
read_access_key_id: {{ $access_key_read }}
|
||||||
read_secret_access_key: {{ $secret_key_read }}
|
read_secret_access_key: {{ $secret_key_read }}
|
||||||
seaweedfs_s3_config: '{"identities":[{"name":"anvAdmin","credentials":[{"accessKey":"{{ $access_key_admin }}","secretKey":"{{ $secret_key_admin }}"}],"actions":["Admin","Read","Write"]},{"name":"anvReadOnly","credentials":[{"accessKey":"{{ $access_key_read }}","secretKey":"{{ $secret_key_read }}"}],"actions":["Read"]}]}'
|
seaweedfs_s3_config: '{"identities":[{"name":"anvAdmin","credentials":[{"accessKey":"{{ $access_key_admin }}","secretKey":"{{ $secret_key_admin }}"}],"actions":["Admin","Read","Write"]},{"name":"anvReadOnly","credentials":[{"accessKey":"{{ $access_key_read }}","secretKey":"{{ $secret_key_read }}"}],"actions":["Read"]}]}'
|
||||||
|
{{- if .Values.filer.s3.auditLogConfig }}
|
||||||
|
filer_s3_auditLogConfig.json: |
|
||||||
|
{{ toJson .Values.filer.s3.auditLogConfig | nindent 4 }}
|
||||||
|
{{- end }}
|
||||||
|
{{- if .Values.s3.auditLogConfig }}
|
||||||
|
s3_auditLogConfig.json: |
|
||||||
|
{{ toJson .Values.s3.auditLogConfig | nindent 4 }}
|
||||||
|
{{- end }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
+3
-3
@@ -1,7 +1,7 @@
|
|||||||
#hack for delete pod master after migration
|
#hack for delete pod master after migration
|
||||||
---
|
---
|
||||||
kind: ClusterRole
|
kind: ClusterRole
|
||||||
apiVersion: rbac.authorization.k8s.io/v1beta1
|
apiVersion: rbac.authorization.k8s.io/v1
|
||||||
metadata:
|
metadata:
|
||||||
name: seaweefds-rw-cr
|
name: seaweefds-rw-cr
|
||||||
rules:
|
rules:
|
||||||
@@ -16,7 +16,7 @@ metadata:
|
|||||||
namespace: {{ .Release.Namespace }}
|
namespace: {{ .Release.Namespace }}
|
||||||
---
|
---
|
||||||
kind: ClusterRoleBinding
|
kind: ClusterRoleBinding
|
||||||
apiVersion: rbac.authorization.k8s.io/v1beta1
|
apiVersion: rbac.authorization.k8s.io/v1
|
||||||
metadata:
|
metadata:
|
||||||
name: system:serviceaccount:seaweefds-rw-sa:default
|
name: system:serviceaccount:seaweefds-rw-sa:default
|
||||||
subjects:
|
subjects:
|
||||||
@@ -26,4 +26,4 @@ subjects:
|
|||||||
roleRef:
|
roleRef:
|
||||||
apiGroup: rbac.authorization.k8s.io
|
apiGroup: rbac.authorization.k8s.io
|
||||||
kind: ClusterRole
|
kind: ClusterRole
|
||||||
name: seaweefds-rw-cr
|
name: seaweefds-rw-cr
|
||||||
+2
@@ -1,4 +1,5 @@
|
|||||||
{{- if .Values.volume.metricsPort }}
|
{{- if .Values.volume.metricsPort }}
|
||||||
|
{{- if .Values.global.monitoring.enabled }}
|
||||||
apiVersion: monitoring.coreos.com/v1
|
apiVersion: monitoring.coreos.com/v1
|
||||||
kind: ServiceMonitor
|
kind: ServiceMonitor
|
||||||
metadata:
|
metadata:
|
||||||
@@ -15,4 +16,5 @@ spec:
|
|||||||
selector:
|
selector:
|
||||||
app: {{ template "seaweedfs.name" . }}
|
app: {{ template "seaweedfs.name" . }}
|
||||||
component: volume
|
component: volume
|
||||||
|
{{- end }}
|
||||||
{{- end }}
|
{{- end }}
|
||||||
+1
-1
@@ -110,7 +110,7 @@ spec:
|
|||||||
-dataCenter={{ .Values.volume.dataCenter }} \
|
-dataCenter={{ .Values.volume.dataCenter }} \
|
||||||
{{- end }}
|
{{- end }}
|
||||||
-ip.bind={{ .Values.volume.ipBind }} \
|
-ip.bind={{ .Values.volume.ipBind }} \
|
||||||
-read.redirect={{ .Values.volume.readRedirect }} \
|
-readMode={{ .Values.volume.readMode }} \
|
||||||
{{- if .Values.volume.whiteList }}
|
{{- if .Values.volume.whiteList }}
|
||||||
-whiteList={{ .Values.volume.whiteList }} \
|
-whiteList={{ .Values.volume.whiteList }} \
|
||||||
{{- end }}
|
{{- end }}
|
||||||
@@ -4,7 +4,6 @@ global:
|
|||||||
registry: ""
|
registry: ""
|
||||||
repository: ""
|
repository: ""
|
||||||
imageName: chrislusf/seaweedfs
|
imageName: chrislusf/seaweedfs
|
||||||
# imageTag: "2.51" - started using {.Chart.appVersion}
|
|
||||||
imagePullPolicy: IfNotPresent
|
imagePullPolicy: IfNotPresent
|
||||||
imagePullSecrets: imagepullsecret
|
imagePullSecrets: imagepullsecret
|
||||||
restartPolicy: Always
|
restartPolicy: Always
|
||||||
@@ -110,6 +109,26 @@ master:
|
|||||||
# ref: https://kubernetes.io/docs/concepts/configuration/pod-priority-preemption/
|
# ref: https://kubernetes.io/docs/concepts/configuration/pod-priority-preemption/
|
||||||
priorityClassName: ""
|
priorityClassName: ""
|
||||||
|
|
||||||
|
ingress:
|
||||||
|
enabled: false
|
||||||
|
className: "nginx"
|
||||||
|
annotations:
|
||||||
|
nginx.ingress.kubernetes.io/auth-type: "basic"
|
||||||
|
nginx.ingress.kubernetes.io/auth-secret: "default/ingress-basic-auth-secret"
|
||||||
|
nginx.ingress.kubernetes.io/auth-realm: 'Authentication Required - SW-Master'
|
||||||
|
nginx.ingress.kubernetes.io/service-upstream: "true"
|
||||||
|
nginx.ingress.kubernetes.io/rewrite-target: /$1
|
||||||
|
nginx.ingress.kubernetes.io/use-regex: "true"
|
||||||
|
nginx.ingress.kubernetes.io/enable-rewrite-log: "true"
|
||||||
|
nginx.ingress.kubernetes.io/ssl-redirect: "false"
|
||||||
|
nginx.ingress.kubernetes.io/force-ssl-redirect: "false"
|
||||||
|
nginx.ingress.kubernetes.io/configuration-snippet: |
|
||||||
|
sub_filter '<head>' '<head> <base href="/sw-master/">'; #add base url
|
||||||
|
sub_filter '="/' '="./'; #make absolute paths to relative
|
||||||
|
sub_filter '=/' '=./';
|
||||||
|
sub_filter '/seaweedfsstatic' './seaweedfsstatic';
|
||||||
|
sub_filter_once off;
|
||||||
|
|
||||||
extraEnvironmentVars:
|
extraEnvironmentVars:
|
||||||
WEED_MASTER_VOLUME_GROWTH_COPY_1: 7
|
WEED_MASTER_VOLUME_GROWTH_COPY_1: 7
|
||||||
WEED_MASTER_VOLUME_GROWTH_COPY_2: 6
|
WEED_MASTER_VOLUME_GROWTH_COPY_2: 6
|
||||||
@@ -162,7 +181,7 @@ volume:
|
|||||||
|
|
||||||
# Directories to store data files. dir[,dir]... (default "/tmp")
|
# Directories to store data files. dir[,dir]... (default "/tmp")
|
||||||
dir: "/data"
|
dir: "/data"
|
||||||
# Directories to store index files. dir[,dir]... (default "/tmp")
|
# Directories to store index files. dir[,dir]... (default is the same as "dir")
|
||||||
dir_idx: null
|
dir_idx: null
|
||||||
|
|
||||||
# Maximum numbers of volumes, count[,count]...
|
# Maximum numbers of volumes, count[,count]...
|
||||||
@@ -175,8 +194,8 @@ volume:
|
|||||||
# Volume server's data center name
|
# Volume server's data center name
|
||||||
dataCenter: null
|
dataCenter: null
|
||||||
|
|
||||||
# Redirect moved or non-local volumes. (default true)
|
# Redirect moved or non-local volumes. (default proxy)
|
||||||
readRedirect: true
|
readMode: proxy
|
||||||
|
|
||||||
# Comma separated Ip addresses having write permission. No limit if empty.
|
# Comma separated Ip addresses having write permission. No limit if empty.
|
||||||
whiteList: null
|
whiteList: null
|
||||||
@@ -247,8 +266,6 @@ filer:
|
|||||||
maxMB: null
|
maxMB: null
|
||||||
# encrypt data on volume servers
|
# encrypt data on volume servers
|
||||||
encryptVolumeData: false
|
encryptVolumeData: false
|
||||||
# enable peers sync metadata, for leveldb (localdb for filer but with sync across)
|
|
||||||
enable_peers: false
|
|
||||||
|
|
||||||
# Whether proxy or redirect to volume server during file GET request
|
# Whether proxy or redirect to volume server during file GET request
|
||||||
redirectOnRead: false
|
redirectOnRead: false
|
||||||
@@ -256,9 +273,6 @@ filer:
|
|||||||
# Limit sub dir listing size (default 100000)
|
# Limit sub dir listing size (default 100000)
|
||||||
dirListLimit: 100000
|
dirListLimit: 100000
|
||||||
|
|
||||||
# Turn off directory listing
|
|
||||||
disableDirListing: false
|
|
||||||
|
|
||||||
# Disable http request, only gRpc operations are allowed
|
# Disable http request, only gRpc operations are allowed
|
||||||
disableHttp: false
|
disableHttp: false
|
||||||
|
|
||||||
@@ -312,6 +326,26 @@ filer:
|
|||||||
# ref: https://kubernetes.io/docs/concepts/configuration/pod-priority-preemption/
|
# ref: https://kubernetes.io/docs/concepts/configuration/pod-priority-preemption/
|
||||||
priorityClassName: ""
|
priorityClassName: ""
|
||||||
|
|
||||||
|
ingress:
|
||||||
|
enabled: false
|
||||||
|
className: "nginx"
|
||||||
|
annotations:
|
||||||
|
nginx.ingress.kubernetes.io/auth-type: "basic"
|
||||||
|
nginx.ingress.kubernetes.io/auth-secret: "default/ingress-basic-auth-secret"
|
||||||
|
nginx.ingress.kubernetes.io/auth-realm: 'Authentication Required - SW-Filer'
|
||||||
|
nginx.ingress.kubernetes.io/service-upstream: "true"
|
||||||
|
nginx.ingress.kubernetes.io/rewrite-target: /$1
|
||||||
|
nginx.ingress.kubernetes.io/use-regex: "true"
|
||||||
|
nginx.ingress.kubernetes.io/enable-rewrite-log: "true"
|
||||||
|
nginx.ingress.kubernetes.io/ssl-redirect: "false"
|
||||||
|
nginx.ingress.kubernetes.io/force-ssl-redirect: "false"
|
||||||
|
nginx.ingress.kubernetes.io/configuration-snippet: |
|
||||||
|
sub_filter '<head>' '<head> <base href="/sw-filer/">'; #add base url
|
||||||
|
sub_filter '="/' '="./'; #make absolute paths to relative
|
||||||
|
sub_filter '=/' '=./';
|
||||||
|
sub_filter '/seaweedfsstatic' './seaweedfsstatic';
|
||||||
|
sub_filter_once off;
|
||||||
|
|
||||||
# extraEnvVars is a list of extra enviroment variables to set with the stateful set.
|
# extraEnvVars is a list of extra enviroment variables to set with the stateful set.
|
||||||
extraEnvironmentVars:
|
extraEnvironmentVars:
|
||||||
WEED_MYSQL_ENABLED: "true"
|
WEED_MYSQL_ENABLED: "true"
|
||||||
@@ -341,6 +375,7 @@ filer:
|
|||||||
# enable user & permission to s3 (need to inject to all services)
|
# enable user & permission to s3 (need to inject to all services)
|
||||||
enableAuth: false
|
enableAuth: false
|
||||||
skipAuthSecretCreation: false
|
skipAuthSecretCreation: false
|
||||||
|
auditLogConfig: {}
|
||||||
|
|
||||||
s3:
|
s3:
|
||||||
enabled: false
|
enabled: false
|
||||||
@@ -357,6 +392,7 @@ s3:
|
|||||||
# enable user & permission to s3 (need to inject to all services)
|
# enable user & permission to s3 (need to inject to all services)
|
||||||
enableAuth: false
|
enableAuth: false
|
||||||
skipAuthSecretCreation: false
|
skipAuthSecretCreation: false
|
||||||
|
auditLogConfig: {}
|
||||||
|
|
||||||
# Suffix of the host name, {bucket}.{domainName}
|
# Suffix of the host name, {bucket}.{domainName}
|
||||||
domainName: ""
|
domainName: ""
|
||||||
@@ -392,22 +428,6 @@ s3:
|
|||||||
size: ""
|
size: ""
|
||||||
storageClass: ""
|
storageClass: ""
|
||||||
|
|
||||||
cronjob:
|
|
||||||
enabled: true
|
|
||||||
master: "seaweedfs-master:9333"
|
|
||||||
filer: "seaweedfs-filer-client:8888"
|
|
||||||
tolerations: ""
|
|
||||||
nodeSelector: |
|
|
||||||
sw-backend: "true"
|
|
||||||
replication:
|
|
||||||
enable: true
|
|
||||||
collectionPattern: ""
|
|
||||||
schedule: "*/7 * * * *"
|
|
||||||
resources: null
|
|
||||||
# balance all volumes among volume servers
|
|
||||||
# ALL|EACH_COLLECTION|<collection_name>
|
|
||||||
collection: ""
|
|
||||||
|
|
||||||
|
|
||||||
certificates:
|
certificates:
|
||||||
commonName: "SeaweedFS CA"
|
commonName: "SeaweedFS CA"
|
||||||
@@ -1,58 +0,0 @@
|
|||||||
{{- if .Values.cronjob }}
|
|
||||||
{{- if .Values.cronjob.enabled }}
|
|
||||||
apiVersion: batch/v1beta1
|
|
||||||
kind: CronJob
|
|
||||||
metadata:
|
|
||||||
name: {{ include "seaweedfs.fullname" . }}-cronjob
|
|
||||||
spec:
|
|
||||||
schedule: "{{ .Values.cronjob.schedule }}"
|
|
||||||
startingDeadlineSeconds: 200
|
|
||||||
concurrencyPolicy: Forbid
|
|
||||||
failedJobsHistoryLimit: 2
|
|
||||||
successfulJobsHistoryLimit: 2
|
|
||||||
jobTemplate:
|
|
||||||
spec:
|
|
||||||
backoffLimit: 2
|
|
||||||
template:
|
|
||||||
spec:
|
|
||||||
{{- if .Values.cronjob.nodeSelector }}
|
|
||||||
nodeSelector:
|
|
||||||
{{ tpl .Values.cronjob.nodeSelector . | indent 12 | trim }}
|
|
||||||
{{- end }}
|
|
||||||
{{- if .Values.cronjob.tolerations }}
|
|
||||||
tolerations:
|
|
||||||
{{ tpl .Values.cronjob.tolerations . | nindent 12 | trim }}
|
|
||||||
{{- end }}
|
|
||||||
restartPolicy: OnFailure
|
|
||||||
containers:
|
|
||||||
- name: shell
|
|
||||||
image: {{ template "cronjob.image" . }}
|
|
||||||
imagePullPolicy: {{ default "IfNotPresent" .Values.global.imagePullPolicy }}
|
|
||||||
resources:
|
|
||||||
{{- toYaml .Values.cronjob.resources| nindent 16 }}
|
|
||||||
command:
|
|
||||||
- sh
|
|
||||||
- -c
|
|
||||||
- |
|
|
||||||
set -ex
|
|
||||||
echo -e "lock\n\
|
|
||||||
volume.balance -force \
|
|
||||||
{{ if .Values.volume.dataCenter }} -dataCenter {{ .Values.volume.dataCenter }}{{ end }}\
|
|
||||||
{{ if .Values.cronjob.collection }} -collection {{ .Values.cronjob.collection }}{{ end }}\n\
|
|
||||||
{{- if .Values.cronjob.enableFixReplication }}
|
|
||||||
volume.fix.replication -collectionPattern={{ .Values.cronjob.collectionPattern }} \n\
|
|
||||||
{{- end }}
|
|
||||||
unlock\n" | \
|
|
||||||
/usr/bin/weed shell \
|
|
||||||
{{- if .Values.cronjob.master }}
|
|
||||||
-master {{ .Values.cronjob.master }} \
|
|
||||||
{{- else }}
|
|
||||||
-master {{ template "seaweedfs.name" . }}-master.{{ .Release.Namespace }}.svc:{{ .Values.master.port }} \
|
|
||||||
{{- end }}
|
|
||||||
{{- if .Values.cronjob.filer }}
|
|
||||||
-filer {{ .Values.cronjob.filer }}
|
|
||||||
{{- else }}
|
|
||||||
-filer {{ template "seaweedfs.name" . }}-filer.{{ .Release.Namespace }}.svc:{{ .Values.filer.port }}
|
|
||||||
{{- end }}
|
|
||||||
{{- end }}
|
|
||||||
{{- end }}
|
|
||||||
@@ -1,59 +0,0 @@
|
|||||||
apiVersion: extensions/v1beta1
|
|
||||||
kind: Ingress
|
|
||||||
metadata:
|
|
||||||
name: ingress-{{ template "seaweedfs.name" . }}-filer
|
|
||||||
annotations:
|
|
||||||
kubernetes.io/ingress.class: "nginx"
|
|
||||||
nginx.ingress.kubernetes.io/auth-type: "basic"
|
|
||||||
nginx.ingress.kubernetes.io/auth-secret: "default/ingress-basic-auth-secret"
|
|
||||||
nginx.ingress.kubernetes.io/auth-realm: 'Authentication Required - SW-Filer'
|
|
||||||
nginx.ingress.kubernetes.io/service-upstream: "true"
|
|
||||||
nginx.ingress.kubernetes.io/rewrite-target: /$1
|
|
||||||
nginx.ingress.kubernetes.io/use-regex: "true"
|
|
||||||
nginx.ingress.kubernetes.io/enable-rewrite-log: "true"
|
|
||||||
nginx.ingress.kubernetes.io/ssl-redirect: "false"
|
|
||||||
nginx.ingress.kubernetes.io/force-ssl-redirect: "false"
|
|
||||||
nginx.ingress.kubernetes.io/configuration-snippet: |
|
|
||||||
sub_filter '<head>' '<head> <base href="/sw-filer/">'; #add base url
|
|
||||||
sub_filter '="/' '="./'; #make absolute paths to relative
|
|
||||||
sub_filter '=/' '=./';
|
|
||||||
sub_filter '/seaweedfsstatic' './seaweedfsstatic';
|
|
||||||
sub_filter_once off;
|
|
||||||
spec:
|
|
||||||
rules:
|
|
||||||
- http:
|
|
||||||
paths:
|
|
||||||
- path: /sw-filer/?(.*)
|
|
||||||
backend:
|
|
||||||
serviceName: {{ template "seaweedfs.name" . }}-filer
|
|
||||||
servicePort: {{ .Values.filer.port }}
|
|
||||||
---
|
|
||||||
apiVersion: extensions/v1beta1
|
|
||||||
kind: Ingress
|
|
||||||
metadata:
|
|
||||||
name: ingress-{{ template "seaweedfs.name" . }}-master
|
|
||||||
annotations:
|
|
||||||
kubernetes.io/ingress.class: "nginx"
|
|
||||||
nginx.ingress.kubernetes.io/auth-type: "basic"
|
|
||||||
nginx.ingress.kubernetes.io/auth-secret: "default/ingress-basic-auth-secret"
|
|
||||||
nginx.ingress.kubernetes.io/auth-realm: 'Authentication Required - SW-Master'
|
|
||||||
nginx.ingress.kubernetes.io/service-upstream: "true"
|
|
||||||
nginx.ingress.kubernetes.io/rewrite-target: /$1
|
|
||||||
nginx.ingress.kubernetes.io/use-regex: "true"
|
|
||||||
nginx.ingress.kubernetes.io/enable-rewrite-log: "true"
|
|
||||||
nginx.ingress.kubernetes.io/ssl-redirect: "false"
|
|
||||||
nginx.ingress.kubernetes.io/force-ssl-redirect: "false"
|
|
||||||
nginx.ingress.kubernetes.io/configuration-snippet: |
|
|
||||||
sub_filter '<head>' '<head> <base href="/sw-master/">'; #add base url
|
|
||||||
sub_filter '="/' '="./'; #make absolute paths to relative
|
|
||||||
sub_filter '=/' '=./';
|
|
||||||
sub_filter '/seaweedfsstatic' './seaweedfsstatic';
|
|
||||||
sub_filter_once off;
|
|
||||||
spec:
|
|
||||||
rules:
|
|
||||||
- http:
|
|
||||||
paths:
|
|
||||||
- path: /sw-master/?(.*)
|
|
||||||
backend:
|
|
||||||
serviceName: {{ template "seaweedfs.name" . }}-master
|
|
||||||
servicePort: {{ .Values.master.port }}
|
|
||||||
Binary file not shown.
|
After Width: | Height: | Size: 127 KiB |
Binary file not shown.
|
After Width: | Height: | Size: 81 KiB |
@@ -5,7 +5,7 @@
|
|||||||
|
|
||||||
<groupId>com.github.chrislusf</groupId>
|
<groupId>com.github.chrislusf</groupId>
|
||||||
<artifactId>seaweedfs-client</artifactId>
|
<artifactId>seaweedfs-client</artifactId>
|
||||||
<version>1.6.6</version>
|
<version>2.85</version>
|
||||||
|
|
||||||
<parent>
|
<parent>
|
||||||
<groupId>org.sonatype.oss</groupId>
|
<groupId>org.sonatype.oss</groupId>
|
||||||
@@ -14,7 +14,7 @@
|
|||||||
</parent>
|
</parent>
|
||||||
|
|
||||||
<properties>
|
<properties>
|
||||||
<protobuf.version>3.9.1</protobuf.version>
|
<protobuf.version>3.16.1</protobuf.version>
|
||||||
<!-- follow https://github.com/grpc/grpc-java -->
|
<!-- follow https://github.com/grpc/grpc-java -->
|
||||||
<grpc.version>1.23.0</grpc.version>
|
<grpc.version>1.23.0</grpc.version>
|
||||||
<guava.version>30.0-jre</guava.version>
|
<guava.version>30.0-jre</guava.version>
|
||||||
@@ -60,7 +60,7 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.apache.httpcomponents</groupId>
|
<groupId>org.apache.httpcomponents</groupId>
|
||||||
<artifactId>httpmime</artifactId>
|
<artifactId>httpmime</artifactId>
|
||||||
<version>4.5.6</version>
|
<version>4.5.13</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>junit</groupId>
|
<groupId>junit</groupId>
|
||||||
@@ -135,7 +135,7 @@
|
|||||||
<plugin>
|
<plugin>
|
||||||
<groupId>org.sonatype.plugins</groupId>
|
<groupId>org.sonatype.plugins</groupId>
|
||||||
<artifactId>nexus-staging-maven-plugin</artifactId>
|
<artifactId>nexus-staging-maven-plugin</artifactId>
|
||||||
<version>1.6.7</version>
|
<version>1.6.8</version>
|
||||||
<extensions>true</extensions>
|
<extensions>true</extensions>
|
||||||
<configuration>
|
<configuration>
|
||||||
<serverId>ossrh</serverId>
|
<serverId>ossrh</serverId>
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
|
|
||||||
<groupId>com.github.chrislusf</groupId>
|
<groupId>com.github.chrislusf</groupId>
|
||||||
<artifactId>seaweedfs-client</artifactId>
|
<artifactId>seaweedfs-client</artifactId>
|
||||||
<version>1.6.6</version>
|
<version>2.85</version>
|
||||||
|
|
||||||
<parent>
|
<parent>
|
||||||
<groupId>org.sonatype.oss</groupId>
|
<groupId>org.sonatype.oss</groupId>
|
||||||
@@ -60,7 +60,7 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.apache.httpcomponents</groupId>
|
<groupId>org.apache.httpcomponents</groupId>
|
||||||
<artifactId>httpmime</artifactId>
|
<artifactId>httpmime</artifactId>
|
||||||
<version>4.5.6</version>
|
<version>4.5.13</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>junit</groupId>
|
<groupId>junit</groupId>
|
||||||
@@ -130,7 +130,7 @@
|
|||||||
<plugin>
|
<plugin>
|
||||||
<groupId>org.sonatype.plugins</groupId>
|
<groupId>org.sonatype.plugins</groupId>
|
||||||
<artifactId>nexus-staging-maven-plugin</artifactId>
|
<artifactId>nexus-staging-maven-plugin</artifactId>
|
||||||
<version>1.6.7</version>
|
<version>1.6.8</version>
|
||||||
<extensions>true</extensions>
|
<extensions>true</extensions>
|
||||||
<configuration>
|
<configuration>
|
||||||
<serverId>ossrh</serverId>
|
<serverId>ossrh</serverId>
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
|
|
||||||
<groupId>com.github.chrislusf</groupId>
|
<groupId>com.github.chrislusf</groupId>
|
||||||
<artifactId>seaweedfs-client</artifactId>
|
<artifactId>seaweedfs-client</artifactId>
|
||||||
<version>1.6.6</version>
|
<version>2.85</version>
|
||||||
|
|
||||||
<parent>
|
<parent>
|
||||||
<groupId>org.sonatype.oss</groupId>
|
<groupId>org.sonatype.oss</groupId>
|
||||||
@@ -60,7 +60,7 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.apache.httpcomponents</groupId>
|
<groupId>org.apache.httpcomponents</groupId>
|
||||||
<artifactId>httpmime</artifactId>
|
<artifactId>httpmime</artifactId>
|
||||||
<version>4.5.6</version>
|
<version>4.5.13</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>junit</groupId>
|
<groupId>junit</groupId>
|
||||||
|
|||||||
@@ -10,7 +10,7 @@ import java.util.List;
|
|||||||
|
|
||||||
public class ByteBufferPool {
|
public class ByteBufferPool {
|
||||||
|
|
||||||
private static final int MIN_BUFFER_SIZE = 8 * 1024 * 1024;
|
private static final int MIN_BUFFER_SIZE = 1 * 1024 * 1024;
|
||||||
private static final Logger LOG = LoggerFactory.getLogger(ByteBufferPool.class);
|
private static final Logger LOG = LoggerFactory.getLogger(ByteBufferPool.class);
|
||||||
|
|
||||||
private static final List<ByteBuffer> bufferList = new ArrayList<>();
|
private static final List<ByteBuffer> bufferList = new ArrayList<>();
|
||||||
|
|||||||
@@ -15,7 +15,7 @@ public class ChunkCache {
|
|||||||
}
|
}
|
||||||
this.cache = CacheBuilder.newBuilder()
|
this.cache = CacheBuilder.newBuilder()
|
||||||
.maximumSize(maxEntries)
|
.maximumSize(maxEntries)
|
||||||
.expireAfterAccess(1, TimeUnit.HOURS)
|
.expireAfterWrite(1, TimeUnit.HOURS)
|
||||||
.build();
|
.build();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -4,7 +4,6 @@ import com.google.common.base.Strings;
|
|||||||
import org.slf4j.Logger;
|
import org.slf4j.Logger;
|
||||||
import org.slf4j.LoggerFactory;
|
import org.slf4j.LoggerFactory;
|
||||||
|
|
||||||
import java.io.File;
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
import java.util.Iterator;
|
import java.util.Iterator;
|
||||||
@@ -15,7 +14,11 @@ public class FilerClient extends FilerGrpcClient {
|
|||||||
private static final Logger LOG = LoggerFactory.getLogger(FilerClient.class);
|
private static final Logger LOG = LoggerFactory.getLogger(FilerClient.class);
|
||||||
|
|
||||||
public FilerClient(String host, int grpcPort) {
|
public FilerClient(String host, int grpcPort) {
|
||||||
super(host, grpcPort);
|
super(host, grpcPort-10000, grpcPort);
|
||||||
|
}
|
||||||
|
|
||||||
|
public FilerClient(String host, int port, int grpcPort) {
|
||||||
|
super(host, port, grpcPort);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static String toFileId(FilerProto.FileId fid) {
|
public static String toFileId(FilerProto.FileId fid) {
|
||||||
@@ -59,24 +62,39 @@ public class FilerClient extends FilerGrpcClient {
|
|||||||
|
|
||||||
public static FilerProto.Entry afterEntryDeserialization(FilerProto.Entry entry) {
|
public static FilerProto.Entry afterEntryDeserialization(FilerProto.Entry entry) {
|
||||||
if (entry.getChunksList().size() <= 0) {
|
if (entry.getChunksList().size() <= 0) {
|
||||||
return entry;
|
if (entry.getContent().isEmpty()) {
|
||||||
}
|
return entry;
|
||||||
String fileId = entry.getChunks(0).getFileId();
|
} else {
|
||||||
if (fileId != null && fileId.length() != 0) {
|
if (entry.getAttributes().getFileSize() <= 0) {
|
||||||
return entry;
|
FilerProto.Entry.Builder entryBuilder = entry.toBuilder();
|
||||||
}
|
FilerProto.FuseAttributes.Builder attrBuilder = entry.getAttributes().toBuilder();
|
||||||
FilerProto.Entry.Builder entryBuilder = entry.toBuilder();
|
attrBuilder.setFileSize(entry.getContent().size());
|
||||||
entryBuilder.clearChunks();
|
entryBuilder.setAttributes(attrBuilder);
|
||||||
for (FilerProto.FileChunk chunk : entry.getChunksList()) {
|
return entryBuilder.build();
|
||||||
FilerProto.FileChunk.Builder chunkBuilder = chunk.toBuilder();
|
}
|
||||||
chunkBuilder.setFileId(toFileId(chunk.getFid()));
|
|
||||||
String sourceFileId = toFileId(chunk.getSourceFid());
|
|
||||||
if (sourceFileId != null) {
|
|
||||||
chunkBuilder.setSourceFileId(sourceFileId);
|
|
||||||
}
|
}
|
||||||
entryBuilder.addChunks(chunkBuilder);
|
return entry;
|
||||||
|
} else {
|
||||||
|
FilerProto.Entry.Builder entryBuilder = entry.toBuilder();
|
||||||
|
entryBuilder.clearChunks();
|
||||||
|
long fileSize = 0;
|
||||||
|
for (FilerProto.FileChunk chunk : entry.getChunksList()) {
|
||||||
|
fileSize = Math.max(fileSize, chunk.getOffset()+chunk.getSize());
|
||||||
|
FilerProto.FileChunk.Builder chunkBuilder = chunk.toBuilder();
|
||||||
|
chunkBuilder.setFileId(toFileId(chunk.getFid()));
|
||||||
|
String sourceFileId = toFileId(chunk.getSourceFid());
|
||||||
|
if (sourceFileId != null) {
|
||||||
|
chunkBuilder.setSourceFileId(sourceFileId);
|
||||||
|
}
|
||||||
|
entryBuilder.addChunks(chunkBuilder);
|
||||||
|
}
|
||||||
|
if (entry.getAttributes().getFileSize() <= 0) {
|
||||||
|
FilerProto.FuseAttributes.Builder attrBuilder = entry.getAttributes().toBuilder();
|
||||||
|
attrBuilder.setFileSize(fileSize);
|
||||||
|
entryBuilder.setAttributes(attrBuilder);
|
||||||
|
}
|
||||||
|
return entryBuilder.build();
|
||||||
}
|
}
|
||||||
return entryBuilder.build();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean mkdirs(String path, int mode) {
|
public boolean mkdirs(String path, int mode) {
|
||||||
@@ -93,9 +111,9 @@ public class FilerClient extends FilerGrpcClient {
|
|||||||
if ("/".equals(path)) {
|
if ("/".equals(path)) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
File pathFile = new File(path);
|
String[] dirAndName = SeaweedUtil.toDirAndName(path);
|
||||||
String parent = pathFile.getParent().replace('\\','/');
|
String parent = dirAndName[0];
|
||||||
String name = pathFile.getName();
|
String name = dirAndName[1];
|
||||||
|
|
||||||
mkdirs(parent, mode, uid, gid, userName, groupNames);
|
mkdirs(parent, mode, uid, gid, userName, groupNames);
|
||||||
|
|
||||||
@@ -114,35 +132,32 @@ public class FilerClient extends FilerGrpcClient {
|
|||||||
|
|
||||||
public boolean mv(String oldPath, String newPath) {
|
public boolean mv(String oldPath, String newPath) {
|
||||||
|
|
||||||
File oldPathFile = new File(oldPath);
|
String[] oldDirAndName = SeaweedUtil.toDirAndName(oldPath);
|
||||||
String oldParent = oldPathFile.getParent().replace('\\','/');
|
String oldParent = oldDirAndName[0];
|
||||||
String oldName = oldPathFile.getName();
|
String oldName = oldDirAndName[1];
|
||||||
|
|
||||||
File newPathFile = new File(newPath);
|
String[] newDirAndName = SeaweedUtil.toDirAndName(newPath);
|
||||||
String newParent = newPathFile.getParent().replace('\\','/');
|
String newParent = newDirAndName[0];
|
||||||
String newName = newPathFile.getName();
|
String newName = newDirAndName[1];
|
||||||
|
|
||||||
return atomicRenameEntry(oldParent, oldName, newParent, newName);
|
return atomicRenameEntry(oldParent, oldName, newParent, newName);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean exists(String path){
|
public boolean exists(String path){
|
||||||
File pathFile = new File(path);
|
|
||||||
String parent = pathFile.getParent();
|
|
||||||
String entryName = pathFile.getName();
|
|
||||||
if(parent == null) {
|
|
||||||
parent = path;
|
|
||||||
entryName ="";
|
|
||||||
}
|
|
||||||
return lookupEntry(parent, entryName) != null;
|
|
||||||
|
|
||||||
|
String[] dirAndName = SeaweedUtil.toDirAndName(path);
|
||||||
|
String parent = dirAndName[0];
|
||||||
|
String entryName = dirAndName[1];
|
||||||
|
|
||||||
|
return lookupEntry(parent, entryName) != null;
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean rm(String path, boolean isRecursive, boolean ignoreRecusiveError) {
|
public boolean rm(String path, boolean isRecursive, boolean ignoreRecusiveError) {
|
||||||
|
|
||||||
File pathFile = new File(path);
|
String[] dirAndName = SeaweedUtil.toDirAndName(path);
|
||||||
String parent = pathFile.getParent().replace('\\','/');
|
String parent = dirAndName[0];
|
||||||
String name = pathFile.getName();
|
String name = dirAndName[1];
|
||||||
|
|
||||||
return deleteEntry(
|
return deleteEntry(
|
||||||
parent,
|
parent,
|
||||||
@@ -153,17 +168,19 @@ public class FilerClient extends FilerGrpcClient {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public boolean touch(String path, int mode) {
|
public boolean touch(String path, int mode) {
|
||||||
|
|
||||||
String currentUser = System.getProperty("user.name");
|
String currentUser = System.getProperty("user.name");
|
||||||
|
|
||||||
long now = System.currentTimeMillis() / 1000L;
|
long now = System.currentTimeMillis() / 1000L;
|
||||||
return touch(path, now, mode, 0, 0, currentUser, new String[]{});
|
return touch(path, now, mode, 0, 0, currentUser, new String[]{});
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean touch(String path, long modifiedTimeSecond, int mode, int uid, int gid, String userName, String[] groupNames) {
|
public boolean touch(String path, long modifiedTimeSecond, int mode, int uid, int gid, String userName, String[] groupNames) {
|
||||||
|
|
||||||
File pathFile = new File(path);
|
String[] dirAndName = SeaweedUtil.toDirAndName(path);
|
||||||
String parent = pathFile.getParent().replace('\\','/');
|
String parent = dirAndName[0];
|
||||||
String name = pathFile.getName();
|
String name = dirAndName[1];
|
||||||
|
|
||||||
FilerProto.Entry entry = lookupEntry(parent, name);
|
FilerProto.Entry entry = lookupEntry(parent, name);
|
||||||
if (entry == null) {
|
if (entry == null) {
|
||||||
@@ -351,6 +368,7 @@ public class FilerClient extends FilerGrpcClient {
|
|||||||
.setPathPrefix(prefix)
|
.setPathPrefix(prefix)
|
||||||
.setClientName(clientName)
|
.setClientName(clientName)
|
||||||
.setSinceNs(sinceNs)
|
.setSinceNs(sinceNs)
|
||||||
|
.setClientId(this.randomClientId)
|
||||||
.build()
|
.build()
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -11,6 +11,7 @@ import org.slf4j.LoggerFactory;
|
|||||||
import javax.net.ssl.SSLException;
|
import javax.net.ssl.SSLException;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
import java.util.Random;
|
||||||
import java.util.concurrent.TimeUnit;
|
import java.util.concurrent.TimeUnit;
|
||||||
|
|
||||||
public class FilerGrpcClient {
|
public class FilerGrpcClient {
|
||||||
@@ -30,6 +31,7 @@ public class FilerGrpcClient {
|
|||||||
public final int VOLUME_SERVER_ACCESS_PUBLIC_URL = 1;
|
public final int VOLUME_SERVER_ACCESS_PUBLIC_URL = 1;
|
||||||
public final int VOLUME_SERVER_ACCESS_FILER_PROXY = 2;
|
public final int VOLUME_SERVER_ACCESS_FILER_PROXY = 2;
|
||||||
public final Map<String, FilerProto.Locations> vidLocations = new HashMap<>();
|
public final Map<String, FilerProto.Locations> vidLocations = new HashMap<>();
|
||||||
|
protected int randomClientId;
|
||||||
private final ManagedChannel channel;
|
private final ManagedChannel channel;
|
||||||
private final SeaweedFilerGrpc.SeaweedFilerBlockingStub blockingStub;
|
private final SeaweedFilerGrpc.SeaweedFilerBlockingStub blockingStub;
|
||||||
private final SeaweedFilerGrpc.SeaweedFilerStub asyncStub;
|
private final SeaweedFilerGrpc.SeaweedFilerStub asyncStub;
|
||||||
@@ -40,11 +42,11 @@ public class FilerGrpcClient {
|
|||||||
private int volumeServerAccess = VOLUME_SERVER_ACCESS_DIRECT;
|
private int volumeServerAccess = VOLUME_SERVER_ACCESS_DIRECT;
|
||||||
private String filerAddress;
|
private String filerAddress;
|
||||||
|
|
||||||
public FilerGrpcClient(String host, int grpcPort) {
|
public FilerGrpcClient(String host, int port, int grpcPort) {
|
||||||
this(host, grpcPort, sslContext);
|
this(host, port, grpcPort, sslContext);
|
||||||
}
|
}
|
||||||
|
|
||||||
public FilerGrpcClient(String host, int grpcPort, SslContext sslContext) {
|
public FilerGrpcClient(String host, int port, int grpcPort, SslContext sslContext) {
|
||||||
|
|
||||||
this(sslContext == null ?
|
this(sslContext == null ?
|
||||||
ManagedChannelBuilder.forAddress(host, grpcPort).usePlaintext()
|
ManagedChannelBuilder.forAddress(host, grpcPort).usePlaintext()
|
||||||
@@ -54,7 +56,7 @@ public class FilerGrpcClient {
|
|||||||
.negotiationType(NegotiationType.TLS)
|
.negotiationType(NegotiationType.TLS)
|
||||||
.sslContext(sslContext));
|
.sslContext(sslContext));
|
||||||
|
|
||||||
filerAddress = String.format("%s:%d", host, grpcPort - 10000);
|
filerAddress = SeaweedUtil.joinHostPort(host, port);
|
||||||
|
|
||||||
FilerProto.GetFilerConfigurationResponse filerConfigurationResponse =
|
FilerProto.GetFilerConfigurationResponse filerConfigurationResponse =
|
||||||
this.getBlockingStub().getFilerConfiguration(
|
this.getBlockingStub().getFilerConfiguration(
|
||||||
@@ -62,6 +64,7 @@ public class FilerGrpcClient {
|
|||||||
cipher = filerConfigurationResponse.getCipher();
|
cipher = filerConfigurationResponse.getCipher();
|
||||||
collection = filerConfigurationResponse.getCollection();
|
collection = filerConfigurationResponse.getCollection();
|
||||||
replication = filerConfigurationResponse.getReplication();
|
replication = filerConfigurationResponse.getReplication();
|
||||||
|
randomClientId = new Random().nextInt();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,109 @@
|
|||||||
|
package seaweedfs.client;
|
||||||
|
|
||||||
|
import java.io.IOException;
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.Collections;
|
||||||
|
import java.util.Comparator;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
public class ReadChunks {
|
||||||
|
|
||||||
|
public static List<SeaweedRead.VisibleInterval> readResolvedChunks(List<FilerProto.FileChunk> chunkList) throws IOException {
|
||||||
|
List<Point> points = new ArrayList<>(chunkList.size() * 2);
|
||||||
|
for (FilerProto.FileChunk chunk : chunkList) {
|
||||||
|
points.add(new Point(chunk.getOffset(), chunk, true));
|
||||||
|
points.add(new Point(chunk.getOffset() + chunk.getSize(), chunk, false));
|
||||||
|
}
|
||||||
|
Collections.sort(points, new Comparator<Point>() {
|
||||||
|
@Override
|
||||||
|
public int compare(Point a, Point b) {
|
||||||
|
int x = (int) (a.x - b.x);
|
||||||
|
if (a.x != b.x) {
|
||||||
|
return (int) (a.x - b.x);
|
||||||
|
}
|
||||||
|
if (a.ts != b.ts) {
|
||||||
|
return (int) (a.ts - b.ts);
|
||||||
|
}
|
||||||
|
if (!a.isStart) {
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
long prevX = 0;
|
||||||
|
List<SeaweedRead.VisibleInterval> visibles = new ArrayList<>();
|
||||||
|
ArrayList<Point> queue = new ArrayList<>();
|
||||||
|
for (Point point : points) {
|
||||||
|
if (point.isStart) {
|
||||||
|
if (queue.size() > 0) {
|
||||||
|
int lastIndex = queue.size() - 1;
|
||||||
|
Point lastPoint = queue.get(lastIndex);
|
||||||
|
if (point.x != prevX && lastPoint.ts < point.ts) {
|
||||||
|
addToVisibles(visibles, prevX, lastPoint, point);
|
||||||
|
prevX = point.x;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// insert into queue
|
||||||
|
for (int i = queue.size(); i >= 0; i--) {
|
||||||
|
if (i == 0 || queue.get(i - 1).ts <= point.ts) {
|
||||||
|
if (i == queue.size()) {
|
||||||
|
prevX = point.x;
|
||||||
|
}
|
||||||
|
queue.add(i, point);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
int lastIndex = queue.size() - 1;
|
||||||
|
int index = lastIndex;
|
||||||
|
Point startPoint = null;
|
||||||
|
for (; index >= 0; index--) {
|
||||||
|
startPoint = queue.get(index);
|
||||||
|
if (startPoint.ts == point.ts) {
|
||||||
|
queue.remove(index);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (index == lastIndex && startPoint != null) {
|
||||||
|
addToVisibles(visibles, prevX, startPoint, point);
|
||||||
|
prevX = point.x;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return visibles;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
private static void addToVisibles(List<SeaweedRead.VisibleInterval> visibles, long prevX, Point startPoint, Point point) {
|
||||||
|
if (prevX < point.x) {
|
||||||
|
FilerProto.FileChunk chunk = startPoint.chunk;
|
||||||
|
visibles.add(new SeaweedRead.VisibleInterval(
|
||||||
|
prevX,
|
||||||
|
point.x,
|
||||||
|
chunk.getFileId(),
|
||||||
|
chunk.getMtime(),
|
||||||
|
prevX - chunk.getOffset(),
|
||||||
|
chunk.getOffset() == prevX && chunk.getSize() == prevX - startPoint.x,
|
||||||
|
chunk.getCipherKey().toByteArray(),
|
||||||
|
chunk.getIsCompressed()
|
||||||
|
));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
static class Point {
|
||||||
|
long x;
|
||||||
|
long ts;
|
||||||
|
FilerProto.FileChunk chunk;
|
||||||
|
boolean isStart;
|
||||||
|
|
||||||
|
public Point(long x, FilerProto.FileChunk chunk, boolean isStart) {
|
||||||
|
this.x = x;
|
||||||
|
this.ts = chunk.getMtime();
|
||||||
|
this.chunk = chunk;
|
||||||
|
this.isStart = isStart;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,23 @@
|
|||||||
|
package seaweedfs.client;
|
||||||
|
|
||||||
|
import java.io.IOException;
|
||||||
|
|
||||||
|
public class RemoteUtil {
|
||||||
|
public static boolean isInRemoteOnly(FilerProto.Entry entry) {
|
||||||
|
if (entry.getChunksList() == null || entry.getChunksList().isEmpty()) {
|
||||||
|
return entry.getRemoteEntry() != null && entry.getRemoteEntry().getRemoteSize() > 0;
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static FilerProto.Entry downloadRemoteEntry(FilerClient filerClient, String fullpath, FilerProto.Entry entry) throws IOException {
|
||||||
|
String dir = SeaweedOutputStream.getParentDirectory(fullpath);
|
||||||
|
String name = SeaweedOutputStream.getFileName(fullpath);
|
||||||
|
|
||||||
|
final FilerProto.CacheRemoteObjectToLocalClusterResponse response = filerClient.getBlockingStub()
|
||||||
|
.cacheRemoteObjectToLocalCluster(FilerProto.CacheRemoteObjectToLocalClusterRequest.newBuilder()
|
||||||
|
.setDirectory(dir).setName(name).build());
|
||||||
|
|
||||||
|
return response.getEntry();
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -19,9 +19,9 @@ public class SeaweedInputStream extends InputStream {
|
|||||||
|
|
||||||
private final FilerClient filerClient;
|
private final FilerClient filerClient;
|
||||||
private final String path;
|
private final String path;
|
||||||
private final FilerProto.Entry entry;
|
|
||||||
private final List<SeaweedRead.VisibleInterval> visibleIntervalList;
|
private final List<SeaweedRead.VisibleInterval> visibleIntervalList;
|
||||||
private final long contentLength;
|
private final long contentLength;
|
||||||
|
private FilerProto.Entry entry;
|
||||||
|
|
||||||
private long position = 0; // cursor of the file
|
private long position = 0; // cursor of the file
|
||||||
|
|
||||||
@@ -35,10 +35,14 @@ public class SeaweedInputStream extends InputStream {
|
|||||||
this.entry = filerClient.lookupEntry(
|
this.entry = filerClient.lookupEntry(
|
||||||
SeaweedOutputStream.getParentDirectory(fullpath),
|
SeaweedOutputStream.getParentDirectory(fullpath),
|
||||||
SeaweedOutputStream.getFileName(fullpath));
|
SeaweedOutputStream.getFileName(fullpath));
|
||||||
if(entry == null){
|
if (entry == null) {
|
||||||
throw new FileNotFoundException();
|
throw new FileNotFoundException();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (RemoteUtil.isInRemoteOnly(entry)) {
|
||||||
|
entry = RemoteUtil.downloadRemoteEntry(filerClient, fullpath, entry);
|
||||||
|
}
|
||||||
|
|
||||||
this.contentLength = SeaweedRead.fileSize(entry);
|
this.contentLength = SeaweedRead.fileSize(entry);
|
||||||
|
|
||||||
this.visibleIntervalList = SeaweedRead.nonOverlappingVisibleIntervals(filerClient, entry.getChunksList());
|
this.visibleIntervalList = SeaweedRead.nonOverlappingVisibleIntervals(filerClient, entry.getChunksList());
|
||||||
@@ -54,6 +58,11 @@ public class SeaweedInputStream extends InputStream {
|
|||||||
this.filerClient = filerClient;
|
this.filerClient = filerClient;
|
||||||
this.path = path;
|
this.path = path;
|
||||||
this.entry = entry;
|
this.entry = entry;
|
||||||
|
|
||||||
|
if (RemoteUtil.isInRemoteOnly(entry)) {
|
||||||
|
this.entry = RemoteUtil.downloadRemoteEntry(filerClient, path, entry);
|
||||||
|
}
|
||||||
|
|
||||||
this.contentLength = SeaweedRead.fileSize(entry);
|
this.contentLength = SeaweedRead.fileSize(entry);
|
||||||
|
|
||||||
this.visibleIntervalList = SeaweedRead.nonOverlappingVisibleIntervals(filerClient, entry.getChunksList());
|
this.visibleIntervalList = SeaweedRead.nonOverlappingVisibleIntervals(filerClient, entry.getChunksList());
|
||||||
@@ -111,8 +120,8 @@ public class SeaweedInputStream extends InputStream {
|
|||||||
long bytesRead = 0;
|
long bytesRead = 0;
|
||||||
int len = buf.remaining();
|
int len = buf.remaining();
|
||||||
int start = (int) this.position;
|
int start = (int) this.position;
|
||||||
if (start+len <= entry.getContent().size()) {
|
if (start + len <= entry.getContent().size()) {
|
||||||
entry.getContent().substring(start, start+len).copyTo(buf);
|
entry.getContent().substring(start, start + len).copyTo(buf);
|
||||||
} else {
|
} else {
|
||||||
bytesRead = SeaweedRead.read(this.filerClient, this.visibleIntervalList, this.position, buf, SeaweedRead.fileSize(entry));
|
bytesRead = SeaweedRead.read(this.filerClient, this.visibleIntervalList, this.position, buf, SeaweedRead.fileSize(entry));
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -32,10 +32,10 @@ public class SeaweedOutputStream extends OutputStream {
|
|||||||
private long lastTotalAppendOffset = 0;
|
private long lastTotalAppendOffset = 0;
|
||||||
private ByteBuffer buffer;
|
private ByteBuffer buffer;
|
||||||
private long outputIndex;
|
private long outputIndex;
|
||||||
private String replication = "000";
|
private String replication = "";
|
||||||
|
|
||||||
public SeaweedOutputStream(FilerClient filerClient, final String fullpath) {
|
public SeaweedOutputStream(FilerClient filerClient, final String fullpath) {
|
||||||
this(filerClient, fullpath, "000");
|
this(filerClient, fullpath, "");
|
||||||
}
|
}
|
||||||
|
|
||||||
public SeaweedOutputStream(FilerClient filerClient, final String fullpath, final String replication) {
|
public SeaweedOutputStream(FilerClient filerClient, final String fullpath, final String replication) {
|
||||||
|
|||||||
@@ -64,10 +64,11 @@ public class SeaweedRead {
|
|||||||
startOffset += gap;
|
startOffset += gap;
|
||||||
}
|
}
|
||||||
|
|
||||||
FilerProto.Locations locations = knownLocations.get(parseVolumeId(chunkView.fileId));
|
String volumeId = parseVolumeId(chunkView.fileId);
|
||||||
|
FilerProto.Locations locations = knownLocations.get(volumeId);
|
||||||
if (locations == null || locations.getLocationsCount() == 0) {
|
if (locations == null || locations.getLocationsCount() == 0) {
|
||||||
LOG.error("failed to locate {}", chunkView.fileId);
|
LOG.error("failed to locate {}", chunkView.fileId);
|
||||||
// log here!
|
volumeIdCache.clearLocations(volumeId);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -225,96 +226,8 @@ public class SeaweedRead {
|
|||||||
|
|
||||||
chunkList = FileChunkManifest.resolveChunkManifest(filerClient, chunkList);
|
chunkList = FileChunkManifest.resolveChunkManifest(filerClient, chunkList);
|
||||||
|
|
||||||
FilerProto.FileChunk[] chunks = chunkList.toArray(new FilerProto.FileChunk[0]);
|
return ReadChunks.readResolvedChunks(chunkList);
|
||||||
Arrays.sort(chunks, new Comparator<FilerProto.FileChunk>() {
|
|
||||||
@Override
|
|
||||||
public int compare(FilerProto.FileChunk a, FilerProto.FileChunk b) {
|
|
||||||
// if just a.getMtime() - b.getMtime(), it will overflow!
|
|
||||||
if (a.getMtime() < b.getMtime()) {
|
|
||||||
return -1;
|
|
||||||
} else if (a.getMtime() > b.getMtime()) {
|
|
||||||
return 1;
|
|
||||||
}
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
List<VisibleInterval> visibles = new ArrayList<>();
|
|
||||||
for (FilerProto.FileChunk chunk : chunks) {
|
|
||||||
List<VisibleInterval> newVisibles = new ArrayList<>();
|
|
||||||
visibles = mergeIntoVisibles(visibles, newVisibles, chunk);
|
|
||||||
}
|
|
||||||
|
|
||||||
return visibles;
|
|
||||||
}
|
|
||||||
|
|
||||||
private static List<VisibleInterval> mergeIntoVisibles(List<VisibleInterval> visibles,
|
|
||||||
List<VisibleInterval> newVisibles,
|
|
||||||
FilerProto.FileChunk chunk) {
|
|
||||||
VisibleInterval newV = new VisibleInterval(
|
|
||||||
chunk.getOffset(),
|
|
||||||
chunk.getOffset() + chunk.getSize(),
|
|
||||||
chunk.getFileId(),
|
|
||||||
chunk.getMtime(),
|
|
||||||
0,
|
|
||||||
true,
|
|
||||||
chunk.getCipherKey().toByteArray(),
|
|
||||||
chunk.getIsCompressed()
|
|
||||||
);
|
|
||||||
|
|
||||||
// easy cases to speed up
|
|
||||||
if (visibles.size() == 0) {
|
|
||||||
visibles.add(newV);
|
|
||||||
return visibles;
|
|
||||||
}
|
|
||||||
if (visibles.get(visibles.size() - 1).stop <= chunk.getOffset()) {
|
|
||||||
visibles.add(newV);
|
|
||||||
return visibles;
|
|
||||||
}
|
|
||||||
|
|
||||||
for (VisibleInterval v : visibles) {
|
|
||||||
if (v.start < chunk.getOffset() && chunk.getOffset() < v.stop) {
|
|
||||||
newVisibles.add(new VisibleInterval(
|
|
||||||
v.start,
|
|
||||||
chunk.getOffset(),
|
|
||||||
v.fileId,
|
|
||||||
v.modifiedTime,
|
|
||||||
v.chunkOffset,
|
|
||||||
false,
|
|
||||||
v.cipherKey,
|
|
||||||
v.isCompressed
|
|
||||||
));
|
|
||||||
}
|
|
||||||
long chunkStop = chunk.getOffset() + chunk.getSize();
|
|
||||||
if (v.start < chunkStop && chunkStop < v.stop) {
|
|
||||||
newVisibles.add(new VisibleInterval(
|
|
||||||
chunkStop,
|
|
||||||
v.stop,
|
|
||||||
v.fileId,
|
|
||||||
v.modifiedTime,
|
|
||||||
v.chunkOffset + (chunkStop - v.start),
|
|
||||||
false,
|
|
||||||
v.cipherKey,
|
|
||||||
v.isCompressed
|
|
||||||
));
|
|
||||||
}
|
|
||||||
if (chunkStop <= v.start || v.stop <= chunk.getOffset()) {
|
|
||||||
newVisibles.add(v);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
newVisibles.add(newV);
|
|
||||||
|
|
||||||
// keep everything sorted
|
|
||||||
for (int i = newVisibles.size() - 1; i >= 0; i--) {
|
|
||||||
if (i > 0 && newV.start < newVisibles.get(i - 1).start) {
|
|
||||||
newVisibles.set(i, newVisibles.get(i - 1));
|
|
||||||
} else {
|
|
||||||
newVisibles.set(i, newV);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return newVisibles;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public static String parseVolumeId(String fileId) {
|
public static String parseVolumeId(String fileId) {
|
||||||
|
|||||||
@@ -27,4 +27,30 @@ public class SeaweedUtil {
|
|||||||
public static CloseableHttpClient getClosableHttpClient() {
|
public static CloseableHttpClient getClosableHttpClient() {
|
||||||
return httpClient;
|
return httpClient;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static String[] toDirAndName(String fullpath) {
|
||||||
|
if (fullpath == null) {
|
||||||
|
return new String[]{"/", ""};
|
||||||
|
}
|
||||||
|
if (fullpath.endsWith("/")) {
|
||||||
|
fullpath = fullpath.substring(0, fullpath.length() - 1);
|
||||||
|
}
|
||||||
|
if (fullpath.length() == 0) {
|
||||||
|
return new String[]{"/", ""};
|
||||||
|
}
|
||||||
|
int sep = fullpath.lastIndexOf("/");
|
||||||
|
String parent = sep == 0 ? "/" : fullpath.substring(0, sep);
|
||||||
|
String name = fullpath.substring(sep + 1);
|
||||||
|
return new String[]{parent, name};
|
||||||
|
}
|
||||||
|
|
||||||
|
public static String joinHostPort(String host, int port) {
|
||||||
|
if (host.startsWith("[") && host.endsWith("]")) {
|
||||||
|
return host + ":" + port;
|
||||||
|
}
|
||||||
|
if (host.indexOf(':')>=0) {
|
||||||
|
return "[" + host + "]:" + port;
|
||||||
|
}
|
||||||
|
return host + ":" + port;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -29,11 +29,31 @@ public class SeaweedWrite {
|
|||||||
final byte[] bytes,
|
final byte[] bytes,
|
||||||
final long bytesOffset, final long bytesLength,
|
final long bytesOffset, final long bytesLength,
|
||||||
final String path) throws IOException {
|
final String path) throws IOException {
|
||||||
FilerProto.FileChunk.Builder chunkBuilder = writeChunk(
|
|
||||||
replication, filerClient, offset, bytes, bytesOffset, bytesLength, path);
|
IOException lastException = null;
|
||||||
synchronized (entry) {
|
for (long waitTime = 1000L; waitTime < 10 * 1000; waitTime += waitTime / 2) {
|
||||||
entry.addChunks(chunkBuilder);
|
try {
|
||||||
|
FilerProto.FileChunk.Builder chunkBuilder = writeChunk(
|
||||||
|
replication, filerClient, offset, bytes, bytesOffset, bytesLength, path);
|
||||||
|
lastException = null;
|
||||||
|
synchronized (entry) {
|
||||||
|
entry.addChunks(chunkBuilder);
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
} catch (IOException ioe) {
|
||||||
|
LOG.debug("writeData:{}", ioe);
|
||||||
|
lastException = ioe;
|
||||||
|
}
|
||||||
|
try {
|
||||||
|
Thread.sleep(waitTime);
|
||||||
|
} catch (InterruptedException e) {
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (lastException != null) {
|
||||||
|
throw lastException;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public static FilerProto.FileChunk.Builder writeChunk(final String replication,
|
public static FilerProto.FileChunk.Builder writeChunk(final String replication,
|
||||||
@@ -59,7 +79,7 @@ public class SeaweedWrite {
|
|||||||
String fileId = response.getFileId();
|
String fileId = response.getFileId();
|
||||||
String auth = response.getAuth();
|
String auth = response.getAuth();
|
||||||
|
|
||||||
String targetUrl = filerClient.getChunkUrl(fileId, response.getUrl(), response.getPublicUrl());
|
String targetUrl = filerClient.getChunkUrl(fileId, response.getLocation().getUrl(), response.getLocation().getPublicUrl());
|
||||||
|
|
||||||
ByteString cipherKeyString = com.google.protobuf.ByteString.EMPTY;
|
ByteString cipherKeyString = com.google.protobuf.ByteString.EMPTY;
|
||||||
byte[] cipherKey = null;
|
byte[] cipherKey = null;
|
||||||
|
|||||||
@@ -15,7 +15,7 @@ public class VolumeIdCache {
|
|||||||
}
|
}
|
||||||
this.cache = CacheBuilder.newBuilder()
|
this.cache = CacheBuilder.newBuilder()
|
||||||
.maximumSize(maxEntries)
|
.maximumSize(maxEntries)
|
||||||
.expireAfterAccess(5, TimeUnit.MINUTES)
|
.expireAfterWrite(5, TimeUnit.MINUTES)
|
||||||
.build();
|
.build();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -26,6 +26,13 @@ public class VolumeIdCache {
|
|||||||
return this.cache.getIfPresent(volumeId);
|
return this.cache.getIfPresent(volumeId);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void clearLocations(String volumeId) {
|
||||||
|
if (this.cache == null) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
this.cache.invalidate(volumeId);
|
||||||
|
}
|
||||||
|
|
||||||
public void setLocations(String volumeId, FilerProto.Locations locations) {
|
public void setLocations(String volumeId, FilerProto.Locations locations) {
|
||||||
if (this.cache == null) {
|
if (this.cache == null) {
|
||||||
return;
|
return;
|
||||||
|
|||||||
@@ -30,6 +30,8 @@ service SeaweedFiler {
|
|||||||
|
|
||||||
rpc AtomicRenameEntry (AtomicRenameEntryRequest) returns (AtomicRenameEntryResponse) {
|
rpc AtomicRenameEntry (AtomicRenameEntryRequest) returns (AtomicRenameEntryResponse) {
|
||||||
}
|
}
|
||||||
|
rpc StreamRenameEntry (StreamRenameEntryRequest) returns (stream StreamRenameEntryResponse) {
|
||||||
|
}
|
||||||
|
|
||||||
rpc AssignVolume (AssignVolumeRequest) returns (AssignVolumeResponse) {
|
rpc AssignVolume (AssignVolumeRequest) returns (AssignVolumeResponse) {
|
||||||
}
|
}
|
||||||
@@ -67,6 +69,8 @@ service SeaweedFiler {
|
|||||||
rpc KvPut (KvPutRequest) returns (KvPutResponse) {
|
rpc KvPut (KvPutRequest) returns (KvPutResponse) {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
rpc CacheRemoteObjectToLocalCluster (CacheRemoteObjectToLocalClusterRequest) returns (CacheRemoteObjectToLocalClusterResponse) {
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//////////////////////////////////////////////////
|
//////////////////////////////////////////////////
|
||||||
@@ -92,6 +96,13 @@ message ListEntriesResponse {
|
|||||||
Entry entry = 1;
|
Entry entry = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
message RemoteEntry {
|
||||||
|
string storage_name = 1;
|
||||||
|
int64 last_local_sync_ts_ns = 2;
|
||||||
|
string remote_e_tag = 3;
|
||||||
|
int64 remote_mtime = 4;
|
||||||
|
int64 remote_size = 5;
|
||||||
|
}
|
||||||
message Entry {
|
message Entry {
|
||||||
string name = 1;
|
string name = 1;
|
||||||
bool is_directory = 2;
|
bool is_directory = 2;
|
||||||
@@ -101,6 +112,8 @@ message Entry {
|
|||||||
bytes hard_link_id = 7;
|
bytes hard_link_id = 7;
|
||||||
int32 hard_link_counter = 8; // only exists in hard link meta data
|
int32 hard_link_counter = 8; // only exists in hard link meta data
|
||||||
bytes content = 9; // if not empty, the file content
|
bytes content = 9; // if not empty, the file content
|
||||||
|
|
||||||
|
RemoteEntry remote_entry = 10;
|
||||||
}
|
}
|
||||||
|
|
||||||
message FullEntry {
|
message FullEntry {
|
||||||
@@ -208,11 +221,24 @@ message AtomicRenameEntryRequest {
|
|||||||
string old_name = 2;
|
string old_name = 2;
|
||||||
string new_directory = 3;
|
string new_directory = 3;
|
||||||
string new_name = 4;
|
string new_name = 4;
|
||||||
|
repeated int32 signatures = 5;
|
||||||
}
|
}
|
||||||
|
|
||||||
message AtomicRenameEntryResponse {
|
message AtomicRenameEntryResponse {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
message StreamRenameEntryRequest {
|
||||||
|
string old_directory = 1;
|
||||||
|
string old_name = 2;
|
||||||
|
string new_directory = 3;
|
||||||
|
string new_name = 4;
|
||||||
|
repeated int32 signatures = 5;
|
||||||
|
}
|
||||||
|
message StreamRenameEntryResponse {
|
||||||
|
string directory = 1;
|
||||||
|
EventNotification event_notification = 2;
|
||||||
|
int64 ts_ns = 3;
|
||||||
|
}
|
||||||
message AssignVolumeRequest {
|
message AssignVolumeRequest {
|
||||||
int32 count = 1;
|
int32 count = 1;
|
||||||
string collection = 2;
|
string collection = 2;
|
||||||
@@ -221,18 +247,18 @@ message AssignVolumeRequest {
|
|||||||
string data_center = 5;
|
string data_center = 5;
|
||||||
string path = 6;
|
string path = 6;
|
||||||
string rack = 7;
|
string rack = 7;
|
||||||
|
string data_node = 9;
|
||||||
string disk_type = 8;
|
string disk_type = 8;
|
||||||
}
|
}
|
||||||
|
|
||||||
message AssignVolumeResponse {
|
message AssignVolumeResponse {
|
||||||
string file_id = 1;
|
string file_id = 1;
|
||||||
string url = 2;
|
|
||||||
string public_url = 3;
|
|
||||||
int32 count = 4;
|
int32 count = 4;
|
||||||
string auth = 5;
|
string auth = 5;
|
||||||
string collection = 6;
|
string collection = 6;
|
||||||
string replication = 7;
|
string replication = 7;
|
||||||
string error = 8;
|
string error = 8;
|
||||||
|
Location location = 9;
|
||||||
}
|
}
|
||||||
|
|
||||||
message LookupVolumeRequest {
|
message LookupVolumeRequest {
|
||||||
@@ -246,6 +272,7 @@ message Locations {
|
|||||||
message Location {
|
message Location {
|
||||||
string url = 1;
|
string url = 1;
|
||||||
string public_url = 2;
|
string public_url = 2;
|
||||||
|
uint32 grpc_port = 3;
|
||||||
}
|
}
|
||||||
message LookupVolumeResponse {
|
message LookupVolumeResponse {
|
||||||
map<string, Locations> locations_map = 1;
|
map<string, Locations> locations_map = 1;
|
||||||
@@ -292,6 +319,8 @@ message GetFilerConfigurationResponse {
|
|||||||
int32 signature = 8;
|
int32 signature = 8;
|
||||||
string metrics_address = 9;
|
string metrics_address = 9;
|
||||||
int32 metrics_interval_sec = 10;
|
int32 metrics_interval_sec = 10;
|
||||||
|
string version = 11;
|
||||||
|
string cluster_id = 12;
|
||||||
}
|
}
|
||||||
|
|
||||||
message SubscribeMetadataRequest {
|
message SubscribeMetadataRequest {
|
||||||
@@ -299,6 +328,8 @@ message SubscribeMetadataRequest {
|
|||||||
string path_prefix = 2;
|
string path_prefix = 2;
|
||||||
int64 since_ns = 3;
|
int64 since_ns = 3;
|
||||||
int32 signature = 4;
|
int32 signature = 4;
|
||||||
|
repeated string path_prefixes = 6;
|
||||||
|
int32 client_id = 7;
|
||||||
}
|
}
|
||||||
message SubscribeMetadataResponse {
|
message SubscribeMetadataResponse {
|
||||||
string directory = 1;
|
string directory = 1;
|
||||||
@@ -323,6 +354,7 @@ message KeepConnectedResponse {
|
|||||||
message LocateBrokerRequest {
|
message LocateBrokerRequest {
|
||||||
string resource = 1;
|
string resource = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
message LocateBrokerResponse {
|
message LocateBrokerResponse {
|
||||||
bool found = 1;
|
bool found = 1;
|
||||||
// if found, send the exact address
|
// if found, send the exact address
|
||||||
@@ -334,7 +366,9 @@ message LocateBrokerResponse {
|
|||||||
repeated Resource resources = 2;
|
repeated Resource resources = 2;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/////////////////////////
|
||||||
// Key-Value operations
|
// Key-Value operations
|
||||||
|
/////////////////////////
|
||||||
message KvGetRequest {
|
message KvGetRequest {
|
||||||
bytes key = 1;
|
bytes key = 1;
|
||||||
}
|
}
|
||||||
@@ -350,7 +384,9 @@ message KvPutResponse {
|
|||||||
string error = 1;
|
string error = 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/////////////////////////
|
||||||
// path-based configurations
|
// path-based configurations
|
||||||
|
/////////////////////////
|
||||||
message FilerConf {
|
message FilerConf {
|
||||||
int32 version = 1;
|
int32 version = 1;
|
||||||
message PathConf {
|
message PathConf {
|
||||||
@@ -362,6 +398,20 @@ message FilerConf {
|
|||||||
bool fsync = 6;
|
bool fsync = 6;
|
||||||
uint32 volume_growth_count = 7;
|
uint32 volume_growth_count = 7;
|
||||||
bool read_only = 8;
|
bool read_only = 8;
|
||||||
|
string data_center = 9;
|
||||||
|
string rack = 10;
|
||||||
|
string data_node = 11;
|
||||||
}
|
}
|
||||||
repeated PathConf locations = 2;
|
repeated PathConf locations = 2;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/////////////////////////
|
||||||
|
// Remote Storage related
|
||||||
|
/////////////////////////
|
||||||
|
message CacheRemoteObjectToLocalClusterRequest {
|
||||||
|
string directory = 1;
|
||||||
|
string name = 2;
|
||||||
|
}
|
||||||
|
message CacheRemoteObjectToLocalClusterResponse {
|
||||||
|
Entry entry = 1;
|
||||||
|
}
|
||||||
|
|||||||
@@ -6,6 +6,7 @@ import org.junit.Test;
|
|||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
import java.util.Random;
|
||||||
|
|
||||||
public class SeaweedReadTest {
|
public class SeaweedReadTest {
|
||||||
|
|
||||||
@@ -13,17 +14,17 @@ public class SeaweedReadTest {
|
|||||||
public void testNonOverlappingVisibleIntervals() throws IOException {
|
public void testNonOverlappingVisibleIntervals() throws IOException {
|
||||||
List<FilerProto.FileChunk> chunks = new ArrayList<>();
|
List<FilerProto.FileChunk> chunks = new ArrayList<>();
|
||||||
chunks.add(FilerProto.FileChunk.newBuilder()
|
chunks.add(FilerProto.FileChunk.newBuilder()
|
||||||
.setFileId("aaa")
|
.setFileId("aaa")
|
||||||
.setOffset(0)
|
.setOffset(0)
|
||||||
.setSize(100)
|
.setSize(100)
|
||||||
.setMtime(1000)
|
.setMtime(1000)
|
||||||
.build());
|
.build());
|
||||||
chunks.add(FilerProto.FileChunk.newBuilder()
|
chunks.add(FilerProto.FileChunk.newBuilder()
|
||||||
.setFileId("bbb")
|
.setFileId("bbb")
|
||||||
.setOffset(100)
|
.setOffset(100)
|
||||||
.setSize(133)
|
.setSize(133)
|
||||||
.setMtime(2000)
|
.setMtime(2000)
|
||||||
.build());
|
.build());
|
||||||
|
|
||||||
List<SeaweedRead.VisibleInterval> visibleIntervals = SeaweedRead.nonOverlappingVisibleIntervals(null, chunks);
|
List<SeaweedRead.VisibleInterval> visibleIntervals = SeaweedRead.nonOverlappingVisibleIntervals(null, chunks);
|
||||||
for (SeaweedRead.VisibleInterval visibleInterval : visibleIntervals) {
|
for (SeaweedRead.VisibleInterval visibleInterval : visibleIntervals) {
|
||||||
@@ -61,4 +62,106 @@ public class SeaweedReadTest {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@Test
|
||||||
|
public void testReadResolvedChunks() throws IOException {
|
||||||
|
List<FilerProto.FileChunk> chunks = new ArrayList<>();
|
||||||
|
chunks.add(FilerProto.FileChunk.newBuilder()
|
||||||
|
.setFileId("a")
|
||||||
|
.setOffset(0)
|
||||||
|
.setSize(100)
|
||||||
|
.setMtime(1)
|
||||||
|
.build());
|
||||||
|
chunks.add(FilerProto.FileChunk.newBuilder()
|
||||||
|
.setFileId("b")
|
||||||
|
.setOffset(50)
|
||||||
|
.setSize(100)
|
||||||
|
.setMtime(2)
|
||||||
|
.build());
|
||||||
|
chunks.add(FilerProto.FileChunk.newBuilder()
|
||||||
|
.setFileId("c")
|
||||||
|
.setOffset(200)
|
||||||
|
.setSize(50)
|
||||||
|
.setMtime(3)
|
||||||
|
.build());
|
||||||
|
chunks.add(FilerProto.FileChunk.newBuilder()
|
||||||
|
.setFileId("d")
|
||||||
|
.setOffset(250)
|
||||||
|
.setSize(50)
|
||||||
|
.setMtime(4)
|
||||||
|
.build());
|
||||||
|
chunks.add(FilerProto.FileChunk.newBuilder()
|
||||||
|
.setFileId("e")
|
||||||
|
.setOffset(175)
|
||||||
|
.setSize(100)
|
||||||
|
.setMtime(5)
|
||||||
|
.build());
|
||||||
|
|
||||||
|
List<SeaweedRead.VisibleInterval> visibleIntervals = ReadChunks.readResolvedChunks(chunks);
|
||||||
|
for (SeaweedRead.VisibleInterval visibleInterval : visibleIntervals) {
|
||||||
|
System.out.println("visible:" + visibleInterval);
|
||||||
|
}
|
||||||
|
|
||||||
|
Assert.assertEquals(4, visibleIntervals.size());
|
||||||
|
|
||||||
|
SeaweedRead.VisibleInterval visibleInterval = visibleIntervals.get(0);
|
||||||
|
Assert.assertEquals(visibleInterval.start, 0);
|
||||||
|
Assert.assertEquals(visibleInterval.stop, 50);
|
||||||
|
Assert.assertEquals(visibleInterval.modifiedTime, 1);
|
||||||
|
Assert.assertEquals(visibleInterval.fileId, "a");
|
||||||
|
|
||||||
|
visibleInterval = visibleIntervals.get(1);
|
||||||
|
Assert.assertEquals(visibleInterval.start, 50);
|
||||||
|
Assert.assertEquals(visibleInterval.stop, 150);
|
||||||
|
Assert.assertEquals(visibleInterval.modifiedTime, 2);
|
||||||
|
Assert.assertEquals(visibleInterval.fileId, "b");
|
||||||
|
|
||||||
|
visibleInterval = visibleIntervals.get(2);
|
||||||
|
Assert.assertEquals(visibleInterval.start, 175);
|
||||||
|
Assert.assertEquals(visibleInterval.stop, 275);
|
||||||
|
Assert.assertEquals(visibleInterval.modifiedTime, 5);
|
||||||
|
Assert.assertEquals(visibleInterval.fileId, "e");
|
||||||
|
|
||||||
|
visibleInterval = visibleIntervals.get(3);
|
||||||
|
Assert.assertEquals(visibleInterval.start, 275);
|
||||||
|
Assert.assertEquals(visibleInterval.stop, 300);
|
||||||
|
Assert.assertEquals(visibleInterval.modifiedTime, 4);
|
||||||
|
Assert.assertEquals(visibleInterval.fileId, "d");
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@Test
|
||||||
|
public void testRandomizedReadResolvedChunks() throws IOException {
|
||||||
|
Random random = new Random();
|
||||||
|
int limit = 1024*1024;
|
||||||
|
long[] array = new long[limit];
|
||||||
|
List<FilerProto.FileChunk> chunks = new ArrayList<>();
|
||||||
|
for (long ts=0;ts<1024;ts++){
|
||||||
|
int x = random.nextInt(limit);
|
||||||
|
int y = random.nextInt(limit);
|
||||||
|
int size = Math.min(Math.abs(x-y), 1024);
|
||||||
|
chunks.add(randomWrite(array, Math.min(x,y), size, ts));
|
||||||
|
}
|
||||||
|
|
||||||
|
List<SeaweedRead.VisibleInterval> visibleIntervals = ReadChunks.readResolvedChunks(chunks);
|
||||||
|
for (SeaweedRead.VisibleInterval visibleInterval : visibleIntervals) {
|
||||||
|
System.out.println("visible:" + visibleInterval);
|
||||||
|
for (int i = (int) visibleInterval.start; i<visibleInterval.stop; i++) {
|
||||||
|
Assert.assertEquals(array[i], visibleInterval.modifiedTime);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
private FilerProto.FileChunk randomWrite(long[] array, int start, int size, long ts) {
|
||||||
|
for (int i=start;i<start+size;i++) {
|
||||||
|
array[i] = ts;
|
||||||
|
}
|
||||||
|
return FilerProto.FileChunk.newBuilder()
|
||||||
|
.setFileId("")
|
||||||
|
.setOffset(start)
|
||||||
|
.setSize(size)
|
||||||
|
.setMtime(ts)
|
||||||
|
.build();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -11,13 +11,13 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.github.chrislusf</groupId>
|
<groupId>com.github.chrislusf</groupId>
|
||||||
<artifactId>seaweedfs-client</artifactId>
|
<artifactId>seaweedfs-client</artifactId>
|
||||||
<version>1.6.6</version>
|
<version>2.85</version>
|
||||||
<scope>compile</scope>
|
<scope>compile</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.github.chrislusf</groupId>
|
<groupId>com.github.chrislusf</groupId>
|
||||||
<artifactId>seaweedfs-hadoop2-client</artifactId>
|
<artifactId>seaweedfs-hadoop2-client</artifactId>
|
||||||
<version>1.6.6</version>
|
<version>2.85</version>
|
||||||
<scope>compile</scope>
|
<scope>compile</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
@@ -29,4 +29,4 @@
|
|||||||
</dependencies>
|
</dependencies>
|
||||||
|
|
||||||
|
|
||||||
</project>
|
</project>
|
||||||
|
|||||||
@@ -86,7 +86,7 @@
|
|||||||
<plugin>
|
<plugin>
|
||||||
<groupId>org.sonatype.plugins</groupId>
|
<groupId>org.sonatype.plugins</groupId>
|
||||||
<artifactId>nexus-staging-maven-plugin</artifactId>
|
<artifactId>nexus-staging-maven-plugin</artifactId>
|
||||||
<version>1.6.7</version>
|
<version>1.6.8</version>
|
||||||
<extensions>true</extensions>
|
<extensions>true</extensions>
|
||||||
<configuration>
|
<configuration>
|
||||||
<serverId>ossrh</serverId>
|
<serverId>ossrh</serverId>
|
||||||
@@ -301,7 +301,7 @@
|
|||||||
</snapshotRepository>
|
</snapshotRepository>
|
||||||
</distributionManagement>
|
</distributionManagement>
|
||||||
<properties>
|
<properties>
|
||||||
<seaweedfs.client.version>1.6.6</seaweedfs.client.version>
|
<seaweedfs.client.version>2.85</seaweedfs.client.version>
|
||||||
<hadoop.version>2.9.2</hadoop.version>
|
<hadoop.version>2.9.2</hadoop.version>
|
||||||
</properties>
|
</properties>
|
||||||
</project>
|
</project>
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
<modelVersion>4.0.0</modelVersion>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
|
|
||||||
<properties>
|
<properties>
|
||||||
<seaweedfs.client.version>1.6.6</seaweedfs.client.version>
|
<seaweedfs.client.version>2.85</seaweedfs.client.version>
|
||||||
<hadoop.version>2.9.2</hadoop.version>
|
<hadoop.version>2.9.2</hadoop.version>
|
||||||
</properties>
|
</properties>
|
||||||
|
|
||||||
@@ -105,7 +105,7 @@
|
|||||||
<plugin>
|
<plugin>
|
||||||
<groupId>org.sonatype.plugins</groupId>
|
<groupId>org.sonatype.plugins</groupId>
|
||||||
<artifactId>nexus-staging-maven-plugin</artifactId>
|
<artifactId>nexus-staging-maven-plugin</artifactId>
|
||||||
<version>1.6.7</version>
|
<version>1.6.8</version>
|
||||||
<extensions>true</extensions>
|
<extensions>true</extensions>
|
||||||
<configuration>
|
<configuration>
|
||||||
<serverId>ossrh</serverId>
|
<serverId>ossrh</serverId>
|
||||||
|
|||||||
@@ -23,6 +23,7 @@ public class SeaweedFileSystem extends FileSystem {
|
|||||||
|
|
||||||
public static final String FS_SEAWEED_FILER_HOST = "fs.seaweed.filer.host";
|
public static final String FS_SEAWEED_FILER_HOST = "fs.seaweed.filer.host";
|
||||||
public static final String FS_SEAWEED_FILER_PORT = "fs.seaweed.filer.port";
|
public static final String FS_SEAWEED_FILER_PORT = "fs.seaweed.filer.port";
|
||||||
|
public static final String FS_SEAWEED_FILER_PORT_GRPC = "fs.seaweed.filer.port.grpc";
|
||||||
public static final int FS_SEAWEED_DEFAULT_PORT = 8888;
|
public static final int FS_SEAWEED_DEFAULT_PORT = 8888;
|
||||||
public static final String FS_SEAWEED_BUFFER_SIZE = "fs.seaweed.buffer.size";
|
public static final String FS_SEAWEED_BUFFER_SIZE = "fs.seaweed.buffer.size";
|
||||||
public static final String FS_SEAWEED_REPLICATION = "fs.seaweed.replication";
|
public static final String FS_SEAWEED_REPLICATION = "fs.seaweed.replication";
|
||||||
@@ -50,9 +51,6 @@ public class SeaweedFileSystem extends FileSystem {
|
|||||||
// get host information from uri (overrides info in conf)
|
// get host information from uri (overrides info in conf)
|
||||||
String host = uri.getHost();
|
String host = uri.getHost();
|
||||||
host = (host == null) ? conf.get(FS_SEAWEED_FILER_HOST, "localhost") : host;
|
host = (host == null) ? conf.get(FS_SEAWEED_FILER_HOST, "localhost") : host;
|
||||||
if (host == null) {
|
|
||||||
throw new IOException("Invalid host specified");
|
|
||||||
}
|
|
||||||
conf.set(FS_SEAWEED_FILER_HOST, host);
|
conf.set(FS_SEAWEED_FILER_HOST, host);
|
||||||
|
|
||||||
// get port information from uri, (overrides info in conf)
|
// get port information from uri, (overrides info in conf)
|
||||||
@@ -60,10 +58,12 @@ public class SeaweedFileSystem extends FileSystem {
|
|||||||
port = (port == -1) ? FS_SEAWEED_DEFAULT_PORT : port;
|
port = (port == -1) ? FS_SEAWEED_DEFAULT_PORT : port;
|
||||||
conf.setInt(FS_SEAWEED_FILER_PORT, port);
|
conf.setInt(FS_SEAWEED_FILER_PORT, port);
|
||||||
|
|
||||||
|
int grpcPort = conf.getInt(FS_SEAWEED_FILER_PORT_GRPC, port+10000);
|
||||||
|
|
||||||
setConf(conf);
|
setConf(conf);
|
||||||
this.uri = uri;
|
this.uri = uri;
|
||||||
|
|
||||||
seaweedFileSystemStore = new SeaweedFileSystemStore(host, port, conf);
|
seaweedFileSystemStore = new SeaweedFileSystemStore(host, port, grpcPort, conf);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -27,9 +27,8 @@ public class SeaweedFileSystemStore {
|
|||||||
private FilerClient filerClient;
|
private FilerClient filerClient;
|
||||||
private Configuration conf;
|
private Configuration conf;
|
||||||
|
|
||||||
public SeaweedFileSystemStore(String host, int port, Configuration conf) {
|
public SeaweedFileSystemStore(String host, int port, int grpcPort, Configuration conf) {
|
||||||
int grpcPort = 10000 + port;
|
filerClient = new FilerClient(host, port, grpcPort);
|
||||||
filerClient = new FilerClient(host, grpcPort);
|
|
||||||
this.conf = conf;
|
this.conf = conf;
|
||||||
String volumeServerAccessMode = this.conf.get(FS_SEAWEED_VOLUME_SERVER_ACCESS, "direct");
|
String volumeServerAccessMode = this.conf.get(FS_SEAWEED_VOLUME_SERVER_ACCESS, "direct");
|
||||||
if (volumeServerAccessMode.equals("publicUrl")) {
|
if (volumeServerAccessMode.equals("publicUrl")) {
|
||||||
|
|||||||
@@ -86,7 +86,7 @@
|
|||||||
<plugin>
|
<plugin>
|
||||||
<groupId>org.sonatype.plugins</groupId>
|
<groupId>org.sonatype.plugins</groupId>
|
||||||
<artifactId>nexus-staging-maven-plugin</artifactId>
|
<artifactId>nexus-staging-maven-plugin</artifactId>
|
||||||
<version>1.6.7</version>
|
<version>1.6.8</version>
|
||||||
<extensions>true</extensions>
|
<extensions>true</extensions>
|
||||||
<configuration>
|
<configuration>
|
||||||
<serverId>ossrh</serverId>
|
<serverId>ossrh</serverId>
|
||||||
@@ -309,7 +309,7 @@
|
|||||||
</snapshotRepository>
|
</snapshotRepository>
|
||||||
</distributionManagement>
|
</distributionManagement>
|
||||||
<properties>
|
<properties>
|
||||||
<seaweedfs.client.version>1.6.6</seaweedfs.client.version>
|
<seaweedfs.client.version>2.85</seaweedfs.client.version>
|
||||||
<hadoop.version>3.1.1</hadoop.version>
|
<hadoop.version>3.1.1</hadoop.version>
|
||||||
</properties>
|
</properties>
|
||||||
</project>
|
</project>
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
<modelVersion>4.0.0</modelVersion>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
|
|
||||||
<properties>
|
<properties>
|
||||||
<seaweedfs.client.version>1.6.6</seaweedfs.client.version>
|
<seaweedfs.client.version>2.85</seaweedfs.client.version>
|
||||||
<hadoop.version>3.1.1</hadoop.version>
|
<hadoop.version>3.1.1</hadoop.version>
|
||||||
</properties>
|
</properties>
|
||||||
|
|
||||||
@@ -105,7 +105,7 @@
|
|||||||
<plugin>
|
<plugin>
|
||||||
<groupId>org.sonatype.plugins</groupId>
|
<groupId>org.sonatype.plugins</groupId>
|
||||||
<artifactId>nexus-staging-maven-plugin</artifactId>
|
<artifactId>nexus-staging-maven-plugin</artifactId>
|
||||||
<version>1.6.7</version>
|
<version>1.6.8</version>
|
||||||
<extensions>true</extensions>
|
<extensions>true</extensions>
|
||||||
<configuration>
|
<configuration>
|
||||||
<serverId>ossrh</serverId>
|
<serverId>ossrh</serverId>
|
||||||
|
|||||||
@@ -23,6 +23,7 @@ public class SeaweedFileSystem extends FileSystem {
|
|||||||
|
|
||||||
public static final String FS_SEAWEED_FILER_HOST = "fs.seaweed.filer.host";
|
public static final String FS_SEAWEED_FILER_HOST = "fs.seaweed.filer.host";
|
||||||
public static final String FS_SEAWEED_FILER_PORT = "fs.seaweed.filer.port";
|
public static final String FS_SEAWEED_FILER_PORT = "fs.seaweed.filer.port";
|
||||||
|
public static final String FS_SEAWEED_FILER_PORT_GRPC = "fs.seaweed.filer.port.grpc";
|
||||||
public static final int FS_SEAWEED_DEFAULT_PORT = 8888;
|
public static final int FS_SEAWEED_DEFAULT_PORT = 8888;
|
||||||
public static final String FS_SEAWEED_BUFFER_SIZE = "fs.seaweed.buffer.size";
|
public static final String FS_SEAWEED_BUFFER_SIZE = "fs.seaweed.buffer.size";
|
||||||
public static final String FS_SEAWEED_REPLICATION = "fs.seaweed.replication";
|
public static final String FS_SEAWEED_REPLICATION = "fs.seaweed.replication";
|
||||||
@@ -50,9 +51,6 @@ public class SeaweedFileSystem extends FileSystem {
|
|||||||
// get host information from uri (overrides info in conf)
|
// get host information from uri (overrides info in conf)
|
||||||
String host = uri.getHost();
|
String host = uri.getHost();
|
||||||
host = (host == null) ? conf.get(FS_SEAWEED_FILER_HOST, "localhost") : host;
|
host = (host == null) ? conf.get(FS_SEAWEED_FILER_HOST, "localhost") : host;
|
||||||
if (host == null) {
|
|
||||||
throw new IOException("Invalid host specified");
|
|
||||||
}
|
|
||||||
conf.set(FS_SEAWEED_FILER_HOST, host);
|
conf.set(FS_SEAWEED_FILER_HOST, host);
|
||||||
|
|
||||||
// get port information from uri, (overrides info in conf)
|
// get port information from uri, (overrides info in conf)
|
||||||
@@ -60,10 +58,12 @@ public class SeaweedFileSystem extends FileSystem {
|
|||||||
port = (port == -1) ? FS_SEAWEED_DEFAULT_PORT : port;
|
port = (port == -1) ? FS_SEAWEED_DEFAULT_PORT : port;
|
||||||
conf.setInt(FS_SEAWEED_FILER_PORT, port);
|
conf.setInt(FS_SEAWEED_FILER_PORT, port);
|
||||||
|
|
||||||
|
int grpcPort = conf.getInt(FS_SEAWEED_FILER_PORT_GRPC, port+10000);
|
||||||
|
|
||||||
setConf(conf);
|
setConf(conf);
|
||||||
this.uri = uri;
|
this.uri = uri;
|
||||||
|
|
||||||
seaweedFileSystemStore = new SeaweedFileSystemStore(host, port, conf);
|
seaweedFileSystemStore = new SeaweedFileSystemStore(host, port, grpcPort, conf);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -27,9 +27,8 @@ public class SeaweedFileSystemStore {
|
|||||||
private FilerClient filerClient;
|
private FilerClient filerClient;
|
||||||
private Configuration conf;
|
private Configuration conf;
|
||||||
|
|
||||||
public SeaweedFileSystemStore(String host, int port, Configuration conf) {
|
public SeaweedFileSystemStore(String host, int port, int grpcPort, Configuration conf) {
|
||||||
int grpcPort = 10000 + port;
|
filerClient = new FilerClient(host, port, grpcPort);
|
||||||
filerClient = new FilerClient(host, grpcPort);
|
|
||||||
this.conf = conf;
|
this.conf = conf;
|
||||||
String volumeServerAccessMode = this.conf.get(FS_SEAWEED_VOLUME_SERVER_ACCESS, "direct");
|
String volumeServerAccessMode = this.conf.get(FS_SEAWEED_VOLUME_SERVER_ACCESS, "direct");
|
||||||
if (volumeServerAccessMode.equals("publicUrl")) {
|
if (volumeServerAccessMode.equals("publicUrl")) {
|
||||||
|
|||||||
+2003
-1371
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
Binary file not shown.
@@ -2,14 +2,15 @@ package basic
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
"io"
|
||||||
|
"os"
|
||||||
|
"strings"
|
||||||
|
"testing"
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/aws"
|
"github.com/aws/aws-sdk-go/aws"
|
||||||
"github.com/aws/aws-sdk-go/aws/awserr"
|
"github.com/aws/aws-sdk-go/aws/awserr"
|
||||||
"github.com/aws/aws-sdk-go/aws/session"
|
"github.com/aws/aws-sdk-go/aws/session"
|
||||||
"github.com/aws/aws-sdk-go/service/s3"
|
"github.com/aws/aws-sdk-go/service/s3"
|
||||||
"io/ioutil"
|
|
||||||
"os"
|
|
||||||
"strings"
|
|
||||||
"testing"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
var (
|
var (
|
||||||
@@ -108,8 +109,8 @@ func TestListBucket(t *testing.T) {
|
|||||||
func TestListObjectV2(t *testing.T) {
|
func TestListObjectV2(t *testing.T) {
|
||||||
|
|
||||||
listObj, err := svc.ListObjectsV2(&s3.ListObjectsV2Input{
|
listObj, err := svc.ListObjectsV2(&s3.ListObjectsV2Input{
|
||||||
Bucket: aws.String(Bucket),
|
Bucket: aws.String(Bucket),
|
||||||
Prefix: aws.String("foo"),
|
Prefix: aws.String("foo"),
|
||||||
Delimiter: aws.String("/"),
|
Delimiter: aws.String("/"),
|
||||||
})
|
})
|
||||||
if err != nil {
|
if err != nil {
|
||||||
@@ -169,7 +170,7 @@ func TestObjectOp(t *testing.T) {
|
|||||||
exitErrorf("Unable to get copy object, %v", err)
|
exitErrorf("Unable to get copy object, %v", err)
|
||||||
}
|
}
|
||||||
|
|
||||||
data, err := ioutil.ReadAll(getObj.Body)
|
data, err := io.ReadAll(getObj.Body)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
exitErrorf("Unable to read object data, %v", err)
|
exitErrorf("Unable to read object data, %v", err)
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,2 @@
|
|||||||
|
/s3-tests
|
||||||
|
/tmp
|
||||||
@@ -0,0 +1,11 @@
|
|||||||
|
# the tests only support python 3.6, not newer
|
||||||
|
FROM ubuntu:latest
|
||||||
|
|
||||||
|
RUN apt-get update && DEBIAN_FRONTEND=noninteractive TZ=Etc/UTC apt-get install -y git-core sudo tzdata
|
||||||
|
RUN git clone https://github.com/ceph/s3-tests.git
|
||||||
|
WORKDIR s3-tests
|
||||||
|
|
||||||
|
# we pin a certain commit
|
||||||
|
RUN git checkout 9a6a1e9f197fc9fb031b809d1e057635c2ff8d4e
|
||||||
|
|
||||||
|
RUN ./bootstrap
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user