Skip to content

Commit 563aadc

Browse files
committed
WIP
1 parent bb660f3 commit 563aadc

1 file changed

Lines changed: 58 additions & 0 deletions

File tree

build-config/buildspec-linux.yml

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
version: 0.2
2+
3+
env:
4+
shell: bash
5+
6+
phases:
7+
install:
8+
run-as: root
9+
commands:
10+
- dnf update -y
11+
- dnf install -y python cmake bash zsh unzip zstd xz git jq protobuf
12+
- dnf swap -y gnupg2-minimal gnupg2-full
13+
pre_build:
14+
commands:
15+
- export HOME=/home/codebuild-user
16+
- export PATH="$HOME/.local/bin:$PATH"
17+
- mkdir -p "$HOME/.local/bin"
18+
# Create fish config dir to prevent rustup from failing
19+
- mkdir -p "$HOME/.config/fish/conf.d"
20+
# Install cargo
21+
- curl --retry 5 --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
22+
- . "$HOME/.cargo/env"
23+
- rustup toolchain install `cat rust-toolchain.toml | grep channel | cut -d '=' -f2 | tr -d ' "'`
24+
# Install cross only if the musl env var is set and not null
25+
- if [ ! -z "${AMAZON_Q_BUILD_MUSL:+x}" ]; then cargo install cross --git https://github.com/cross-rs/cross; fi
26+
# Install python/node via mise (https://mise.jdx.dev/continuous-integration.html)
27+
- curl --retry 5 --proto '=https' --tlsv1.2 -sSf https://mise.run | sh
28+
- mise install
29+
- eval "$(mise activate bash --shims)"
30+
# Enable corepack for pnpm
31+
# - corepack enable
32+
# Install python deps
33+
- pip3 install -r build-scripts/requirements.txt
34+
build:
35+
commands:
36+
# Disable tests that need fish/shellcheck
37+
- export AMAZON_Q_BUILD_SKIP_FISH_TESTS=1
38+
- export AMAZON_Q_BUILD_SKIP_SHELLCHECK_TESTS=1
39+
- python3.11 build-scripts/qchatmain.py build
40+
41+
artifacts:
42+
discard-paths: "yes"
43+
base-directory: "build"
44+
files:
45+
# Bundles for desktop builds
46+
- ./*.appimage
47+
- ./*.deb
48+
# Archives for minimal builds
49+
- ./*.tar.gz
50+
- ./*.tar.xz
51+
- ./*.tar.zst
52+
- ./*.zip
53+
# Hashes
54+
- ./*.sha256
55+
# Signatures
56+
- ./*.asc
57+
- ./*.sig
58+

0 commit comments

Comments
 (0)