Skip to content

Ubuntu 22.04 new apt command and new repo file #1905

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 11 commits into from
Feb 7, 2025
39 changes: 16 additions & 23 deletions .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# See here for image contents: https://github.com/microsoft/vscode-dev-containers/tree/v0.205.2/containers/ubuntu/.devcontainer/base.Dockerfile
# See here for image contents: https://github.com/microsoft/vscode-dev-containers/tree/main/containers/ubuntu/.devcontainer/base.Dockerfile

# [Choice] Ubuntu version (use hirsuite or bionic on local arm64/Apple Silicon): hirsute, focal, bionic
ARG VARIANT="focal"
# [Choice] Ubuntu version (use ubuntu-22.04 or ubuntu-18.04 on local arm64/Apple Silicon): ubuntu-22.04, ubuntu-20.04, ubuntu-18.04
ARG VARIANT="ubuntu-22.04"
FROM mcr.microsoft.com/vscode/devcontainers/base:${VARIANT}

RUN apt-get update -y && apt-get install -y \
Expand All @@ -16,23 +16,19 @@ RUN apt-get update -y && apt-get install -y \
jq

# ========================================================================================================
# Update repository signing keys
# Get repository signing keys
# --------------------------------------------------------------------------------------------------------
# Hyperledger
RUN apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 9692C00E657DDE61 && \
# Sovrin
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys CE7709D068DB5E88
RUN gpg --keyserver keyserver.ubuntu.com --recv-keys 9692C00E657DDE61 && \
gpg --export 9692C00E657DDE61 > /etc/apt/keyrings/hyperledger.gpg
# ========================================================================================================

# Plenum
# - https://github.com/hyperledger/indy-plenum/issues/1546
# - Needed to pick up rocksdb=5.8.8
RUN echo "deb https://hyperledger.jfrog.io/artifactory/indy focal dev" >> /etc/apt/sources.list && \
echo "deb http://security.ubuntu.com/ubuntu bionic-security main" >> /etc/apt/sources.list && \
echo "deb https://repo.sovrin.org/deb bionic master" >> /etc/apt/sources.list && \
echo "deb https://repo.sovrin.org/sdk/deb bionic master" >> /etc/apt/sources.list
RUN echo "deb [signed-by=/etc/apt/keyrings/hyperledger.gpg] https://hyperledger.jfrog.io/artifactory/indy jammy dev rc" > /etc/apt/sources.list.d/hyperledger.list

