Skip to content

Commit cd7fc7a

Browse files
committed
feat: commit initial work on ubuntu 22.04
fix: remove setuptools as it conflicts with existing OS packages chore: update github workflows fix: fix tests chore: use temp server fix: fix deb package versioning fix: fix msgpack dependency fix: fix build fix: add cython3 fix: fix checkpoint service fix: fix popitem fix: remove extra parameter from test_stats_publisher fix: replace iloc with keys fix: fix collections.Mapping to collections.abc.Mapping fix: some collections still use last=False... fix: fix append to add fix: fix rlp fix: fix lint fix: fix popitem that uses last notation fix: fix Iterable chore: clean up un-needed files chore: change to hyperledger github fix: restore needed file that was cleaned up Signed-off-by: Kim Ebert <[email protected]>
1 parent ae6b893 commit cd7fc7a

32 files changed

+607
-42
lines changed

.github/workflows/PR.yaml

+4-4
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ jobs:
2828
uses: actions/checkout@v4
2929
- name: setup
3030
id: setup
31-
uses: hyperledger/indy-shared-gha/.github/actions/workflow-setup@v1
31+
uses: hyperledger/indy-shared-gha/.github/actions/workflow-setup@v2
3232
- name: testsNeeded
3333
id: testsNeeded
3434
uses: dorny/paths-filter@v3
@@ -44,12 +44,12 @@ jobs:
4444
name: Lint
4545
needs: [workflow-setup]
4646
if: ${{ needs.workflow-setup.outputs.testsNeeded == 'true' }}
47-
uses: hyperledger/indy-shared-gha/.github/workflows/lint.yaml@v1
47+
uses: hyperledger/indy-shared-gha/.github/workflows/lint.yaml@v2
4848

4949
build-docker-image:
5050
name: Create Builder Image
5151
needs: [workflow-setup, lint]
52-
uses: hyperledger/indy-shared-gha/.github/workflows/buildimage.yaml@v1
52+
uses: hyperledger/indy-shared-gha/.github/workflows/buildimage.yaml@v2
5353
with:
5454
CACHE_KEY_BUILD: ${{ needs.workflow-setup.outputs.CACHE_KEY_BUILD }}
5555
DOCKER_IMAGE: ghcr.io/${{ needs.workflow-setup.outputs.GITHUB_REPOSITORY_NAME }}/plenum-build
@@ -58,7 +58,7 @@ jobs:
5858
build_packages:
5959
name: Build Packages
6060
needs: [workflow-setup, build-docker-image]
61-
uses: hyperledger/indy-shared-gha/.github/workflows/buildpackages.yaml@v1
61+
uses: hyperledger/indy-shared-gha/.github/workflows/buildpackages.yaml@v2
6262
with:
6363
DOCKER_IMAGE: ghcr.io/${{ needs.workflow-setup.outputs.GITHUB_REPOSITORY_NAME }}/plenum-build:${{ needs.workflow-setup.outputs.UBUNTU_VERSION }}
6464
UBUNTU_VERSION: ${{ needs.workflow-setup.outputs.UBUNTU_VERSION }}

.github/workflows/Push.yaml

+5-5
Original file line numberDiff line numberDiff line change
@@ -28,16 +28,16 @@ jobs:
2828
uses: actions/checkout@v4
2929
- name: setup
3030
id: setup
31-
uses: hyperledger/indy-shared-gha/.github/actions/workflow-setup@v1
31+
uses: hyperledger/indy-shared-gha/.github/actions/workflow-setup@v2
3232

3333
lint:
3434
name: Lint
35-
uses: hyperledger/indy-shared-gha/.github/workflows/lint.yaml@v1
35+
uses: hyperledger/indy-shared-gha/.github/workflows/lint.yaml@v2
3636

