Skip to content
This repository was archived by the owner on Jan 9, 2020. It is now read-only.

Commit

Permalink
Added README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
ebouliane committed Dec 1, 2015
1 parent 166eb35 commit 1719599
Showing 1 changed file with 60 additions and 0 deletions.
60 changes: 60 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
# scheduled_runonce

####Table of Contents
1. [Overview](#overview)
2. [Module Description - What the run once module does and why it is useful](#module-description)
3. [Setup - The basics of getting started with run once](#setup)
* [Setup requirements](#setup-requirements)
* [Beginning with RunOnce](#beginning-with-run-once)
4. [License](#license)

##Overview

Allow a task to run once on a server between the provided date/time.

##Module Description

This module will allow a scheduled task to run once on a host between the date/time specified. It checks if a file exists (IE: /tmp/pp.<date start>) and if it does not, it will create and run the command.

By default the command is "/sbin/shutdown -ra now"

This module was tested and works great within RedHat Satellite 6.1.

##Setup

##Setup Requirements

Make sure touch is within the path /usr/bin or /sbin

##Beginning with run once

```puppet
scheduled_runonce {
"class_enabled" => true,
"datetime_start" => "2012-06-12 12:53:00",
"datetime_end" => "2012-06-12 12:53:59",
"command_var" => "/sbin/shutdown -ra now",
"check_file" => "/tmp/pp.sched_runonce",
}
```

class_enabled (Boolean: default [true])
- Enables/Disables the process
datetime_start (String: Date Format [Y-m-d H:i:s], default [undefined])
- Start Date/Time of the reboot window
datetime_end (String: Date Format [Y-m-d H:i:s], default [undefined])
- End Date/Time of the reboot window
command_var (String: default [/sbin/shutdown -ra now])
- Command to execute
check_file (String: default [/tmp/pp.scheduled-reboot])
- The check file that is created with Start DateTime added to the end.

##License

Copyright 2015 Eric B

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

0 comments on commit 1719599

Please sign in to comment.