diff --git a/.github/workflows/pyinstaller.yml b/.github/workflows/pyinstaller.yml index 83d3a73b4..0f9a02a64 100644 --- a/.github/workflows/pyinstaller.yml +++ b/.github/workflows/pyinstaller.yml @@ -32,10 +32,12 @@ jobs: python-version: '3.x' architecture: 'x64' + # curl -sSL https://bootstrap.pypa.io/get-pip.py -o get-pip.py + # python3 get-pip.py "pip<20" + # => fails with https://github.com/pypa/setuptools/issues/3044 - name: Install Python package dependencies run: | - curl -sSL https://bootstrap.pypa.io/get-pip.py -o get-pip.py - python3 get-pip.py "pip<20" + pip3 -U pip pip3 show pip pip3 install -r requirements-dev.txt diff --git a/docker/Makefile b/docker/Makefile index 2979d367c..f5d2da1d6 100644 --- a/docker/Makefile +++ b/docker/Makefile @@ -40,6 +40,10 @@ clean_wheels: rm -rf ./.wheels mkdir -p ./.wheels/ +clean_docker: + -docker images | grep "crossbario/autobahn-python" | awk '{print $1}' | xargs docker rmi + + download_wheels: mkdir -p ./.wheels/ rm -f ./.wheels/*.whl @@ -63,12 +67,28 @@ docker_stop_rm: -docker rm $(docker ps -a -q -f) +show: + @echo + @echo + @echo "autobahn build configuration -------------------------------------------------------------------------------------------" + @echo + @echo " AUTOBAHN_BUILD_DATE = ${AUTOBAHN_BUILD_DATE}" + @echo " AUTOBAHN_BUILD_ID = ${AUTOBAHN_BUILD_ID}" + @echo " AUTOBAHN_VCS_REF = ${AUTOBAHN_VCS_REF}" + @echo " AUTOBAHN_VERSION = ${AUTOBAHN_VERSION}" + @echo "" + @echo " XBRNETWORK_EXE_FILENAME = ${XBRNETWORK_EXE_FILENAME}" + @echo + + build: build_cpy build_pypy test: test_cpy test_pypy publish: publish_cpy publish_pypy +list: list_cpy list_pypy + build_amd64: build_cpy_amd64 build_pypy_amd64 @@ -76,6 +96,8 @@ test_amd64: test_cpy_amd64 test_pypy_amd64 publish_amd64: publish_cpy_amd64 publish_pypy_amd64 +list_amd64: list_cpy_amd64 list_pypy_amd64 + build_arm64v8: build_cpy_arm64v8 build_pypy_arm64v8 @@ -83,6 +105,8 @@ test_arm64v8: test_cpy_arm64v8 test_pypy_arm64v8 publish_arm64v8: publish_cpy_arm64v8 publish_pypy_arm64v8 +list_arm64v8: list_cpy_arm64v8 list_pypy_arm64v8 + build_cpy: build_cpy_amd64 build_cpy_arm64v8 @@ -90,6 +114,8 @@ test_cpy: test_cpy_amd64 test_cpy_arm64v8 publish_cpy: publish_cpy_amd64 publish_cpy_arm64v8 +list_cpy: list_cpy_amd64 list_cpy_arm64v8 + build_pypy: build_pypy_amd64 build_pypy_arm64v8 @@ -97,6 +123,8 @@ test_pypy: test_pypy_amd64 test_pypy_arm64v8 publish_pypy: publish_pypy_amd64 publish_pypy_arm64v8 +list_pypy: list_pypy_amd64 list_pypy_arm64v8 + build_cpy_amd64: docker build \ @@ -119,6 +147,17 @@ publish_cpy_amd64: docker push crossbario/autobahn-python:cpy-amd64-${AUTOBAHN_VERSION} docker push crossbario/autobahn-python:cpy-amd64-${AUTOBAHN_VERSION}-${AUTOBAHN_BUILD_ID} +list_cpy_amd64: + @echo + @echo "autobahn-python:cpy-amd64 ----------------------------------------------------------------------------------------------" + @echo + @docker inspect --format='{{index .RepoDigests 0}}' crossbario/autobahn-python:cpy-amd64-${AUTOBAHN_VERSION}-${AUTOBAHN_BUILD_ID} + @echo + @docker images crossbario/autobahn-python:cpy-amd64 + @docker images crossbario/autobahn-python:cpy-amd64-${AUTOBAHN_VERSION} + @docker images crossbario/autobahn-python:cpy-amd64-${AUTOBAHN_VERSION}-${AUTOBAHN_BUILD_ID} + @docker images `docker inspect --format='{{index .RepoDigests 0}}' crossbario/autobahn-python:cpy-amd64-${AUTOBAHN_VERSION}-${AUTOBAHN_BUILD_ID}` + build_cpy_arm64v8: docker build \ @@ -141,6 +180,18 @@ publish_cpy_arm64v8: docker push crossbario/autobahn-python:cpy-arm64v8-${AUTOBAHN_VERSION} docker push crossbario/autobahn-python:cpy-arm64v8-${AUTOBAHN_VERSION}-${AUTOBAHN_BUILD_ID} +list_cpy_arm64v8: + @echo + @echo + @echo "autobahn-python:cpy-arm64v8 --------------------------------------------------------------------------------------------" + @echo + @docker inspect --format='{{index .RepoDigests 0}}' crossbario/autobahn-python:cpy-arm64v8-${AUTOBAHN_VERSION}-${AUTOBAHN_BUILD_ID} + @echo + @docker images crossbario/autobahn-python:cpy-arm64v8 + @docker images crossbario/autobahn-python:cpy-arm64v8-${AUTOBAHN_VERSION} + @docker images crossbario/autobahn-python:cpy-arm64v8-${AUTOBAHN_VERSION}-${AUTOBAHN_BUILD_ID} + @docker images `docker inspect --format='{{index .RepoDigests 0}}' crossbario/autobahn-python:cpy-arm64v8-${AUTOBAHN_VERSION}-${AUTOBAHN_BUILD_ID}` + build_pypy_amd64: docker build \ @@ -163,6 +214,18 @@ publish_pypy_amd64: docker push crossbario/autobahn-python:pypy-amd64-${AUTOBAHN_VERSION} docker push crossbario/autobahn-python:pypy-amd64-${AUTOBAHN_VERSION}-${AUTOBAHN_BUILD_ID} +list_pypy_amd64: + @echo + @echo + @echo "autobahn-python:pypy-amd64 --------------------------------------------------------------------------------------------" + @echo + @docker inspect --format='{{index .RepoDigests 0}}' crossbario/autobahn-python:pypy-amd64-${AUTOBAHN_VERSION}-${AUTOBAHN_BUILD_ID} + @echo + @docker images crossbario/autobahn-python:pypy-amd64 + @docker images crossbario/autobahn-python:pypy-amd64-${AUTOBAHN_VERSION} + @docker images crossbario/autobahn-python:pypy-amd64-${AUTOBAHN_VERSION}-${AUTOBAHN_BUILD_ID} + @docker images `docker inspect --format='{{index .RepoDigests 0}}' crossbario/autobahn-python:pypy-amd64-${AUTOBAHN_VERSION}-${AUTOBAHN_BUILD_ID}` + build_pypy_arm64v8: docker build \ @@ -185,6 +248,17 @@ publish_pypy_arm64v8: docker push crossbario/autobahn-python:pypy-arm64v8-${AUTOBAHN_VERSION} docker push crossbario/autobahn-python:pypy-arm64v8-${AUTOBAHN_VERSION}-${AUTOBAHN_BUILD_ID} +list_pypy_arm64v8: + @echo + @echo + @echo "autobahn-python:pypy-arm64v8 ------------------------------------------------------------------------------------------" + @echo + @docker inspect --format='{{index .RepoDigests 0}}' crossbario/autobahn-python:pypy-arm64v8-${AUTOBAHN_VERSION}-${AUTOBAHN_BUILD_ID} + @echo + @docker images crossbario/autobahn-python:pypy-arm64v8 + @docker images crossbario/autobahn-python:pypy-arm64v8-${AUTOBAHN_VERSION} + @docker images crossbario/autobahn-python:pypy-arm64v8-${AUTOBAHN_VERSION}-${AUTOBAHN_BUILD_ID} + @docker images `docker inspect --format='{{index .RepoDigests 0}}' crossbario/autobahn-python:pypy-arm64v8-${AUTOBAHN_VERSION}-${AUTOBAHN_BUILD_ID}` # Docker multi-arch manifest # diff --git a/docker/README.md b/docker/README.md index ab8936d9f..ca7472924 100644 --- a/docker/README.md +++ b/docker/README.md @@ -75,3 +75,18 @@ make build make test make publish ``` + + +## Checking built images + +To show the Docker image hashes and tags: + +``` +clear && make show list +``` + +To test the Docker images and print version infos: + +``` +clear && make test +``` diff --git a/pyinstaller/xbrnetwork.spec b/pyinstaller/xbrnetwork.spec index b1cb3f97a..030041b87 100644 --- a/pyinstaller/xbrnetwork.spec +++ b/pyinstaller/xbrnetwork.spec @@ -1,14 +1,16 @@ # -*- mode: python ; coding: utf-8 -*- + block_cipher = None a = Analysis(['../autobahn/xbr/_cli.py'], - pathex=['/home/oberstet/scm/crossbario/autobahn-python/pyinstaller'], + pathex=[], binaries=[], datas=[], hiddenimports=[], hookspath=['/home/oberstet/scm/crossbario/autobahn-python/pyinstaller'], + hooksconfig={}, runtime_hooks=[], excludes=[], win_no_prefer_redirects=False, @@ -17,11 +19,12 @@ a = Analysis(['../autobahn/xbr/_cli.py'], noarchive=False) pyz = PYZ(a.pure, a.zipped_data, cipher=block_cipher) + exe = EXE(pyz, a.scripts, a.binaries, a.zipfiles, - a.datas, + a.datas, [], name='xbrnetwork', debug=False, @@ -30,4 +33,8 @@ exe = EXE(pyz, upx=True, upx_exclude=[], runtime_tmpdir=None, - console=True ) + console=True, + disable_windowed_traceback=False, + target_arch=None, + codesign_identity=None, + entitlements_file=None ) diff --git a/tox.ini b/tox.ini index 0b0338e98..1ca4a0f4a 100644 --- a/tox.ini +++ b/tox.ini @@ -209,7 +209,8 @@ passenv = AUTOBAHN_VERSION XBRNETWORK_EXE_FILENAME deps = - pyinstaller==4.2 + pip + pyinstaller==4.8 commands = echo "Building with AUTOBAHN_BUILD_DATE={env:AUTOBAHN_BUILD_DATE}" echo "Building with AUTOBAHN_BUILD_ID={env:AUTOBAHN_BUILD_ID}" @@ -218,8 +219,9 @@ commands = echo "Building with XBRNETWORK_EXE_FILENAME={env:XBRNETWORK_EXE_FILENAME}" # Install pip v19.3.1 (yes, absolutely, we do not want the "new resolver" shit) - curl -sSL -o get-pip.py https://bootstrap.pypa.io/get-pip.py - python get-pip.py "pip<20" + # curl -sSL -o get-pip.py https://bootstrap.pypa.io/get-pip.py + # python get-pip.py # fails with https://github.com/pypa/setuptools/issues/3044 + # python get-pip.py "pip<20" pip show pip # Install development dependencies