{"id":1789,"date":"2018-09-11T14:52:52","date_gmt":"2018-09-11T06:52:52","guid":{"rendered":"https:\/\/cowmanchiang.me\/wp\/?p=1789"},"modified":"2023-10-31T15:42:22","modified_gmt":"2023-10-31T07:42:22","slug":"docker-the-crontab-is-not-work-in-docker","status":"publish","type":"post","link":"https:\/\/cowmanchiang.me\/wp\/?p=1789","title":{"rendered":"[Docker] The crontab is not work in docker"},"content":{"rendered":"<p>Source: <a href=\"http:\/\/www.voidcn.com\/article\/p-glqonfrc-bnw.html\" rel=\"noopener noreferrer\" target=\"_blank\">docker\u5bb9\u5668\u5185cron\u4e0d\u6267\u884c<\/a><\/p>\n<p>vim \/etc\/pam.d\/crond<br \/>\n<code><br \/>\n#<\/p>\n<h1>The PAM configuration file for the cron daemon<\/h1>\n<p>#<br \/>\n#<\/p>\n<h1>No PAM authentication called, auth modules not needed<\/h1>\n<h1>account    required   pam_access.so<\/h1>\n<p>account    sufficient   pam_access.so<br \/>\naccount    include    password-auth<\/p>\n<h1>session    required   pam_loginuid.so<\/h1>\n<p>session    sufficient   pam_loginuid.so<br \/>\nsession    include    password-auth<br \/>\nauth       include    password-auth<br \/>\n<\/code><\/p>\n<p>required: failure of such a PAM will ultimately lead to the PAM-API returning failure but only after the remaining stacked modules (for this service and type) have been invoked.<\/p>\n<p>sufficient: if such a module succeeds and no prior required module has failed the PAM framework returns success to the application or to the superior PAM stack immediately without calling any further modules in the stack. A failure of a sufficient module is ignored and processing of the PAM module stack continues unaffected.<\/p>\n<p><a href=\"http:\/\/www.linux-pam.org\/Linux-PAM-html\/sag-configuration-file.html\" rel=\"noopener noreferrer\" target=\"_blank\">4.1. Configuration file syntax<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Source: docker\u5bb9\u5668\u5185cron\u4e0d\u6267\u884c vim \/etc\/pam.d\/crond # The PAM configuration file for the cron daemon # # No PAM authentication called, auth modules not needed account required pam_access.so account sufficient pam_access.so account include password-auth session required pam_loginuid.so session sufficient pam_loginuid.so session include &hellip; <a href=\"https:\/\/cowmanchiang.me\/wp\/?p=1789\">Continue reading <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[38,58],"tags":[],"class_list":["post-1789","post","type-post","status-publish","format-standard","hentry","category-docker","category-linux"],"_links":{"self":[{"href":"https:\/\/cowmanchiang.me\/wp\/index.php?rest_route=\/wp\/v2\/posts\/1789","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/cowmanchiang.me\/wp\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/cowmanchiang.me\/wp\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/cowmanchiang.me\/wp\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/cowmanchiang.me\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1789"}],"version-history":[{"count":2,"href":"https:\/\/cowmanchiang.me\/wp\/index.php?rest_route=\/wp\/v2\/posts\/1789\/revisions"}],"predecessor-version":[{"id":1848,"href":"https:\/\/cowmanchiang.me\/wp\/index.php?rest_route=\/wp\/v2\/posts\/1789\/revisions\/1848"}],"wp:attachment":[{"href":"https:\/\/cowmanchiang.me\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1789"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/cowmanchiang.me\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1789"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/cowmanchiang.me\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1789"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}