beacon-node-builds: drop targets, move to prater host

Signed-off-by: Jakub Sokołowski <jakub@status.im>
This commit is contained in:
Jakub Sokołowski 2021-08-18 12:43:51 +02:00
parent e08baf3861
commit 4f05e2f40d
No known key found for this signature in database
GPG Key ID: 4EF064D0E6D63020
7 changed files with 42 additions and 14 deletions

View File

@ -0,0 +1,30 @@
---
# Builds use quite a bit of RAM
swap_file_size_mb: 4096
# Docker image builds
beacon_node_builds_docker_hub_user: '{{lookup("passwordstore", "cloud/DockerHub/user")}}'
beacon_node_builds_docker_hub_token: '{{lookup("passwordstore", "cloud/DockerHub/token")}}'
# The -large suffix is because of native compilation.
beacon_node_builds_branches:
- name: 'unstable-libp2p-unstable-large'
version: 'nim-libp2p-auto-bump-unstable'
frequency: '*-*-* 18:00:00'
- name: 'unstable-large'
version: 'unstable'
frequency: '*-*-* 10:00:00'
- name: 'testing-large'
version: 'testing'
frequency: '*-*-* 06:00:00'
- name: 'stable-large'
version: 'stable'
frequency: '*-*-* 02:00:00'
- name: 'deploy-eth2-prod'
version: 'v1.4.1'
enabled: false
update: true

View File

@ -12,7 +12,7 @@
- name: Deploy beacon node build nodes
become: true
hosts:
- testing-large-01.aws-eu-central-1a.nimbus.pyrmont
- testing-large-01.aws-eu-central-1a.nimbus.prater
roles:
- role: swap-file
tags: swap-file

View File

@ -16,7 +16,7 @@
- name: infra-role-bootstrap-linux
src: git@github.com:status-im/infra-role-bootstrap-linux.git
version: 53e96605481a84542702bd72e94a58eb63da9c9e
version: a51317d65e30ca9609778619195df96c8d05ba42
scm: git
- name: infra-role-bootstrap-windows
@ -31,7 +31,7 @@
- name: oauth-proxy
src: git@github.com:status-im/infra-role-oauth-proxy.git
version: 567b4cf59d97f87be78e77e62684214f6de03096
version: 05ef1410abe09db6df6e58ca14c556b7e2c383d7
scm: git
- name: consul-service

View File

@ -10,8 +10,9 @@ The minimal configuration would look something like:
beacon_node_builds_branches:
- name: 'xyz'
version: 'feature/xyz'
targets: ['nimbus_beacon_node', 'nimbus_signing_process']
frequency: '*-*-* 02:00:00'
enabled: true
update: true
# Required to push Docker images
beacon_node_builds_docker_hub_user: 'docker-hub-user'

View File

@ -14,6 +14,5 @@ beacon_node_build_timer_timeout: 3600
beacon_node_builds_branches: []
# - name: 'unstable'
# version: 'unstable'
# targets: ['nimbus_beacon_node', 'nimbus_signing_process']
# frequency: '*-*-* 10:00:00'
# enabled: false

View File

@ -7,12 +7,11 @@ RUN apt-get -qq update \
&& apt-get -qq clean \
&& rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
{% for target in item.targets %}
COPY repo/build/{{ target }}_${COMMIT} /usr/local/bin/{{ target }}
{% endfor %}
COPY repo/build/nimbus_beacon_node_${COMMIT} /usr/local/bin/nimbus_beacon_node
COPY repo/build/nimbus_signing_process_${COMMIT} /usr/local/bin/nimbus_signing_process
STOPSIGNAL SIGINT
ENTRYPOINT ["/usr/local/bin/{{ item.targets | first }}"]
ENTRYPOINT ["/usr/local/bin/nimbus_beacon_node"]
CMD ["--help"]

View File

@ -11,7 +11,7 @@ function dockerImageExists() {
}
function binaryExists() {
ls -l build/{{ item.targets | first }}_${COMMIT} 2>&1 1>/dev/null
ls -l build/nimbus_beacon_node_${COMMIT} 2>&1 1>/dev/null
}
function fetchChanges() {
@ -25,13 +25,12 @@ function buildBinaries() {
NICE="nice -n 19 ionice -c2 -n7"
${NICE} make -j1 update
${NICE} make -j1 {{ item.targets | join(" ") }} \
${NICE} make -j1 nimbus_beacon_node nimbus_signing_process \
LOG_LEVEL="TRACE" NIMFLAGS="-d:testnet_servers_image -d:noSignalHandler"
# Rename binaries to match commit the were built from.
{% for target in item.targets %}
mv "build/{{ target }}" "build/{{ target }}_${COMMIT}"
{% endfor %}
mv "build/nimbus_beacon_node" "build/nimbus_beacon_node_${COMMIT}"
mv "build/nimbus_signing_process" "build/nimbus_signing_process_${COMMIT}"
# Delete copies that are older than 7 days
find build -mtime +7 -exec rm '{}' \+