- Add Dockerfile.buttplug: builds Rust/WASM + TS, serves via nginx - Add nginx.buttplug.conf: serves /dist and /wasm with correct MIME types - Add .gitea/workflows/docker-build-buttplug.yml: path-filtered CI workflow - Strip Rust toolchain and buttplug build from frontend Dockerfile - Move buttplug to devDependencies (types only at build time) - Remove vite-plugin-wasm from frontend (WASM now served by nginx) - Add /buttplug proxy in vite.config (dev: localhost:8080) - Add buttplug service to compose.yml - Load buttplug dynamically in play page via runtime import - Fix faq page: suppress no-unnecessary-state-wrap for reassigned SvelteSet Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
69 lines
1.8 KiB
YAML
69 lines
1.8 KiB
YAML
name: Build and Push Buttplug Image
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
- develop
|
|
tags:
|
|
- "v*.*.*"
|
|
paths:
|
|
- "packages/buttplug/**"
|
|
- "Dockerfile.buttplug"
|
|
- "nginx.buttplug.conf"
|
|
pull_request:
|
|
branches:
|
|
- main
|
|
paths:
|
|
- "packages/buttplug/**"
|
|
- "Dockerfile.buttplug"
|
|
- "nginx.buttplug.conf"
|
|
workflow_dispatch:
|
|
|
|
env:
|
|
REGISTRY: dev.pivoine.art
|
|
IMAGE_NAME: valknar/sexy-buttplug
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Set up Docker Buildx
|
|
uses: docker/setup-buildx-action@v3
|
|
with:
|
|
platforms: linux/amd64
|
|
|
|
- name: Log in to Gitea Container Registry
|
|
uses: docker/login-action@v3
|
|
with:
|
|
registry: ${{ env.REGISTRY }}
|
|
username: ${{ gitea.actor }}
|
|
password: ${{ secrets.REGISTRY_TOKEN }}
|
|
|
|
- name: Extract metadata
|
|
id: meta
|
|
uses: docker/metadata-action@v5
|
|
with:
|
|
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
|
|
tags: |
|
|
type=raw,value=latest,enable={{is_default_branch}}
|
|
type=ref,event=branch
|
|
type=ref,event=pr
|
|
type=semver,pattern={{version}}
|
|
type=sha,prefix={{branch}}-
|
|
|
|
- name: Build and push
|
|
uses: docker/build-push-action@v5
|
|
with:
|
|
context: .
|
|
file: Dockerfile.buttplug
|
|
platforms: linux/amd64
|
|
push: ${{ gitea.event_name != 'pull_request' }}
|
|
tags: ${{ steps.meta.outputs.tags }}
|
|
labels: ${{ steps.meta.outputs.labels }}
|
|
cache-from: type=registry,ref=${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:buildcache
|
|
cache-to: type=registry,ref=${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:buildcache,mode=max
|