github.com/muhammedhassanm/blockchain@v0.0.0-20200120143007-697261defd4d/sawtooth-core-master/adm/Dockerfile-installed (about)

     1  # Copyright 2018 Cargill Incorporated
     2  #
     3  # Licensed under the Apache License, Version 2.0 (the "License");
     4  # you may not use this file except in compliance with the License.
     5  # You may obtain a copy of the License at
     6  #
     7  #     http://www.apache.org/licenses/LICENSE-2.0
     8  #
     9  # Unless required by applicable law or agreed to in writing, software
    10  # distributed under the License is distributed on an "AS IS" BASIS,
    11  # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    12  # See the License for the specific language governing permissions and
    13  # limitations under the License.
    14  
    15  # docker build -f adm/Dockerfile-installed -t sawtooth-admin-tools .
    16  
    17  # -------------=== admin tools build ===-------------
    18  FROM ubuntu:xenial as adm-builder
    19  
    20  ENV VERSION=AUTO_STRICT
    21  
    22  RUN apt-get update \
    23   && apt-get install -y \
    24   curl \
    25   gcc \
    26   libssl-dev \
    27   libzmq3-dev \
    28   pkg-config \
    29   unzip
    30  
    31  # For Building Protobufs
    32  RUN curl https://sh.rustup.rs -sSf | sh -s -- -y \
    33   && curl -OLsS https://github.com/google/protobuf/releases/download/v3.5.1/protoc-3.5.1-linux-x86_64.zip \
    34   && unzip protoc-3.5.1-linux-x86_64.zip -d protoc3 \
    35   && rm protoc-3.5.1-linux-x86_64.zip
    36  
    37  ENV PATH=$PATH:/protoc3/bin
    38  RUN /root/.cargo/bin/cargo install cargo-deb
    39  
    40  COPY . /project
    41  
    42  WORKDIR /project/adm
    43  
    44  RUN /root/.cargo/bin/cargo deb
    45  
    46  # -------------=== admin tools docker build ===-------------
    47  FROM ubuntu:xenial
    48  
    49  COPY --from=adm-builder /project/adm/target/debian/sawadm_*.deb /tmp
    50  
    51  RUN apt-get update \
    52   && dpkg -i /tmp/sawadm_*.deb || true \
    53   && apt-get -f -y install