-
-
Notifications
You must be signed in to change notification settings - Fork 239
92 lines (89 loc) · 2.35 KB
/
Copy pathmoon.yml
File metadata and controls
92 lines (89 loc) · 2.35 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
name: Moon
on:
push:
branches:
- master
pull_request:
paths:
- .cargo/config.toml
- .github/workflows/moon.yml
- .moon/*
- crates/**
- legacy/**
- packages/**
- website/**
- package.json
- yarn.lock
- Cargo.lock
- Cargo.toml
- rust-toolchain.toml
env:
# For setup-rust
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
jobs:
ci:
name: CI
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
steps:
- uses: actions/checkout@v6
with:
fetch-depth: 0
- uses: actions/setup-node@v6
- uses: voidzero-dev/setup-vp@v1
- uses: arduino/setup-protoc@v3
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
- uses: moonrepo/setup-rust@v1
with:
cache-base: '^(master|develop-)'
- run: cargo run -- --color --log debug ci --base ${{ github.base_ref || 'master' }}
env:
DEPOT_TOKEN: ${{ secrets.DEPOT_TOKEN }}
MOON_DEBUG_DAEMON: true
MOON_DEBUG_REMOTE: true
MOON_DEBUG_PROCESS_ENV: true
RUST_BACKTRACE: '1'
- run: cat .moon/cache/daemon/server.log
if: failure()
- uses: moonrepo/run-report-action@v1
if: success() || failure()
with:
access-token: ${{ secrets.GITHUB_TOKEN }}
matrix: ${{ toJSON(matrix) }}
docker:
if: ${{ github.repository == 'moonrepo/moon' }}
name: Docker
# Older required for Docker libc
runs-on: ubuntu-22.04
permissions:
contents: read
id-token: write
steps:
- uses: actions/checkout@v6
- uses: depot/setup-action@v1
- uses: arduino/setup-protoc@v3
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
- uses: moonrepo/setup-rust@v1
with:
cache: false
- run: cargo build
- run: ./target/debug/moon --version
# Non-staged
- run: ./target/debug/moon docker scaffold website --log trace
env:
MOON_SKIP_SETUP_TOOLCHAIN: '*'
- uses: depot/build-push-action@v1
with:
context: .
push: false
file: ./scripts/docker/Dockerfile
# Staged
- uses: depot/build-push-action@v1
with:
context: .
push: false
file: ./scripts/docker/Dockerfile.staged