Compare commits

..

No commits in common. "c10s" and "c8" have entirely different histories.
c10s ... c8

12 changed files with 59 additions and 281 deletions

1
.crontabs.metadata Normal file
View File

@ -0,0 +1 @@
b9ea464e842ee5dac1d721faa267c1a8f5e78e70 SOURCES/crontabs-1.11-20190603git.tar.gz

View File

@ -1 +0,0 @@
1

3
.gitignore vendored
View File

@ -1,2 +1 @@
*~ SOURCES/crontabs-1.11-20190603git.tar.gz
*.tar.*

View File

@ -1,49 +1,66 @@
* Tue Sep 12 2023 Jan Staněk <jstanek@redhat.com> - 1.11-30.20190603git %global snap_release 20190603
- Migrated to SPDX license field. Summary: Root crontab files used to schedule the execution of programs
Name: crontabs
Version: 1.11
Release: 17.%{snap_release}git%{?dist}
License: Public Domain and GPLv2
URL: https://github.com/cronie-crond/crontabs
Source0: https://github.com/cronie-crond/crontabs/releases/download/crontabs-%{snap_release}/%{name}-%{version}-%{snap_release}git.tar.gz
BuildArch: noarch
Requires: sed
Recommends: cronie
* Wed Jul 19 2023 Fedora Release Engineering <releng@fedoraproject.org> - 1.11-30.20190603git %description
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild This package is used mainly for executing files by cron.
* Thu Jan 19 2023 Fedora Release Engineering <releng@fedoraproject.org> - 1.11-29.20190603git The crontabs package contains root crontab files and directories.
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild You will need to install cron daemon to run the jobs from the crontabs.
The cron daemon such as cronie or fcron checks the crontab files to
see when particular commands are scheduled to be executed. If commands
are scheduled, it executes them.
* Wed Jul 20 2022 Fedora Release Engineering <releng@fedoraproject.org> - 1.11-28.20190603git Crontabs handles a basic system function, so it should be installed on
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild your system.
* Thu Jun 23 2022 Ondřej Pohořelský <opohorel@redhat.com> - 1.11-27.20190603git %prep
- Make cronie hard dependency %setup -q
- Resolves: #2089793
* Thu Jan 20 2022 Fedora Release Engineering <releng@fedoraproject.org> - 1.11-26.20190603git %build
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild #empty
* Wed Jul 21 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.11-25.20190603git %install
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT/etc/cron.{hourly,daily,weekly,monthly}
mkdir -p $RPM_BUILD_ROOT/usr/bin
mkdir -p $RPM_BUILD_ROOT/%{_mandir}/man4/
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.11-24.20190603git install -m644 ./crontab $RPM_BUILD_ROOT/etc/crontab
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild install -m755 ./run-parts $RPM_BUILD_ROOT/usr/bin/run-parts
install -m644 ./{crontabs,run-parts}.4 $RPM_BUILD_ROOT/%{_mandir}/man4/
* Mon Jul 27 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.11-23.20190603git mkdir -p $RPM_BUILD_ROOT/etc/sysconfig/
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild touch $RPM_BUILD_ROOT/etc/sysconfig/run-parts
* Tue Jan 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.11-22.20190603git %files
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild %{!?_licensedir:%global license %%doc}
%license COPYING
%config(noreplace) /etc/crontab
%attr(0644,root,root) %config(noreplace) /etc/sysconfig/run-parts
%{_bindir}/run-parts
%dir /etc/cron.hourly
%dir /etc/cron.daily
%dir /etc/cron.weekly
%dir /etc/cron.monthly
%{_mandir}/man4/*
* Wed Jul 24 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.11-21.20190603git %changelog
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild * Wed Jan 06 2021 Ondřej Pohořelský <opohorel@redhat.com> - 1.11-17.20190603git
- update to the latest release
* Mon Jun 3 2019 Tomáš Mráz <tmraz@redhat.com> - 1.11-20.20190603git - add sed require
- fix regression from the previous release (#1716114) - remove %%clean section
- remove obsolete Group tag
* Thu May 30 2019 Tomáš Mráz <tmraz@redhat.com> - 1.11-19.20190530git - fix upstream URL
- fix race condition in run-parts causing it to hang occasionally - Resolves: rhbz#1696449, rhbz#1703982
- fix upstream URLs
* Thu Jan 31 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.11-18.20150630git
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
* Thu Jul 12 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.11-17.20150630git
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
* Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.11-16.20150630git * Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.11-16.20150630git
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild - Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
@ -133,7 +150,7 @@
* Mon Jan 26 2009 Marcela Mašláňová <mmaslano@redhat.com> 1.10-26 * Mon Jan 26 2009 Marcela Mašláňová <mmaslano@redhat.com> 1.10-26
- change /etc/crontab. All anacron jobs in cron.daily,weekly,... - change /etc/crontab. All anacron jobs in cron.daily,weekly,...
are check by anacron every hour. Anacron run them if they didn't are check by anacron every hour. Anacron run them if they didn't
run today. run today.
* Mon Dec 1 2008 Jan ONDREJ (SAL) <ondrejj(at)salstar.sk> 1.10-25 * Mon Dec 1 2008 Jan ONDREJ (SAL) <ondrejj(at)salstar.sk> 1.10-25
- Added /etc/cron.{hourly,daily,weekly,monthly} dirs again. bz#473353 - Added /etc/cron.{hourly,daily,weekly,monthly} dirs again. bz#473353
@ -142,7 +159,7 @@
- 450084 LANG=C is set up for running scripts - 450084 LANG=C is set up for running scripts
* Wed May 28 2008 Marcela Maslanova <mmaslano@redhat.com> 1.10-22 * Wed May 28 2008 Marcela Maslanova <mmaslano@redhat.com> 1.10-22
- remove scripts for delay, anacron now own most of the scripts. - remove scripts for delay, anacron now own most of the scripts.
Crontabs owns only run-parts, /etc/crontab and crontabs sysconfig. Crontabs owns only run-parts, /etc/crontab and crontabs sysconfig.
* Mon May 5 2008 Marcela Maslanova <mmaslano@redhat.com> 1.10-21 * Mon May 5 2008 Marcela Maslanova <mmaslano@redhat.com> 1.10-21
@ -236,7 +253,7 @@ Crontabs owns only run-parts, /etc/crontab and crontabs sysconfig.
* Thu Apr 15 1999 Bill Nottingham <notting@redhat.com> * Thu Apr 15 1999 Bill Nottingham <notting@redhat.com>
- don't run .rpm{save,new,orig} files (bug #2190) - don't run .rpm{save,new,orig} files (bug #2190)
* Sun Mar 21 1999 Cristian Gafton <gafton@redhat.com> * Sun Mar 21 1999 Cristian Gafton <gafton@redhat.com>
- auto rebuild in the new build environment (release 5) - auto rebuild in the new build environment (release 5)
* Mon Nov 30 1998 Bill Nottingham <notting@redhat.com> * Mon Nov 30 1998 Bill Nottingham <notting@redhat.com>
@ -251,7 +268,7 @@ Crontabs owns only run-parts, /etc/crontab and crontabs sysconfig.
* Tue Apr 07 1998 Erik Troan <ewt@redhat.com> * Tue Apr 07 1998 Erik Troan <ewt@redhat.com>
- moved crontab jobs up a bit to make sure they aren't confused by - moved crontab jobs up a bit to make sure they aren't confused by
switching to and fro daylight savings time switching to and fro daylight savings time
* Fri Oct 24 1997 Erik Troan <ewt@redhat.com> * Fri Oct 24 1997 Erik Troan <ewt@redhat.com>
- removed tmpwatch and at entries - removed tmpwatch and at entries

View File

@ -1,60 +0,0 @@
%global snapshot_date 20190603
%global snapshot_commit 9e74f2d
Summary: Root crontab files used to schedule the execution of programs
Name: crontabs
Version: 1.11^%{snapshot_date}git%{snapshot_commit}
Release: %autorelease
# See https://gitlab.com/fedora/legal/fedora-license-data/-/merge_requests/359 for reasoning why Public Domain is not here.
License: GPL-2.0-or-later
URL: https://github.com/cronie-crond/crontabs
Source0: https://github.com/cronie-crond/crontabs/releases/download/crontabs-%{snapshot_date}/%{name}-%(echo %{version}|cut -d\^ -f1)-%{snapshot_date}git.tar.gz
BuildArch: noarch
Requires: sed
Requires: cronie
%description
This package is used by Fedora mainly for executing files by cron.
The crontabs package contains root crontab files and directories.
You will need to install cron daemon to run the jobs from the crontabs.
The cron daemon such as cronie or fcron checks the crontab files to
see when particular commands are scheduled to be executed. If commands
are scheduled, it executes them.
Crontabs handles a basic system function, so it should be installed on
your system.
%prep
%autosetup -n %{name}-%(echo %{version}|cut -d\^ -f1)
%build
#empty
%install
rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT/etc/cron.{hourly,daily,weekly,monthly}
mkdir -p $RPM_BUILD_ROOT/usr/bin
mkdir -p $RPM_BUILD_ROOT/%{_mandir}/man4/
install -m644 ./crontab $RPM_BUILD_ROOT/etc/crontab
install -m755 ./run-parts $RPM_BUILD_ROOT/usr/bin/run-parts
install -m644 ./{crontabs,run-parts}.4 $RPM_BUILD_ROOT/%{_mandir}/man4/
mkdir -p $RPM_BUILD_ROOT/etc/sysconfig/
touch $RPM_BUILD_ROOT/etc/sysconfig/run-parts
%files
%{!?_licensedir:%global license %%doc}
%license COPYING
%config(noreplace) /etc/crontab
%attr(0644,root,root) %config(noreplace) /etc/sysconfig/run-parts
%{_bindir}/run-parts
%dir /etc/cron.hourly
%dir /etc/cron.daily
%dir /etc/cron.weekly
%dir /etc/cron.monthly
%{_mandir}/man4/*
%changelog
%autochangelog

View File

@ -1,6 +0,0 @@
--- !Policy
product_versions:
- rhel-10
decision_context: osci_compose_gate
rules:
- !PassingTestCaseRule {test_case_name: osci.brew-build.tier0.functional}

View File

@ -1,10 +0,0 @@
summary: Internal Tier1 tests plan
discover:
how: fmf
filter: 'tier: 1'
url: https://pkgs.devel.redhat.com/git/tests/crontabs
execute:
how: tmt
adjust:
enabled: false
when: distro == centos-stream or distro == fedora

View File

@ -1 +0,0 @@
SHA512 (crontabs-1.11-20190603git.tar.gz) = 1f0dae337c9dcd07cbc20bdc2c596f4e6aa314c025329fa5d2d53048cf84ba1e0c82bb0b66fefb7333aa58290d421debe0aaf8bf5d6733ddd4442d9ad668a945

View File

@ -1,63 +0,0 @@
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#
# Makefile of /CoreOS/crontabs/Sanity/test-of-functionality-of-crontabs
# Description: test of functionality of crontabs
# Author: Petr Sklenar <psklenar@redhat.com>
#
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#
# Copyright (c) 2011 Red Hat, Inc. All rights reserved.
#
# This copyrighted material is made available to anyone wishing
# to use, modify, copy, or redistribute it subject to the terms
# and conditions of the GNU General Public License version 2.
#
# This program is distributed in the hope that it will be
# useful, but WITHOUT ANY WARRANTY; without even the implied
# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
# PURPOSE. See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public
# License along with this program; if not, write to the Free
# Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
# Boston, MA 02110-1301, USA.
#
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
export TEST=/CoreOS/crontabs/Sanity/test-of-functionality-of-crontabs
export TESTVERSION=1.0
BUILT_FILES=
FILES=$(METADATA) runtest.sh Makefile PURPOSE
.PHONY: all install download clean
run: $(FILES) build
./runtest.sh
build: $(BUILT_FILES)
chmod a+x runtest.sh
clean:
rm -f *~ $(BUILT_FILES)
include /usr/share/rhts/lib/rhts-make.include
$(METADATA): Makefile
@echo "Owner: Petr Sklenar <psklenar@redhat.com>" > $(METADATA)
@echo "Name: $(TEST)" >> $(METADATA)
@echo "TestVersion: $(TESTVERSION)" >> $(METADATA)
@echo "Path: $(TEST_DIR)" >> $(METADATA)
@echo "Description: test of functionality of crontabs" >> $(METADATA)
@echo "Type: Sanity" >> $(METADATA)
@echo "TestTime: 30m" >> $(METADATA)
@echo "RunFor: crontabs" >> $(METADATA)
@echo "Requires: crontabs" >> $(METADATA)
@echo "Priority: Normal" >> $(METADATA)
@echo "License: GPLv2" >> $(METADATA)
@echo "Confidential: no" >> $(METADATA)
@echo "Destructive: no" >> $(METADATA)
rhts-lint $(METADATA)

View File

@ -1,3 +0,0 @@
PURPOSE of /CoreOS/crontabs/Sanity/test-of-functionality-of-crontabs
Description: test of functionality of crontabs
Author: Petr Sklenar <psklenar@redhat.com>

View File

@ -1,83 +0,0 @@
#!/bin/bash
# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#
# runtest.sh of /CoreOS/crontabs/Sanity/test-of-functionality-of-crontabs
# Description: test of functionality of crontabs
# Author: Petr Sklenar <psklenar@redhat.com>
#
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#
# Copyright (c) 2011 Red Hat, Inc. All rights reserved.
#
# This copyrighted material is made available to anyone wishing
# to use, modify, copy, or redistribute it subject to the terms
# and conditions of the GNU General Public License version 2.
#
# This program is distributed in the hope that it will be
# useful, but WITHOUT ANY WARRANTY; without even the implied
# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
# PURPOSE. See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public
# License along with this program; if not, write to the Free
# Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
# Boston, MA 02110-1301, USA.
#
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# Include rhts environment
. /usr/bin/rhts-environment.sh
. /usr/lib/beakerlib/beakerlib.sh
PACKAGE="crontabs"
#how long should we wait:
COUNT=5
rlJournalStart
rlPhaseStartSetup
rlAssertRpm $PACKAGE
user="petr$RANDOM"
rlRun "rm -rf /tmp/test.createdbypetr /tmp/test.createdbyroot" 0 "Removing tmp directory"
rlRun "useradd $user"
rlFileBackup /etc/crontab
rlPhaseEnd
rlPhaseStartTest
echo "* * * * * root echo root >> /tmp/test.createdbyroot" >> /etc/crontab
rlAssert0 "added first entry into crontab" $?
echo "* * * * * $user echo petr >> /tmp/test.createdbypetr" >> /etc/crontab
rlAssert0 "added second entry into crontab" $?
#sleep a while
rlRun "sleep ${COUNT}m" 0 "sleeping for 5m to wait for cron to create files"
rlPhaseEnd
rlPhaseStartTest "check content"
byroot=`grep root /tmp/test.createdbyroot | wc -l`
bypetr=`grep petr /tmp/test.createdbypetr | wc -l`
if [ "$byroot" -ge "${COUNT}" ];then
rlPass "there is $byroot line"
else
rlFail "there is $byroot line"
fi
if [ "$bypetr" -ge "${COUNT}" ];then
rlPass "there is $bypetr line"
else
rlFail "there is $bypetr line"
fi
rlPhaseEnd
rlPhaseStartTest "check permissions of created files"
/bin/ls -la /tmp/test.createdbyroot | grep "root root"
rlAssert0 "permissions are root root" $?
/bin/ls -la /tmp/test.createdbypetr | grep "$user $user"
rlAssert0 "permissions are $user $user" $?
rlPhaseEnd
rlPhaseStartCleanup
rlRun "rm -rf /tmp/test.createdbypetr /tmp/test.createdbyroot" 0 "Removing tmp directory"
rlRun "userdel -r $user"
rlFileRestore
rlPhaseEnd
rlJournalPrintText
rlJournalEnd

View File

@ -1,12 +0,0 @@
---
# This first play always runs on the local staging system
- hosts: localhost
roles:
- role: standard-test-beakerlib
tags:
- classic
tests:
- test-of-functionality-of-crontabs
required_packages:
- crontabs # test-of-functionality-of-crontabs needs crontabs
- findutils # beakerlib needs find command