github.com/mysteriumnetwork/node@v0.0.0-20240516044423-365054f76801/bin/builder_run (about)

     1  #!/bin/bash
     2  
     3  ###########################################################################
     4  # Packaging script which creates Debian package using builder image
     5  #
     6  # Requirements:
     7  #    docker
     8  #    mysteriumnetwork/mysterium-node-builder docker image
     9  #
    10  #
    11  # To execute :
    12  #> bin/builder_run some_command_to_execute
    13  
    14  # Usage:
    15  #> bin/builder_run pwd
    16  #> bin/builder_run bin/package_all <version>
    17  #> bin/builder_run bin/build; bin/package_debian 0.0.1 amd64
    18  
    19  COMMAND=$@
    20  if [ -z "$COMMAND" ]; then
    21      printf "\e[0;31m%s\e[0m\n" "Missing command!"
    22      exit 1
    23  fi
    24  
    25  docker run --rm -ti \
    26      -v $(pwd):/go/src/github.com/mysteriumnetwork/node \
    27      mysteriumnetwork/mysterium-node-builder "${COMMAND}"