RUN apt-get update -y && apt-get install -y \
RUN apt update -y && apt install -y \
# Python
python3-pip \
python3-nacl \
Expand All @@ -53,22 +49,19 @@ RUN apt-get update -y && apt-get install -y \
gcc \
make \
# Indy Node and Plenum
libssl1.0.0 \
ursa=0.3.2-1 \
# Indy SDK
libindy=1.15.0~1625-bionic \
# Need to move libursa.so to parent dir
&& mv /usr/lib/ursa/* /usr/lib && rm -rf /usr/lib/ursa
# Indy SDK is not used anymore
#libindy \
libssl3

RUN pip3 install -U \
# Required by setup.py
setuptools==50.3.2 \
'pyzmq==22.3.0' \
setuptools==75.8.0 \
pyzmq==26.2.1 \
Cython==0.29.36


# install fpm
RUN gem install --no-document rake dotenv:2.8.1 fpm:1.14.2
RUN gem install --no-document rake dotenv:2.8.1 fpm:1.15.0 && \
pip3 install Cython==0.29.36

RUN apt-get -y autoremove \
RUN apt -y autoremove \
&& rm -rf /var/lib/apt/lists/*
4 changes: 2 additions & 2 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@
"name": "Ubuntu",
"build": {
"dockerfile": "Dockerfile",
// Update 'VARIANT' to pick an Ubuntu version: hirsute, focal, bionic
// Update 'VARIANT' to pick an Ubuntu version: jammy, hirsute, focal, bionic
// Use hirsute or bionic on local arm64/Apple Silicon.
"args": { "VARIANT": "focal" }
"args": { "VARIANT": "jammy" }
},

"customizations": {
Expand Down
22 changes: 6 additions & 16 deletions .github/workflows/build/Dockerfile.ubuntu-2204
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ FROM ubuntu:22.04
ARG uid=1000
ARG user=indy

RUN apt-get update -y && apt-get install -y \
RUN apt update -y && apt install -y \
# common stuff
git \
wget \
Expand All @@ -15,14 +15,11 @@ RUN apt-get update -y && apt-get install -y \
jq

# ========================================================================================================
# Update repository signing keys
# Get repository signing keys
# --------------------------------------------------------------------------------------------------------
# Hyperledger
RUN apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 9692C00E657DDE61 && \
# Sovrin
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys CE7709D068DB5E88 && \
# Bionic-Security
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 3B4FE6ACC0B21F32
RUN gpg --keyserver keyserver.ubuntu.com --recv-keys 9692C00E657DDE61 && \
gpg --export 9692C00E657DDE61 > /etc/apt/keyrings/hyperledger.gpg
# ========================================================================================================

# ToDo:
Expand All @@ -31,16 +28,9 @@ RUN apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 9692C00E657DDE61 &&
# Plenum
# - https://github.com/hyperledger/indy-plenum/issues/1546
# - Needed to pick up rocksdb=5.8.8
RUN echo "deb https://hyperledger.jfrog.io/artifactory/indy jammy dev rc" >> /etc/apt/sources.list && \
echo "deb http://security.ubuntu.com/ubuntu bionic-security main" >> /etc/apt/sources.list && \
echo "deb https://repo.sovrin.org/deb bionic master" >> /etc/apt/sources.list && \
echo "deb https://repo.sovrin.org/sdk/deb bionic master" >> /etc/apt/sources.list
RUN echo "deb [signed-by=/etc/apt/keyrings/hyperledger.gpg] https://hyperledger.jfrog.io/artifactory/indy jammy dev rc" > /etc/apt/sources.list.d/hyperledger.list

RUN apt-get update -y && apt-get install -y \
rubygems \
python3-pip && \
apt-get -y autoremove && \
rm -rf /var/lib/apt/lists/*
RUN apt update -y && apt install -y rubygems python3-pip && apt-get -y autoremove && rm -rf /var/lib/apt/lists/*

# install fpm
RUN gem install --no-document rake dotenv:2.8.1 fpm:1.15.0 && \
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/releasepr.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ on:
paths:
- '!**'
- "indy_node/__version__.json"
workflow_dispatch:

jobs:
release-infos:
Expand Down
41 changes: 18 additions & 23 deletions build-scripts/ubuntu-2204/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ FROM ubuntu:22.04
ARG uid=1000
ARG user=indy

RUN apt-get update -y && apt-get install -y \
RUN apt update -y && apt install -y \
# common stuff
git \
wget \
Expand All @@ -13,28 +13,19 @@ RUN apt-get update -y && apt-get install -y \
apt-utils

# ========================================================================================================
# Update repository signing keys
# Get repository signing keys
# --------------------------------------------------------------------------------------------------------
# Hyperledger
RUN apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 9692C00E657DDE61 && \
# Sovrin
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys CE7709D068DB5E88 && \
# Bionic-Security
apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 3B4FE6ACC0B21F32
RUN gpg --keyserver keyserver.ubuntu.com --recv-keys 9692C00E657DDE61 && \
gpg --export 9692C00E657DDE61 > /etc/apt/keyrings/hyperledger.gpg
# ========================================================================================================

# Plenum
# - https://github.com/hyperledger/indy-plenum/issues/1546
# - Needed to pick up rocksdb=5.8.8
RUN echo "deb https://hyperledger.jfrog.io/artifactory/indy jammy dev" >> /etc/apt/sources.list && \
echo "deb http://security.ubuntu.com/ubuntu bionic-security main" >> /etc/apt/sources.list && \
echo "deb https://repo.sovrin.org/deb bionic master" >> /etc/apt/sources.list && \
echo "deb https://repo.sovrin.org/sdk/deb bionic master" >> /etc/apt/sources.list
RUN echo "deb [signed-by=/etc/apt/keyrings/hyperledger.gpg] https://hyperledger.jfrog.io/artifactory/indy jammy dev rc" > /etc/apt/sources.list.d/hyperledger.list

# Sovrin
RUN apt-key adv --keyserver keyserver.ubuntu.com --recv-keys CE7709D068DB5E88

RUN apt-get update -y && apt-get install -y \
RUN apt update -y && apt install -y \
# Python
python3-pip \
python3-nacl \
Expand All @@ -55,21 +46,25 @@ RUN apt-get update -y && apt-get install -y \
gcc \
make \
# Indy Node and Plenum
libssl1.0.0 \
ursa=0.3.2-1 \
libssl3
# Indy Node and Plenum
# Indy SDK is not used anymore
#libindy \
# rsa=0.3.2-1 \
# Indy SDK
libindy=1.15.0~1625-bionic \
# libindy=1.15.0~1625-bionic \
# Need to move libursa.so to parent dir
&& mv /usr/lib/ursa/* /usr/lib && rm -rf /usr/lib/ursa
# && mv /usr/lib/ursa/* /usr/lib && rm -rf /usr/lib/ursa

RUN pip3 install -U \
# Required by setup.py
setuptools==50.3.2 \
'pyzmq==22.3.0'
setuptools==75.8.0 \
pyzmq==26.2.1

# install fpm
RUN gem install --no-document rake dotenv:2.8.1 fpm:1.14.2
RUN gem install --no-document rake dotenv:2.8.1 fpm:1.15.0 && \
pip3 install Cython==0.29.36

RUN apt-get -y autoremove \
RUN apt -y autoremove \
&& rm -rf /var/lib/apt/lists/*

Loading