3737
build-docker-image:
3838
name: Create Builder Image
3939
needs: [workflow-setup, lint]
40-
uses: hyperledger/indy-shared-gha/.github/workflows/buildimage.yaml@v1
40+
uses: hyperledger/indy-shared-gha/.github/workflows/buildimage.yaml@v2
4141
with:
4242
CACHE_KEY_BUILD: ${{ needs.workflow-setup.outputs.CACHE_KEY_BUILD }}
4343
DOCKER_IMAGE: ghcr.io/${{ needs.workflow-setup.outputs.GITHUB_REPOSITORY_NAME }}/plenum-build
@@ -46,7 +46,7 @@ jobs:
4646
build_packages:
4747
name: Build Packages
4848
needs: [workflow-setup, build-docker-image]
49-
uses: hyperledger/indy-shared-gha/.github/workflows/buildpackages.yaml@v1
49+
uses: hyperledger/indy-shared-gha/.github/workflows/buildpackages.yaml@v2
5050
with:
5151
DOCKER_IMAGE: ghcr.io/${{ needs.workflow-setup.outputs.GITHUB_REPOSITORY_NAME }}/plenum-build:${{ needs.workflow-setup.outputs.UBUNTU_VERSION }}
5252
UBUNTU_VERSION: ${{ needs.workflow-setup.outputs.UBUNTU_VERSION }}
@@ -66,7 +66,7 @@ jobs:
6666
name: Publish Artifacts
6767
needs: [workflow-setup, plenum_tests]
6868
if: needs.workflow-setup.outputs.publish == 'true'
69-
uses: hyperledger/indy-shared-gha/.github/workflows/publish_artifacts.yaml@v1
69+
uses: hyperledger/indy-shared-gha/.github/workflows/publish_artifacts.yaml@v2
7070
with:
7171
COMPONENT: 'dev'
7272
UBUNTU_VERSION: ${{ needs.workflow-setup.outputs.UBUNTU_VERSION }}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
FROM ubuntu:22.04
2+
3+
ARG uid=1000
4+
ARG user=indy
5+
6+
RUN apt-get update -y && apt-get install -y \
7+
# common stuff
8+
git \
9+
apt-transport-https \
10+
apt-utils\
11+
wget\
12+
curl\
13+
jq\
14+
gnupg
15+
16+
# ========================================================================================================
17+
# Update repository signing keys
18+
# --------------------------------------------------------------------------------------------------------
19+
# Hyperledger
20+
RUN apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 9692C00E657DDE61 && \
21+
# Sovrin
22+
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys CE7709D068DB5E88
23+
# ========================================================================================================
24+
25+
# Plenum
26+
# - https://github.com/hyperledger/indy-plenum/issues/1546
27+
# - Needed to pick up rocksdb=5.8.8
28+
#RUN echo "deb https://hyperledger.jfrog.io/artifactory/indy focal dev" >> /etc/apt/sources.list && \
29+
# echo "deb https://repo.sovrin.org/deb bionic master" >> /etc/apt/sources.list && \
30+
# echo "deb https://repo.sovrin.org/sdk/deb bionic master" >> /etc/apt/sources.list
31+
32+
# TODO change this to official repo
33+
RUN echo "deb [trusted=yes] http://209.141.41.82:8000/ packagedir/" >> /etc/apt/sources.list
34+
35+
36+
RUN apt-get update -y && apt-get install -y \
37+
# Python
38+
python3-pip \
39+
rubygems && \
40+
gem install --no-document dotenv:2.8.1 fpm:1.15.0 && \
41+
pip3 install Cython==0.29.36
42+

.github/workflows/publishRelease.yaml

+4-4
Original file line numberDiff line numberDiff line change
@@ -34,12 +34,12 @@ jobs:
3434
uses: actions/checkout@v4
3535
- name: get-release-info
3636
id: get-release-info
37-
uses: hyperledger/indy-shared-gha/.github/actions/get-release-info@v1
37+
uses: hyperledger/indy-shared-gha/.github/actions/get-release-info@v2
3838
with:
3939
versionString: "${{ github.event.head_commit.message }}"
4040
- name: workflow-setup
4141
id: workflow-setup
42-
uses: hyperledger/indy-shared-gha/.github/actions/workflow-setup@v1
42+
uses: hyperledger/indy-shared-gha/.github/actions/workflow-setup@v2
4343

4444
createRelease:
4545
name: Create Release
@@ -111,7 +111,7 @@ jobs:
111111
name: Publish Artifacts
112112
needs: [release-infos, createRelease]
113113
if: needs.release-infos.outputs.isVersionBump == 'true' && needs.release-infos.outputs.publish == 'true'
114-
uses: hyperledger/indy-shared-gha/.github/workflows/publish_artifacts.yaml@v1
114+
uses: hyperledger/indy-shared-gha/.github/workflows/publish_artifacts.yaml@v2
115115
with:
116116
COMPONENT: ${{ needs.release-infos.outputs.component }}
117117
UBUNTU_VERSION: ${{ needs.release-infos.outputs.UBUNTU_VERSION }}
@@ -124,7 +124,7 @@ jobs:
124124
convertPyVersion:
125125
name: "Convert to python version flavour"
126126
needs: [release-infos, publish_artifacts]
127-
uses: hyperledger/indy-shared-gha/.github/workflows/pyVersionConversion.yaml@v1
127+
uses: hyperledger/indy-shared-gha/.github/workflows/pyVersionConversion.yaml@v2
128128
with:
129129
VERSIONTAG: ${{ needs.release-infos.outputs.VERSIONTAG }}
130130

.github/workflows/releasepr.yaml

+5-5
Original file line numberDiff line numberDiff line change
@@ -26,24 +26,24 @@ jobs:
2626
uses: actions/checkout@v4
2727
- name: get-release-info
2828
id: get-release-info
29-
uses: hyperledger/indy-shared-gha/.github/actions/get-release-info@v1
29+
uses: hyperledger/indy-shared-gha/.github/actions/get-release-info@v2
3030
with:
3131
versionString: "${{ github.event.pull_request.body }}"
3232
- name: workflow-setup
3333
id: workflow-setup
34-
uses: hyperledger/indy-shared-gha/.github/actions/workflow-setup@v1
34+
uses: hyperledger/indy-shared-gha/.github/actions/workflow-setup@v2
3535

