Skip to content
This repository was archived by the owner on Aug 2, 2022. It is now read-only.

Commit 26a4d28

Browse files
authored
Merge pull request #10389 from EOSIO/merge-release-2.1.x-to-master
Merge release/2.1.x to master for v2.1.0
2 parents 32a47e3 + 6fe20a5 commit 26a4d28

File tree

792 files changed

+76691
-23558
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

792 files changed

+76691
-23558
lines changed

.cicd/README.md

Lines changed: 105 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,105 @@
1+
# eosio
2+
The [eosio](https://buildkite.com/EOSIO/eosio) and [eosio-build-unpinned](https://buildkite.com/EOSIO/eosio-build-unpinned) pipelines are the primary pipelines for the [eos](https://github.com/EOSIO/eos) repository, running with specific or default versions of our dependencies, respectively. Both run against every commit to a base branch or pull request, along with the [eosio-code-coverage](https://buildkite.com/EOSIO/eosio-code-coverage) pipeline.
3+
4+
The [eosio](https://buildkite.com/EOSIO/eosio) pipeline further triggers the [eosio-sync-from-genesis](https://buildkite.com/EOSIO/eosio-sync-from-genesis) and [eosio-resume-from-state](https://buildkite.com/EOSIO/eosio-resume-from-state) pipelines on each build, and the the [eosio-lrt](https://buildkite.com/EOSIO/eosio-lrt) pipeline on merge commits. Each of these pipelines are described in more detail below and in their respective READMEs.
5+
6+
<details>
7+
<summary>See More</summary>
8+
9+
## Index
10+
1. [Configuration](README.md#configuration)
11+
1. [Variables](README.md#variables)
12+
1. [Examples](README.md#examples)
13+
1. [Pipelines](README.md#pipelines)
14+
1. [See Also](README.md#see-also)
15+
16+
## Configuration
17+
Most EOSIO pipelines are run any time you push a commit or tag to an open pull request in [eos](https://github.com/EOSIO/eos), any time you merge a pull request, and nightly. The [eosio-lrt](https://buildkite.com/EOSIO/eosio-lrt) pipeline only runs when you merge a pull request because it takes so long. Long-running tests are also run in the [eosio](https://buildkite.com/EOSIO/eosio) nightly builds, which have `RUN_ALL_TESTS='true'` set.
18+
19+
### Variables
20+
Most pipelines in the organization have several environment variables that can be used to configure how the pipeline runs. These environment variables can be specified when manually triggering a build via the Buildkite UI.
21+
22+
Configure which platforms are run:
23+
```bash
24+
SKIP_LINUX='true|false' # skip all steps on Linux distros
25+
SKIP_MAC='true|false' # skip all steps on Mac hardware
26+
```
27+
These will override more specific operating system declarations, and primarily exist to disable one of our two buildfleets should one be sick or the finite macOS agents are congested.
28+
29+
Configure which operating systems are built, tested, and packaged:
30+
```bash
31+
RUN_ALL_TESTS='true' # run all tests in the current build (including LRTs, overridden by SKIP* variables)
32+
SKIP_AMAZON_LINUX_2='true|false' # skip all steps for Amazon Linux 2
33+
SKIP_CENTOS_7_7='true|false' # skip all steps for Centos 7.7
34+
SKIP_CENTOS_8='true|false' # skip all steps for Centos 8
35+
SKIP_MACOS_10_14='true|false' # skip all steps for MacOS 10.14
36+
SKIP_MACOS_10_15='true|false' # skip all steps for MacOS 10.15
37+
SKIP_MACOS_11='true|false' # skip all steps for MacOS 11
38+
SKIP_UBUNTU_16_04='true|false' # skip all steps for Ubuntu 16.04
39+
SKIP_UBUNTU_18_04='true|false' # skip all steps for Ubuntu 18.04
40+
SKIP_UBUNTU_20_04='true|false' # skip all steps for Ubuntu 20.04
41+
```
42+
43+
Configure which steps are executed for each operating system:
44+
```bash
45+
SKIP_BUILD='true|false' # skip all build steps
46+
SKIP_UNIT_TESTS='true|false' # skip all unit tests
47+
SKIP_WASM_SPEC_TESTS='true|false' # skip all wasm spec tests
48+
SKIP_SERIAL_TESTS='true|false' # skip all integration tests
49+
SKIP_LONG_RUNNING_TESTS='true|false' # skip all long running tests
50+
SKIP_MULTIVERSION_TEST='true|false' # skip all multiversion tests
51+
SKIP_SYNC_TESTS='true|false' # skip all sync tests
52+
SKIP_PACKAGE_BUILDER='true|false' # skip all packaging steps
53+
```
54+
55+
Configure how the steps are executed:
56+
```bash
57+
PINNED='true|false' # use specific versions of dependencies instead of whatever version is provided by default on a given platform
58+
TIMEOUT='##' # set timeout in minutes for all steps
59+
```
60+
61+
### Examples
62+
Build and test on Linux only:
63+
```bash
64+
SKIP_MAC='true'
65+
```
66+
67+
Build and test on MacOS only:
68+
```bash
69+
SKIP_LINUX='true'
70+
```
71+
72+
Skip all tests:
73+
```bash
74+
SKIP_UNIT_TESTS='true'
75+
SKIP_WASM_SPEC_TESTS='true'
76+
SKIP_SERIAL_TESTS='true'
77+
SKIP_LONG_RUNNING_TESTS='true'
78+
SKIP_MULTIVERSION_TEST='true'
79+
SKIP_SYNC_TESTS='true'
80+
```
81+
82+
## Pipelines
83+
There are several eosio pipelines that exist and are triggered by pull requests, pipelines, or schedules:
84+
85+
Pipeline | Details
86+
---|---
87+
[eosio](https://buildkite.com/EOSIO/eosio) | [eos](https://github.com/EOSIO/eos) build, tests, and packaging with pinned dependencies; runs on every pull request and base branch commit, and nightly
88+
[eosio-base-images](https://buildkite.com/EOSIO/eosio-base-images) | pack EOSIO dependencies into docker and Anka base-images nightly
89+
[eosio-big-sur-beta](https://buildkite.com/EOSIO/eosio-big-sur-beta) | build and test [eos](https://github.com/EOSIO/eos) on macOS 11 "Big Sur" weekly
90+
[eosio-build-scripts](https://buildkite.com/EOSIO/eosio-build-scripts) | run [eos](https://github.com/EOSIO/eos) build scripts nightly on empty operating systems
91+
[eosio-build-unpinned](https://buildkite.com/EOSIO/eosio-build-unpinned) | [eos](https://github.com/EOSIO/eos) build and tests with platform-provided dependencies; runs on every pull request and base branch commit, and nightly
92+
[eosio-code-coverage](https://buildkite.com/EOSIO/eosio-code-coverage) | assess [eos](https://github.com/EOSIO/eos) unit test coverage; runs on every pull request and base branch commit
93+
[eosio-debug-build](https://buildkite.com/EOSIO/eosio-debug-build) | perform a debug build for [eos](https://github.com/EOSIO/eos) on every pull request and base branch commit
94+
[eosio-lrt](https://buildkite.com/EOSIO/eosio-lrt) | runs tests that need more time on merge commits
95+
[eosio-resume-from-state](https://buildkite.com/EOSIO/eosio-resume-from-state) | loads the current version of `nodeos` from state files generated by specific previous versions of `nodeos` in each [eosio](https://buildkite.com/EOSIO/eosio) build ([Documentation](https://github.com/EOSIO/auto-eks-sync-nodes/blob/master/pipelines/eosio-resume-from-state/README.md))
96+
[eosio-sync-from-genesis](https://buildkite.com/EOSIO/eosio-sync-from-genesis) | sync the current version of `nodeos` past genesis from peers on common public chains as a smoke test, for each [eosio](https://buildkite.com/EOSIO/eosio) build
97+
98+
## See Also
99+
- Buildkite
100+
- [DevDocs](https://github.com/EOSIO/devdocs/wiki/Buildkite)
101+
- [eosio-resume-from-state Documentation](https://github.com/EOSIO/auto-eks-sync-nodes/blob/master/pipelines/eosio-resume-from-state/README.md)
102+
- [Run Your First Build](https://buildkite.com/docs/tutorials/getting-started#run-your-first-build)
103+
- [#help-automation](https://blockone.slack.com/archives/CMTAZ9L4D) Slack Channel
104+
105+
</details>

.cicd/base-images.yml

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,29 @@ steps:
4545
cd: ~
4646
agents: "queue=mac-anka-node-fleet"
4747
timeout: 180
48+
49+
- label: ":darwin: macOS 10.15 - Base Image Pinned"
50+
command:
51+
- "git clone [email protected]:EOSIO/eos.git eos && cd eos && git checkout -f $BUILDKITE_BRANCH"
52+
- "cd eos && ./.cicd/platforms/pinned/macos-10.15-pinned.sh"
53+
plugins:
54+
- EOSIO/anka#v0.6.1:
55+
debug: true
56+
vm-name: "10.15.5_6C_14G_80G"
57+
no-volume: true
58+
always-pull: true
59+
wait-network: true
60+
pre-execute-sleep: 5
61+
pre-execute-ping-sleep: github.com
62+
vm-registry-tag: "clean::cicd::git-ssh::nas::brew::buildkite-agent"
63+
failover-registries:
64+
- "registry_1"
65+
- "registry_2"
66+
inherit-environment-vars: true
67+
- EOSIO/skip-checkout#v0.1.1:
68+
cd: ~
69+
agents: "queue=mac-anka-node-fleet"
70+
timeout: 180
4871

4972
- label: ":ubuntu: Ubuntu 16.04 - Base Image Pinned"
5073
command:
@@ -112,6 +135,29 @@ steps:
112135
cd: ~
113136
agents: "queue=mac-anka-node-fleet"
114137
timeout: 180
138+
139+
- label: ":darwin: macOS 10.15 - Base Image Unpinned"
140+
command:
141+
- "git clone [email protected]:EOSIO/eos.git eos && cd eos && git checkout -f $BUILDKITE_BRANCH"
142+
- "cd eos && ./.cicd/platforms/unpinned/macos-10.15-unpinned.sh"
143+
plugins:
144+
- EOSIO/anka#v0.6.1:
145+
debug: true
146+
vm-name: "10.15.5_6C_14G_80G"
147+
no-volume: true
148+
always-pull: true
149+
wait-network: true
150+
pre-execute-sleep: 5
151+
pre-execute-ping-sleep: github.com
152+
vm-registry-tag: "clean::cicd::git-ssh::nas::brew::buildkite-agent"
153+
failover-registries:
154+
- "registry_1"
155+
- "registry_2"
156+
inherit-environment-vars: true
157+
- EOSIO/skip-checkout#v0.1.1:
158+
cd: ~
159+
agents: "queue=mac-anka-node-fleet"
160+
timeout: 180
115161

116162
- label: ":ubuntu: Ubuntu 18.04 - Base Image Unpinned"
117163
command:

.cicd/build-scripts.yml

Lines changed: 114 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,15 +21,26 @@ steps:
2121
command:
2222
- "./scripts/eosio_build.sh -P -y"
2323
timeout: 180
24-
24+
25+
- label: ":centos: CentOS 8 - Build Pinned"
26+
plugins:
27+
- docker#v3.3.0:
28+
image: "centos:8"
29+
always-pull: true
30+
agents:
31+
queue: "automation-eks-eos-builder-fleet"
32+
command:
33+
- "./scripts/eosio_build.sh -P -y"
34+
timeout: 180
35+
2536
- label: ":darwin: macOS 10.14 - Build Pinned"
2637
env:
2738
REPO: "[email protected]:EOSIO/eos.git"
2839
TEMPLATE: "10.14.6_6C_14G_80G"
2940
TEMPLATE_TAG: "clean::cicd::git-ssh::nas::brew::buildkite-agent"
3041
agents: "queue=mac-anka-large-node-fleet"
3142
command:
32-
- "git clone [email protected]:EOSIO/eos.git eos && cd eos && git checkout -f $BUILDKITE_BRANCH && git submodule update --init --recursive"
43+
- "git clone [email protected]:EOSIO/eos.git eos && cd eos && git checkout -f $BUILDKITE_BRANCH && git submodule update --init --recursive"
3344
- "cd eos && ./scripts/eosio_build.sh -P -y"
3445
plugins:
3546
- EOSIO/anka#v0.6.1:
@@ -50,6 +61,36 @@ steps:
5061
- EOSIO/skip-checkout#v0.1.1:
5162
cd: ~
5263
timeout: 180
64+
65+
66+
- label: ":darwin: macOS 10.15 - Build Pinned"
67+
env:
68+
REPO: "[email protected]:EOSIO/eos.git"
69+
TEMPLATE: "10.15.5_6C_14G_80G"
70+
TEMPLATE_TAG: "clean::cicd::git-ssh::nas::brew::buildkite-agent"
71+
agents: "queue=mac-anka-large-node-fleet"
72+
command:
73+
- "git clone [email protected]:EOSIO/eos.git eos && cd eos && git checkout -f $BUILDKITE_BRANCH && git submodule update --init --recursive"
74+
- "cd eos && ./scripts/eosio_build.sh -P -y"
75+
plugins:
76+
- EOSIO/anka#v0.6.1:
77+
debug: true
78+
vm-name: "10.15.5_6C_14G_80G"
79+
no-volume: true
80+
modify-cpu: 12
81+
modify-ram: 24
82+
always-pull: true
83+
wait-network: true
84+
pre-execute-sleep: 5
85+
pre-execute-ping-sleep: github.com
86+
vm-registry-tag: "clean::cicd::git-ssh::nas::brew::buildkite-agent"
87+
failover-registries:
88+
- "registry_1"
89+
- "registry_2"
90+
inherit-environment-vars: true
91+
- EOSIO/skip-checkout#v0.1.1:
92+
cd: ~
93+
timeout: 180
5394

5495
- label: ":ubuntu: Ubuntu 16.04 - Build Pinned"
5596
plugins:
@@ -75,6 +116,21 @@ steps:
75116
- "./scripts/eosio_build.sh -P -y"
76117
timeout: 180
77118

119+
- label: ":ubuntu: Ubuntu 20.04 - Build Pinned"
120+
env:
121+
DEBIAN_FRONTEND: "noninteractive"
122+
plugins:
123+
- docker#v3.3.0:
124+
image: "ubuntu:20.04"
125+
always-pull: true
126+
agents:
127+
queue: "automation-eks-eos-builder-fleet"
128+
command:
129+
- "ln -fs /usr/share/zoneinfo/America/New_York /etc/localtime"
130+
- "apt update && apt upgrade -y && apt install -y git"
131+
- "./scripts/eosio_build.sh -P -y"
132+
timeout: 180
133+
78134
- label: ":aws: Amazon_Linux 2 - Build UnPinned"
79135
plugins:
80136
- docker#v3.3.0:
@@ -96,6 +152,17 @@ steps:
96152
command:
97153
- "./scripts/eosio_build.sh -y"
98154
timeout: 180
155+
156+
- label: ":centos: CentOS 8 - Build UnPinned"
157+
plugins:
158+
- docker#v3.3.0:
159+
image: "centos:8"
160+
always-pull: true
161+
agents:
162+
queue: "automation-eks-eos-builder-fleet"
163+
command:
164+
- "./scripts/eosio_build.sh -y"
165+
timeout: 180
99166

100167
- label: ":darwin: macOS 10.14 - Build UnPinned"
101168
env:
@@ -125,6 +192,35 @@ steps:
125192
- EOSIO/skip-checkout#v0.1.1:
126193
cd: ~
127194
timeout: 180
195+
196+
- label: ":darwin: macOS 10.15 - Build UnPinned"
197+
env:
198+
REPO: "[email protected]:EOSIO/eos.git"
199+
TEMPLATE: "10.15.5_6C_14G_80G"
200+
TEMPLATE_TAG: "clean::cicd::git-ssh::nas::brew::buildkite-agent"
201+
agents: "queue=mac-anka-large-node-fleet"
202+
command:
203+
- "git clone [email protected]:EOSIO/eos.git eos && cd eos && git checkout -f $BUILDKITE_BRANCH && git submodule update --init --recursive"
204+
- "cd eos && ./scripts/eosio_build.sh -y"
205+
plugins:
206+
- EOSIO/anka#v0.6.1:
207+
debug: true
208+
vm-name: "10.15.5_6C_14G_80G"
209+
no-volume: true
210+
modify-cpu: 12
211+
modify-ram: 24
212+
always-pull: true
213+
wait-network: true
214+
pre-execute-sleep: 5
215+
pre-execute-ping-sleep: github.com
216+
vm-registry-tag: "clean::cicd::git-ssh::nas::brew::buildkite-agent"
217+
failover-registries:
218+
- "registry_1"
219+
- "registry_2"
220+
inherit-environment-vars: true
221+
- EOSIO/skip-checkout#v0.1.1:
222+
cd: ~
223+
timeout: 180
128224

129225
- label: ":ubuntu: Ubuntu 18.04 - Build UnPinned"
130226
plugins:
@@ -136,4 +232,19 @@ steps:
136232
command:
137233
- "apt update && apt upgrade -y && apt install -y git"
138234
- "./scripts/eosio_build.sh -y"
139-
timeout: 180
235+
timeout: 180
236+
237+
- label: ":ubuntu: Ubuntu 20.04 - Build UnPinned"
238+
env:
239+
DEBIAN_FRONTEND: "noninteractive"
240+
plugins:
241+
- docker#v3.3.0:
242+
image: "ubuntu:20.04"
243+
always-pull: true
244+
agents:
245+
queue: "automation-eks-eos-builder-fleet"
246+
command:
247+
- "ln -fs /usr/share/zoneinfo/America/New_York /etc/localtime"
248+
- "apt update && apt upgrade -y && apt install -y git g++"
249+
- "./scripts/eosio_build.sh -y"
250+
timeout: 180

.cicd/build.sh

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,15 @@ set -eo pipefail
44
. ./.cicd/helpers/general.sh
55
mkdir -p "$BUILD_DIR"
66
[[ -z "$DCMAKE_BUILD_TYPE" ]] && export DCMAKE_BUILD_TYPE='Release'
7-
CMAKE_EXTRAS="-DCMAKE_BUILD_TYPE=\"$DCMAKE_BUILD_TYPE\" -DENABLE_MULTIVERSION_PROTOCOL_TEST=\"true\" -DBUILD_MONGO_DB_PLUGIN=\"true\""
7+
CMAKE_EXTRAS="-DCMAKE_BUILD_TYPE=\"$DCMAKE_BUILD_TYPE\" -DENABLE_MULTIVERSION_PROTOCOL_TEST=\"true\""
88
if [[ "$(uname)" == 'Darwin' && "$FORCE_LINUX" != 'true' ]]; then
99
# You can't use chained commands in execute
1010
if [[ "$GITHUB_ACTIONS" == 'true' ]]; then
1111
export PINNED='false'
1212
fi
1313
[[ ! "$PINNED" == 'false' ]] && CMAKE_EXTRAS="$CMAKE_EXTRAS -DCMAKE_TOOLCHAIN_FILE=\"$HELPERS_DIR/clang.make\""
1414
cd "$BUILD_DIR"
15+
[[ "$CI" == 'true' ]] && source ~/.bash_profile # Make sure node is available for ship_test
1516
echo '+++ :hammer_and_wrench: Building EOSIO'
1617
CMAKE_COMMAND="cmake $CMAKE_EXTRAS .."
1718
echo "$ $CMAKE_COMMAND"
@@ -29,11 +30,14 @@ else # Linux
2930
if [[ "$IMAGE_TAG" == 'amazon_linux-2-unpinned' ]]; then
3031
CMAKE_EXTRAS="$CMAKE_EXTRAS -DCMAKE_CXX_COMPILER=\"clang++\" -DCMAKE_C_COMPILER=\"clang\""
3132
elif [[ "$IMAGE_TAG" == 'centos-7.7-unpinned' ]]; then
32-
PRE_COMMANDS="$PRE_COMMANDS && source \"/opt/rh/devtoolset-8/enable\" && source \"/opt/rh/rh-python36/enable\""
33+
PRE_COMMANDS="$PRE_COMMANDS && source /opt/rh/devtoolset-8/enable"
3334
CMAKE_EXTRAS="$CMAKE_EXTRAS -DLLVM_DIR=\"/opt/rh/llvm-toolset-7.0/root/usr/lib64/cmake/llvm\""
3435
elif [[ "$IMAGE_TAG" == 'ubuntu-18.04-unpinned' ]]; then
3536
CMAKE_EXTRAS="$CMAKE_EXTRAS -DCMAKE_CXX_COMPILER=\"clang++-7\" -DCMAKE_C_COMPILER=\"clang-7\" -DLLVM_DIR=\"/usr/lib/llvm-7/lib/cmake/llvm\""
3637
fi
38+
if [[ "$IMAGE_TAG" == centos-7.* ]]; then
39+
PRE_COMMANDS="$PRE_COMMANDS && source /opt/rh/rh-python36/enable"
40+
fi
3741
CMAKE_COMMAND="cmake \$CMAKE_EXTRAS .."
3842
MAKE_COMMAND="make -j $JOBS"
3943
BUILD_COMMANDS="echo \"+++ :hammer_and_wrench: Building EOSIO\" && echo \"$ $CMAKE_COMMAND\" && eval $CMAKE_COMMAND && echo \"$ $MAKE_COMMAND\" && eval $MAKE_COMMAND"

0 commit comments

Comments
 (0)