File tree Expand file tree Collapse file tree 4 files changed +59
-0
lines changed
cookbooks/aws-parallelcluster-computefleet Expand file tree Collapse file tree 4 files changed +59
-0
lines changed Original file line number Diff line number Diff line change 1+ [Unit]
2+ Description =Check for recent file modifications
3+
4+ [Service]
5+ Type =oneshot
6+ ExecStart =/bin/bash -c 'echo "check-update.service executed at $(date)"'
7+
8+ [Install]
9+ WantedBy =multi-user.target
Original file line number Diff line number Diff line change 1+ [Unit]
2+ Description=Check file modification time every minute
3+
4+ [Timer]
5+ OnBootSec=1min
6+ OnUnitActiveSec=60sec
7+ Unit=check-update.service
8+
9+ [Install]
10+ WantedBy=timers.target
Original file line number Diff line number Diff line change 1212# limitations under the License.
1313
1414include_recipe 'aws-parallelcluster-computefleet::fleet_status'
15+
16+ if node [ 'cluster' ] [ 'node_type' ] == 'ComputeFleet'
17+ include_recipe 'aws-parallelcluster-computefleet::config_check_update_systemd_service'
18+ end
Original file line number Diff line number Diff line change 1+ # frozen_string_literal: true
2+
3+ #
4+ # Cookbook:: aws-parallelcluster-slurm
5+ # Recipe:: config_compute
6+ #
7+ # Copyright:: 2013-2021 Amazon.com, Inc. or its affiliates. All Rights Reserved.
8+ #
9+ # Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with the
10+ # License. A copy of the License is located at
11+ #
12+ # http://aws.amazon.com/apache2.0/
13+ #
14+ # or in the "LICENSE.txt" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES
15+ # OR CONDITIONS OF ANY KIND, express or implied. See the License for the specific language governing permissions and
16+ # limitations under the License.
17+
18+ cookbook_file '/etc/systemd/system/check-update.service' do
19+ source 'check_update/check-update.service'
20+ owner 'root'
21+ group 'root'
22+ mode '0644'
23+ action :create
24+ end
25+
26+ cookbook_file '/etc/systemd/system/check-update.timer' do
27+ source 'check_update/check-update.timer'
28+ owner 'root'
29+ group 'root'
30+ mode '0644'
31+ action :create
32+ end
33+
34+ service 'check-update.timer' do
35+ action [ :enable , :start ]
36+ end
You can’t perform that action at this time.
0 commit comments