Re: [PATCH] fas_client: fix template to correctly apply on pkgs02 and add people02
On Mon, 20 Apr 2020 at 11:13, Pierre-Yves Chibon wrote: > On Mon, Apr 20, 2020 at 02:41:51PM +, Kevin Fenzi wrote: > > The ansible_hostname variable is actually the short name of the host, > > not the fqdn, so this conditional didn't match before. Switch it to use > > startswith and also add people02 as thats the other host people try and > > login to often after changing ssh keys. > > > > With this, pkgs02 and people02 should hopefully update ssh keys from fas > > every 15min and avoid manual sync requests to the team. > > > > Signed-off-by: Kevin Fenzi > > --- > > roles/fas_client/templates/fas-client.cron.j2 | 2 +- > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > diff --git a/roles/fas_client/templates/fas-client.cron.j2 > b/roles/fas_client/templates/fas-client.cron.j2 > > index c0de939..8dd0a78 100644 > > --- a/roles/fas_client/templates/fas-client.cron.j2 > > +++ b/roles/fas_client/templates/fas-client.cron.j2 > > @@ -1,4 +1,4 @@ > > -{% if ansible_hostname == 'pkgs02.phx2.fedoraproject.org' %} > > +{% if ansible_hostname.startswith(('pkgs02', 'people02')) %} > > */15 * * * * root /usr/local/bin/lock-wrapper fasClient > "/usr/bin/fasClient -i |& grep -vi deprecation | /usr/local/bin/nag-once > fassync 1d 2>&1" > > {% else %} > > 00 20 * * * root /usr/local/bin/lock-wrapper fasClient "/bin/sleep > $(($RANDOM \% 3600)); /usr/bin/fasClient -i |& grep -vi deprecation | > /usr/local/bin/nag-once fassync 1d 2>&1" > > +1 for me, should we include pkgs01 for stg? > +1 with the same caveat? > > Pierre > ___ > infrastructure mailing list -- infrastructure@lists.fedoraproject.org > To unsubscribe send an email to > infrastructure-le...@lists.fedoraproject.org > Fedora Code of Conduct: > https://docs.fedoraproject.org/en-US/project/code-of-conduct/ > List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines > List Archives: > https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org > -- Stephen J Smoogen. ___ infrastructure mailing list -- infrastructure@lists.fedoraproject.org To unsubscribe send an email to infrastructure-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org
Re: [PATCH] fas_client: fix template to correctly apply on pkgs02 and add people02
On Mon, Apr 20, 2020 at 02:41:51PM +, Kevin Fenzi wrote: > The ansible_hostname variable is actually the short name of the host, > not the fqdn, so this conditional didn't match before. Switch it to use > startswith and also add people02 as thats the other host people try and > login to often after changing ssh keys. > > With this, pkgs02 and people02 should hopefully update ssh keys from fas > every 15min and avoid manual sync requests to the team. > > Signed-off-by: Kevin Fenzi > --- > roles/fas_client/templates/fas-client.cron.j2 | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/roles/fas_client/templates/fas-client.cron.j2 > b/roles/fas_client/templates/fas-client.cron.j2 > index c0de939..8dd0a78 100644 > --- a/roles/fas_client/templates/fas-client.cron.j2 > +++ b/roles/fas_client/templates/fas-client.cron.j2 > @@ -1,4 +1,4 @@ > -{% if ansible_hostname == 'pkgs02.phx2.fedoraproject.org' %} > +{% if ansible_hostname.startswith(('pkgs02', 'people02')) %} > */15 * * * * root /usr/local/bin/lock-wrapper fasClient "/usr/bin/fasClient > -i |& grep -vi deprecation | /usr/local/bin/nag-once fassync 1d 2>&1" > {% else %} > 00 20 * * * root /usr/local/bin/lock-wrapper fasClient "/bin/sleep > $(($RANDOM \% 3600)); /usr/bin/fasClient -i |& grep -vi deprecation | > /usr/local/bin/nag-once fassync 1d 2>&1" +1 for me, should we include pkgs01 for stg? Pierre ___ infrastructure mailing list -- infrastructure@lists.fedoraproject.org To unsubscribe send an email to infrastructure-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org
[PATCH] fas_client: fix template to correctly apply on pkgs02 and add people02
The ansible_hostname variable is actually the short name of the host, not the fqdn, so this conditional didn't match before. Switch it to use startswith and also add people02 as thats the other host people try and login to often after changing ssh keys. With this, pkgs02 and people02 should hopefully update ssh keys from fas every 15min and avoid manual sync requests to the team. Signed-off-by: Kevin Fenzi --- roles/fas_client/templates/fas-client.cron.j2 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/roles/fas_client/templates/fas-client.cron.j2 b/roles/fas_client/templates/fas-client.cron.j2 index c0de939..8dd0a78 100644 --- a/roles/fas_client/templates/fas-client.cron.j2 +++ b/roles/fas_client/templates/fas-client.cron.j2 @@ -1,4 +1,4 @@ -{% if ansible_hostname == 'pkgs02.phx2.fedoraproject.org' %} +{% if ansible_hostname.startswith(('pkgs02', 'people02')) %} */15 * * * * root /usr/local/bin/lock-wrapper fasClient "/usr/bin/fasClient -i |& grep -vi deprecation | /usr/local/bin/nag-once fassync 1d 2>&1" {% else %} 00 20 * * * root /usr/local/bin/lock-wrapper fasClient "/bin/sleep $(($RANDOM \% 3600)); /usr/bin/fasClient -i |& grep -vi deprecation | /usr/local/bin/nag-once fassync 1d 2>&1" -- 1.8.3.1 ___ infrastructure mailing list -- infrastructure@lists.fedoraproject.org To unsubscribe send an email to infrastructure-le...@lists.fedoraproject.org Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/infrastructure@lists.fedoraproject.org