Skip to content

Build base container #51

Build base container

Build base container #51

Workflow file for this run

name: Build base container
on:
push:
tags:
- build_base*
jobs:
build:
runs-on: ubuntu-22.04
steps:
- name: install cmake
run: |
wget --no-check-certificate https://cmake.org/files/v3.21/cmake-3.21.0-linux-x86_64.sh && \
chmod +x cmake-3.21.0-linux-x86_64.sh && \
./cmake-3.21.0-linux-x86_64.sh --skip-license --include-subdir && \
sudo ln -sf `pwd`/cmake-3.21.0-linux-x86_64/bin/* /usr/local/bin
- name: install packages
run: |
sudo apt-get update && \
sudo apt-get install -y build-essential software-properties-common apt-utils libprocps-dev \
gcc-11 g++-11 valgrind gawk sed libffi-dev ccache yasm texinfo \
autotools-dev autogen automake autoconf m4 shtool pkg-config nasm \
python3 python3-pip python-is-python3 \
libtool libgcrypt20-dev
# python python-pip
# wget git libargtable2-dev \
# libmicrohttpd-dev libhiredis-dev redis-server openssl libssl-dev >/dev/null 2>&1;
- name: Use g++-11 and gcov-11 by default
run: |
echo "Updating all needed alternatives"
sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-11 11
sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-11 11
sudo update-alternatives --install /usr/bin/gcov gcov /usr/bin/gcov-11 11
sudo update-alternatives --install /usr/bin/gcov-dump gcov-dump /usr/bin/gcov-dump-11 11
sudo update-alternatives --install /usr/bin/gcov-tool gcov-tool /usr/bin/gcov-tool-11 11
echo "Checking alternative for gcc"
which gcc
gcc --version
echo "Checking alternative for g++"
which g++
g++ --version
echo "Checking alternative for gcov"
which gcov
gcov --version
echo "Checking alternative for gcov-dump"
which gcov-dump
gcov-dump --version
echo "Checking alternative for gcov-tool"
which gcov-tool
gcov-tool --version
- uses: actions/checkout@v2
- name: submodule update
run: git submodule update --init --recursive
- name: Build the Docker image(base)
run: docker build . --file DockerfileBase --tag skalenetwork/consensust_base:latest
- name: Login to docker
env:
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }}
DOCKER_PASSWORD: ${{ secrets.DOCKER_PASSWORD }}
run: echo "$DOCKER_PASSWORD" | docker login --username "$DOCKER_USERNAME" --password-stdin
- name: push docker image
run: docker push skalenetwork/consensust_base:latest