ci: bun run failed

This commit is contained in:
ReaJason
2024-12-20 02:33:37 +08:00
parent fcbec8db19
commit c6f13dde5e
5 changed files with 24 additions and 15 deletions
+7 -2
View File
@@ -5,6 +5,7 @@ on:
paths-ignore: paths-ignore:
- 'docs/**' - 'docs/**'
- '**.md' - '**.md'
concurrency: concurrency:
group: ${{ github.workflow }}-${{ github.ref }} group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true cancel-in-progress: true
@@ -29,8 +30,10 @@ jobs:
- uses: oven-sh/setup-bun@v2 - uses: oven-sh/setup-bun@v2
with: with:
bun-version: latest bun-version: latest
- name: Bun Install
run: cd web && bun install --frozen-lockfile
- name: Build Web - name: Build Web
run: cd web && bun install --frozen-lockfile && bun build && bash copy-build.sh run: cd web && bun run build && bash copy-build.sh
- name: Build with Gradle - name: Build with Gradle
run: ./gradlew :boot:bootjar run: ./gradlew :boot:bootjar
- name: Upload Jar - name: Upload Jar
@@ -43,6 +46,8 @@ jobs:
needs: [ build ] needs: [ build ]
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- name: Checkout
uses: actions/checkout@v4
- name: Download Jar - name: Download Jar
uses: actions/download-artifact@v4 uses: actions/download-artifact@v4
with: with:
@@ -60,7 +65,7 @@ jobs:
- name: Build and push - name: Build and push
uses: docker/build-push-action@v6 uses: docker/build-push-action@v6
with: with:
context: boot/ context: boot
platforms: linux/amd64,linux/arm64 platforms: linux/amd64,linux/arm64
push: true push: true
tags: reajason/memshell-party:latest tags: reajason/memshell-party:latest
@@ -10,7 +10,7 @@ import org.springframework.web.bind.annotation.GetMapping;
@Controller @Controller
public class ViewController { public class ViewController {
@GetMapping("/") @GetMapping("/")
public String index() { public String index(){
return "index"; return "index";
} }
} }
@@ -15,6 +15,16 @@ public class GenerateRequest {
private InjectorConfig injectorConfig; private InjectorConfig injectorConfig;
private Packer.INSTANCE packer; private Packer.INSTANCE packer;
@Data
static class ShellToolConfigDTO {
private String shellClassName;
private String godzillaPass;
private String godzillaKey;
private String godzillaHeaderName;
private String godzillaHeaderValue;
private String commandParamName;
}
public ShellToolConfig parseShellToolConfig() { public ShellToolConfig parseShellToolConfig() {
if (shellConfig.getShellTool().equals(ShellTool.Godzilla)) { if (shellConfig.getShellTool().equals(ShellTool.Godzilla)) {
return GodzillaConfig.builder() return GodzillaConfig.builder()
@@ -33,14 +43,4 @@ public class GenerateRequest {
} }
throw new UnsupportedOperationException("unknown shell tool " + shellConfig.getShellTool()); throw new UnsupportedOperationException("unknown shell tool " + shellConfig.getShellTool());
} }
@Data
static class ShellToolConfigDTO {
private String shellClassName;
private String godzillaPass;
private String godzillaKey;
private String godzillaHeaderName;
private String godzillaHeaderValue;
private String commandParamName;
}
} }
+2 -1
View File
@@ -5,4 +5,5 @@ mkdir -p ../boot/src/main/resources/static/assets/
cp dist/vite.svg ../boot/src/main/resources/static/ cp dist/vite.svg ../boot/src/main/resources/static/
cp -R dist/assets/* ../boot/src/main/resources/static/assets/ cp -R dist/assets/* ../boot/src/main/resources/static/assets/
cp dist/index.html ../boot/src/main/resources/templates mkdir -p ../boot/src/main/resources/templates
cp dist/index.html ../boot/src/main/resources/templates/index.html
+4 -1
View File
@@ -52,5 +52,8 @@
"tailwind-merge": "^2.5.5", "tailwind-merge": "^2.5.5",
"tailwindcss-animate": "^1.0.7", "tailwindcss-animate": "^1.0.7",
"zod": "^3.24.1" "zod": "^3.24.1"
} },
"trustedDependencies": [
"@biomejs/biome"
]
} }