Skip to content

Deploy static content to Pages #16

Deploy static content to Pages

Deploy static content to Pages #16

Workflow file for this run

# Simple workflow for deploying static content to GitHub Pages
name: Deploy static content to Pages
on:
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: read
pages: write
id-token: write
# Allow one concurrent deployment
concurrency:
group: "pages"
cancel-in-progress: true
jobs:
# Single deploy job since we're just deploying
deploy:
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Pages
uses: actions/configure-pages@v4
- name: 'Set up Java'
uses: actions/setup-java@v3
with:
java-version: 21
distribution: temurin
cache: 'gradle'
- name: 'Setup Gradle'
uses: gradle/actions/setup-gradle@v4
- name: Assemble the project
run: ./gradlew multiplatform-ui:wasmJsBrowserProductionWebpack
- name: Copy project files
run: |
mkdir -p multiplatformApp
cp -r multiplatform-ui/build/kotlin-webpack/wasmJs/productionExecutable/* multiplatformApp
cp -r multiplatform-ui/build/processedResources/wasmJs/main/* multiplatformApp
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
# Upload entire repository
path: multiplatformApp
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@main