Innablr / revolver

AWS Powercycle Facility
MIT License
2 stars 2 forks source link

Implement a filter that matches start/end datetime - can be used for future-date scheduling #336

Closed lyricnz closed 3 weeks ago

lyricnz commented 1 month ago

Per #228

lyricnz commented 1 month ago

Sample filter:

            - name: 'turn it all in in 2021'
              filter:
                - type: ec2
                - accountId: '112233445566'
                - matchWindow:
                    from: '2021-01-01'
                    to: '2022-01-01'
              schedule: '24x7'
              priority: 50
lyricnz commented 1 month ago

You'll have to be super-careful using these filters - especially around timezones (implicit/local vs explicit), and around 00:00 being the default time of day.

lyricnz commented 1 month ago

If a date without a time is specified as from/to value, then it is implicitly 00:00, which makes for somewhat counter-intuitive need to +1 on the end date in order to get 24hour event coverage.