mirror of
https://github.com/kubesphere/website.git
synced 2025-12-26 00:12:48 +00:00
57 lines
1.4 KiB
YAML
57 lines
1.4 KiB
YAML
name: KubeSphere Website
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- master
|
|
schedule: # run 8:00 AM Beijing Time everyday
|
|
- cron: '0 0 * * *'
|
|
|
|
jobs:
|
|
deploy:
|
|
runs-on: ubuntu-18.04
|
|
steps:
|
|
- name: Checkout code
|
|
uses: actions/checkout@v2
|
|
with:
|
|
submodules: true
|
|
fetch-depth: 0
|
|
|
|
- name: Setup Hugo
|
|
uses: peaceiris/actions-hugo@v2
|
|
with:
|
|
hugo-version: '0.71.1'
|
|
extended: true
|
|
|
|
- name: Sync to gitee
|
|
uses: Yikun/hub-mirror-action@master
|
|
with:
|
|
src: github/kubesphere
|
|
dst: gitee/kubesphere
|
|
white_list: 'website'
|
|
dst_key: ${{ secrets.GITEE_PRIVATE_KEY }}
|
|
dst_token: ${{ secrets.GITEE_TOKEN}}
|
|
account_type: org
|
|
|
|
- name: Build English Website
|
|
run: hugo --environment upstream --minify
|
|
|
|
- name: Build and Push image
|
|
uses: docker/build-push-action@v1
|
|
with:
|
|
username: ${{ secrets.DOCKER_USERNAME }}
|
|
password: ${{ secrets.DOCKER_PASSWORD }}
|
|
repository: kubesphere/website
|
|
tags: v1.0-en
|
|
|
|
- name: Build Chinese Website
|
|
run: hugo --environment upstream-zh --minify
|
|
|
|
- name: Build and Push image
|
|
uses: docker/build-push-action@v1
|
|
with:
|
|
username: ${{ secrets.DOCKER_USERNAME }}
|
|
password: ${{ secrets.DOCKER_PASSWORD }}
|
|
repository: kubesphere/website
|
|
tags: v1.0-zh
|