Apache Software Foundation Website (www.apache.org)
This repository provides the source for the main website of The Apache Software Foundation.
-
- md pages in GitHub Flavored Markdown (GFM), which can include HTML.
- ezmd pages in a combination of ezt and GFM.
- html files are treated as static files.
- Static assets of all types.
- .htaccess files for redirection and rewrite rules.
-
Branches. Note that .asf.yaml is set up for autopreview. A branch named
preview/mytest
for example is automatically staged at https://www-mytest.staged.apache.org/
Markdown (.md) files appear in the preview pane of the GitHub editor approximately as they will appear in the generated website. This is convenient for reviewing changes, but means that linking to the source requires a bit more work compared with other files. If you want to create a permalink or raise an issue that relates to a particular Markdown source line, proceed as follows:
- link to the rendered file as normal, for example: https://github.com/apache/www-site/blob/main/README.md
- append ?plain=1 to the URL, for example: https://github.com/apache/www-site/blob/main/README.md?plain=1
- the file displays with line numbers, as for other types of files. Click a line number to generate a permalink or create an issue with a link to the line.
Read the ASF-Pelican Getting started guide and the pages it links to.
The website is built with Pelican.
Continuous Integration / Continuous Deployment (CI/CD) is via the .asf.yaml file mechanism, which runs Buildbot.
- Pelican Configuration -- Pelican configuration.
- ASF Data Load -- ASF metadata to be used by ezt and Pelican. See asfdata.py.
- ASF YAML Pelican Build -- ASF infrastructure instructions.
The svn history was not migrated and remains available.
Foundation records, including minutes of Board meetings, remain in svn, except for the index page.
Whimsy maintains the board calendar - calendar.md
in SVN. At the start of each build, a setup entry in pelicanconf.yaml calls the get_calendar.sh script, which copies the calendar into content/foundation/board
.
Changes to the file do not automatically trigger a build, but the file changes rarely (about once a month) and there are regular builds which pick up changes within an hour or so.
If you wish to update and test the site locally, there is a Docker build script you can use. You will also need Git, and familiarity with working in a command-line shell.
The following instructions should work for Unix, Linux, and macOS, but will need adjustment for Windows.
- Install Docker.
- Change to a suitable directory.
- Get the Infra Pelican setup:
git clone https://github.com/apache/infrastructure-pelican
. - Change to the checkout:
cd infrastructure-pelican
. - Build the container:
docker build -t pelican-asf .
. This will take a while the first time. - Change to a suitable directory.
- Get the ASF website source:
git clone https://github.com/apache/www-site
. - Change to the website checkout:
cd www-site
. - Create a dummy authorisation file:
touch .authtokens
. - Start the continuous builder:
docker run -it -p8000:8000 -v $PWD:/site pelican-asf
. This will generate a lot of output, but will eventually stop. [N.B. Pelican calls the data generation plugins 3 times before generating the pages.] - If you want to add some additional debug output, add the following line to
pelicanconf.yaml
:debug: true
- Browse to http://localhost:8000/ .
- If the builder reports a failure trying to find content/theme/apache, try changing
the
theme
entry inpelicanconf.yaml
totheme: ../theme/apache
and re-run
If you make changes to the local copy of www-site, these will be automatically built, and should appear in the browser when you refresh the page.
Any branch in the www-site repository that is named preview/* will auto-build and stage to www-*.staged.apache.org.
If you need to test your changes, create a branch such as preview/your-asf-id
Commits to it will be staged at www-your-asf-id.staged.apache.org
Note: the branch name must not include any "." characters, or browsers will refuse to display the site due to an invalid SSL certificate. The underscore character should not be used either, as it is disallowed in host names.
For any questions or support, please reach out to us by visiting our contact page at Apache Contact Us page.