generated from krisnova/rust-nova
-
Notifications
You must be signed in to change notification settings - Fork 90
95 lines (95 loc) · 4.82 KB
/
002-tester-ubuntu-make-test-auraescript.yml
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
93
94
95
# ---------------------------------------------------------------------------- #
# #
# +--------------------------------------------+ #
# | █████╗ ██╗ ██╗██████╗ █████╗ ███████╗ | #
# | ██╔══██╗██║ ██║██╔══██╗██╔══██╗██╔════╝ | #
# | ███████║██║ ██║██████╔╝███████║█████╗ | #
# | ██╔══██║██║ ██║██╔══██╗██╔══██║██╔══╝ | #
# | ██║ ██║╚██████╔╝██║ ██║██║ ██║███████╗ | #
# | ╚═╝ ╚═╝ ╚═════╝ ╚═╝ ╚═╝╚═╝ ╚═╝╚══════╝ | #
# +--------------------------------------------+ #
# #
# Distributed Systems Runtime #
# #
# ---------------------------------------------------------------------------- #
# #
# Copyright 2022 - 2024, the Aurae contributors #
# SPDX-License-Identifier: Apache-2.0 #
# #
# ---------------------------------------------------------------------------- #
#
# This is the premerge test workflow for auraescript
#
# This check will introduce confidence for the following:
#
# - That the binary does not have unexpected dependencies.
# - We intentionally build this on a clean ubuntu image, to prove that we can
# generate a static binary with minimal dependencies.
# - That the code does not warn (due to clippy errors/warnings)
# - That the behaviour works as per tests
#
# When this build passes we should have a "clean cargo" output!
#
name: "(002) [ubuntu:latest] make auraescript-test"
on:
push:
branches: main
pull_request:
branches: main
env:
CARGO_TERM_COLOR: always
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: bufbuild/buf-setup-action@v1
with:
github_token: ${{ github.token }}
version: 1.32.0
- uses: actions/cache@v3
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: 000-${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
restore-keys: |
000-${{ runner.os }}-cargo-
- name: Install protoc-gen-doc in [ubuntu:latest]
run: |
wget https://github.com/pseudomuto/protoc-gen-doc/releases/download/v1.5.1/protoc-gen-doc_1.5.1_linux_amd64.tar.gz
tar -xzf protoc-gen-doc_1.5.1_linux_amd64.tar.gz
chmod +x protoc-gen-doc
cp protoc-gen-doc /usr/local/bin/protoc-gen-doc
sudo apt-get update
sudo apt-get install -y protobuf-compiler
- name: Install compile time dependencies (musl-tools) in [ubuntu:latest]
#
# Do not add GNU libraries here! Do not add GNU libraries here!
#
# Please (seriously please) be careful about adding commands here.
# This is our core way of validating that our binary is "healthy"
# If we need to install anything with the word "lib" in it to get
# the build to pass, we likely should be having other discussions
# instead of adding commands here.
#
# Do not add GNU libraries here! Do not add GNU libraries here!
#
# For example, we should NOT be adding libraries such as "libseccomp"
# or "libdbus".
#
# If in doubt, please ask in Discord in the build channel.
#
# Do not at GNU libraries here! Do not add GNU libraries here!
run: |
sudo apt-get update
sudo apt-get install -y musl-tools
- name: Cargo build, lint, test [make test]
# This should remain the only command we execute as this matches the title of the file.
# The goal is for this to be easy to find from the GitHub dashboard.
# Instead of adding more commands here, consider another make target or a new YAML file
# named with a good name.
run: make auraescript-test