apache / infrastructure-actions

Apache infrastructure
https://infrastructure.apache.org/
1 stars 3 forks source link

What is the proper yaml for output branches #46

Closed dave2wave closed 5 months ago

dave2wave commented 5 months ago

I see the following in the action at https://github.com/apache/infrastructure-actions/blob/main/pelican/action.yml#L102-L104

This copies the .asf.yaml file.. This is not really what is needed:

For preview we need:

staging:
  profile: ~
  autostage: preview/*

and for branch ash-site:

publish:
  profile: ~
  whoami: asf-site
sebbASF commented 5 months ago

AFAICT the code currently does the same as the BuildBot job. That certainly works for staging builds, as can be seen in www-site preview branches. But I agree it looks odd to see the full .asf.yaml in the staging branch.

I think maybe the code needs to copy just the staging and publish stanzas.

Also, some projects may use a different branch for the published site, so that needs to be obtained from the existing .asf.yaml

dfoulks1 commented 5 months ago

the staging part of the .asf.yaml is branch specific aiui, so only the bits matching the whoami will be evaluated.

sebbASF commented 5 months ago

The staging stanza is only branch specific if it contains a whoami clause. [1]

Also the autostage clause is not affected by the whoami clause.

[1] https://github.com/apache/infrastructure-asfyaml/blob/main/README.md#staging-a-web-site-preview-domain

dave2wave commented 5 months ago

Thank you