3636
lint:
3737
name: Lint
3838
needs: [release-infos]
3939
if: needs.release-infos.outputs.isVersionBump == 'true'
40-
uses: hyperledger/indy-shared-gha/.github/workflows/lint.yaml@v1
40+
uses: hyperledger/indy-shared-gha/.github/workflows/lint.yaml@v2
4141

4242
build-docker-image:
4343
name: Create Builder Image
4444
needs: [release-infos, lint]
4545
if: needs.release-infos.outputs.isVersionBump == 'true'
46-
uses: hyperledger/indy-shared-gha/.github/workflows/buildimage.yaml@v1
46+
uses: hyperledger/indy-shared-gha/.github/workflows/buildimage.yaml@v2
4747
with:
4848
CACHE_KEY_BUILD: ${{ needs.release-infos.outputs.CACHE_KEY_BUILD }}
4949
DOCKER_IMAGE: ghcr.io/${{ needs.release-infos.outputs.GITHUB_REPOSITORY_NAME }}/plenum-build
@@ -53,7 +53,7 @@ jobs:
5353
name: Build Packages
5454
needs: [release-infos, build-docker-image]
5555
if: needs.release-infos.outputs.isVersionBump == 'true'
56-
uses: hyperledger/indy-shared-gha/.github/workflows/buildpackages.yaml@v1
56+
uses: hyperledger/indy-shared-gha/.github/workflows/buildpackages.yaml@v2
5757
with:
5858
DOCKER_IMAGE: ghcr.io/${{ needs.release-infos.outputs.GITHUB_REPOSITORY_NAME }}/plenum-build:${{ needs.release-infos.outputs.UBUNTU_VERSION }}
5959
UBUNTU_VERSION: ${{ needs.release-infos.outputs.UBUNTU_VERSION }}

.github/workflows/tag.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,12 @@ jobs:
2121
fetch-depth: 0
2222
- name: extract branch
2323
id: get-branch
24-
uses: hyperledger/indy-shared-gha/.github/actions/branch-from-tag@v1
24+
uses: hyperledger/indy-shared-gha/.github/actions/branch-from-tag@v2
2525
with:
2626
tag: ${{ github.ref }}
2727
- name: get-release-info
2828
id: get-release-info
29-
uses: hyperledger/indy-shared-gha/.github/actions/get-release-info@v1
29+
uses: hyperledger/indy-shared-gha/.github/actions/get-release-info@v2
3030
with:
3131
versionString: "${{ github.ref }}"
3232

build-scripts/ubuntu-2204/README.md

+30
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
### Build indy-plenum using docker
2+
3+
```
4+
./build-indy-plenum-docker.sh <path-to-sources> <version>
5+
```
6+
Built package is placed in a docker volume `indy-plenum-deb-u1604`.
7+
8+
### Build indy-plenum
9+
10+
```
11+
./build-indy-plenum.sh <path to sources> <version> <output-path: default='.'>
12+
```
13+
14+
Built package is placed in the `output-path` folder.
15+
16+
### Build 3rd-party dependencies using docker
17+
18+
```
19+
./build-3rd-parties-docker.sh
20+
```
21+
22+
Built packages are placed in a docker volume `indy-plenum-deb-u1604`.
23+
24+
### Build 3rd-party dependencies
25+
26+
```
27+
./build-3rd-parties-docker.sh <output-path: default='.'>
28+
```
29+
30+
Built packages are placed in the `output-path` folder.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
#!/usr/bin/env bash
2+
3+
set -x
4+
set -e
5+
6+
7+
PKG_SOURCE_PATH=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )/../../
8+
9+
if [ -z "$2" ]; then
10+
CMD="/input/build-scripts/ubuntu-2204/build-3rd-parties.sh /output"
11+
else
12+
CMD="$2"
13+
fi
14+
15+
PKG_NAME=indy-plenum
16+
IMAGE_NAME="${PKG_NAME}-build-u2204"
17+
OUTPUT_VOLUME_NAME="${1:-"${PKG_NAME}-deb-u2204"}"
18+
19+
docker build -t "${PKG_NAME}-build-u2204" -f $PKG_SOURCE_PATH/.github/workflows/build/Dockerfile.ubuntu-2204 .
20+
docker volume create --name "${OUTPUT_VOLUME_NAME}"
21+
22+
docker run \
23+
-i \
24+
--rm \
25+
-v "${PKG_SOURCE_PATH}:/input" \
26+
-v "${OUTPUT_VOLUME_NAME}:/output" \
27+
"${IMAGE_NAME}" \
28+
$CMD

0 commit comments

Comments
 (0)