Skip to content

Generate and Deploy Website #117

Generate and Deploy Website

Generate and Deploy Website #117

Workflow file for this run

name: Generate and Deploy Website
on:
workflow_dispatch:
workflow_call:
schedule:
- cron: "0 */6 * * *"
jobs:
docs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v4
with:
repository: 'duckdb/duckdb-web'
ref: 'community-extension'
path: 'web'
- name: Set up DuckDB
run: |
wget https://github.com/duckdb/duckdb/releases/download/v1.1.0/duckdb_cli-linux-amd64.zip
unzip duckdb_cli-linux-amd64.zip
chmod +x duckdb
- name: Fetch extensions
run: |
./scripts/fetch_extensions.sh ./duckdb
- name: Generate docs
run: |
./scripts/generate_md.sh ./duckdb
cp build/docs/*.md web/extensions/.
cat build/docs/extensions_list.md.tmp >> web/list_of_extensions.md
- name: Setup Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: '3.3' # Not needed with a .ruby-version file
bundler-cache: true # runs 'bundle install' and caches installed gems automatically
cache-version: 0 # Increment this number if you need to re-download cached gems
- name: Build with Jekyll
working-directory: 'web'
run: bundle install && bundler exec jekyll build --config _config.yml,_config_exclude_archive.yml
- name: Deploy website
working-directory: 'web/_site'
env:
AWS_ACCESS_KEY_ID: ${{ secrets.DUCKDB_COMMUNITY_EXTENSION_S3_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.DUCKDB_COMMUNITY_EXTENSION_S3_SECRET }}
AWS_DEFAULT_REGION: ${{ secrets.S3_DUCKDB_ORG_REGION }}
run: |
aws s3 cp --recursive extensions/ s3://duckdb-community-extensions/extensions --acl public-read
aws s3 cp index.html s3://duckdb-community-extensions/ --acl public-read
aws s3 cp core_extensions.html s3://duckdb-community-extensions/ --acl public-read
aws s3 cp development.html s3://duckdb-community-extensions/ --acl public-read
aws s3 cp documentation.html s3://duckdb-community-extensions/ --acl public-read
aws s3 cp faq.html s3://duckdb-community-extensions/ --acl public-read
aws s3 cp list_of_extensions.html s3://duckdb-community-extensions/ --acl public-read