Commit d317b82 1 parent 503a330 commit d317b82 Copy full SHA for d317b82
File tree 1 file changed +21
-4
lines changed
1 file changed +21
-4
lines changed Original file line number Diff line number Diff line change 670
670
mode "755"
671
671
end
672
672
673
+ systemd_service "cleanup-tiles@" do
674
+ description "Cleanup old tiles for /%I"
675
+ exec_start "/usr/local/bin/cleanup-tiles /%I"
676
+ user "_renderd"
677
+ io_scheduling_class "idle"
678
+ sandbox true
679
+ read_write_paths "/%I"
680
+ end
681
+
682
+ systemd_timer "cleanup-tiles@" do
683
+ description "Cleanup old tiles for /%I"
684
+ on_boot_sec "30m"
685
+ on_unit_inactive_sec "60m"
686
+ randomized_delay_sec "10m"
687
+ end
688
+
673
689
tile_directories . each do |directory |
674
690
label = directory . gsub ( "/" , "-" )
675
691
676
692
cron_d "cleanup-tiles#{ label } " do
677
- minute "0"
678
- user "_renderd"
679
- command "ionice -c 3 /usr/local/bin/cleanup-tiles #{ directory } "
680
- mailto "admins@openstreetmap.org"
693
+ action :delete
694
+ end
695
+
696
+ service "cleanup-tiles@#{ label [ 1 ..] } " do
697
+ action [ :enable , :start ]
681
698
end
682
699
end
683
700
You can’t perform that action at this time.
0 commit comments