Skip to content

Instantly share code, notes, and snippets.

@sbenthall
Created October 15, 2022 23:01
Show Gist options
  • Save sbenthall/f9344d9d40bb47f5cf18c39271f5b93a to your computer and use it in GitHub Desktop.
Save sbenthall/f9344d9d40bb47f5cf18c39271f5b93a to your computer and use it in GitHub Desktop.
cache/pip/wheels/3f/0c/68/cfda18ca3ce656cd4629ba10e535e2ea081638fe4b396448c8
default: Successfully built mod_wsgi
default: Installing collected packages: mod_wsgi
default: Successfully installed mod_wsgi-4.9.4
default: WARNING: Running pip as the 'root' user can result in broken permissions and conflicting behaviour with the system package manager. It is recommended to use a virtual environment instead: https://pip.pypa.io/warnings/venv
default:
default: # Create the virtual environment
default: python3 -m venv $VENV_PATH
default:
default: # Activate the environment
default: # shellcheck disable=SC1090
default: source $VENV_PATH/bin/activate
default: # This file must be used with "source bin/activate" *from bash*
default: # you cannot run it directly
default:
default: deactivate () {
default: # reset old environment variables
default: if [ -n "${_OLD_VIRTUAL_PATH:-}" ] ; then
default: PATH="${_OLD_VIRTUAL_PATH:-}"
default: export PATH
default: unset _OLD_VIRTUAL_PATH
default: fi
default: if [ -n "${_OLD_VIRTUAL_PYTHONHOME:-}" ] ; then
default: PYTHONHOME="${_OLD_VIRTUAL_PYTHONHOME:-}"
default: export PYTHONHOME
default: unset _OLD_VIRTUAL_PYTHONHOME
default: fi
default:
default: # This should detect bash and zsh, which have a hash command that must
default: # be called to get it to forget past commands. Without forgetting
default: # past commands the $PATH changes we made may not be respected
default: if [ -n "${BASH:-}" -o -n "${ZSH_VERSION:-}" ] ; then
default: hash -r
default: fi
default:
default: if [ -n "${_OLD_VIRTUAL_PS1:-}" ] ; then
default: PS1="${_OLD_VIRTUAL_PS1:-}"
default: export PS1
default: unset _OLD_VIRTUAL_PS1
default: fi
default:
default: unset VIRTUAL_ENV
default: if [ ! "${1:-}" = "nondestructive" ] ; then
default: # Self destruct!
default: unset -f deactivate
default: fi
default: }
default:
default: # unset irrelevant variables
default: deactivate nondestructive
default:
default: VIRTUAL_ENV="/var/www/roundware"
default: export VIRTUAL_ENV
default:
default: _OLD_VIRTUAL_PATH="$PATH"
default: PATH="$VIRTUAL_ENV/bin:$PATH"
default: export PATH
default:
default: # unset PYTHONHOME if set
default: # this will fail if PYTHONHOME is set to the empty string (which is bad anyway)
default: # could use `if (set -u; : $PYTHONHOME) ;` in bash
default: if [ -n "${PYTHONHOME:-}" ] ; then
default: _OLD_VIRTUAL_PYTHONHOME="${PYTHONHOME:-}"
default: unset PYTHONHOME
default: fi
default:
default: if [ -z "${VIRTUAL_ENV_DISABLE_PROMPT:-}" ] ; then
default: _OLD_VIRTUAL_PS1="${PS1:-}"
default: if [ "x(roundware) " != x ] ; then
default: PS1="(roundware) ${PS1:-}"
default: else
default: if [ "`basename \"$VIRTUAL_ENV\"`" = "__" ] ; then
default: # special case for Aspen magic directories
default: # see https://aspen.io/
default: PS1="[`basename \`dirname \"$VIRTUAL_ENV\"\``] $PS1"
default: else
default: PS1="(`basename \"$VIRTUAL_ENV\"`)$PS1"
default: fi
default: fi
default: export PS1
default: fi
default:
default: # This should detect bash and zsh, which have a hash command that must
default: # be called to get it to forget past commands. Without forgetting
default: # past commands the $PATH changes we made may not be respected
default: if [ -n "${BASH:-}" -o -n "${ZSH_VERSION:-}" ] ; then
default: hash -r
default: fi
default: # Set python path to use production code
default: export PYTHONPATH=$CODE_PATH
default:
default: # Setup Postgresql database
default: if ! su - postgres -c "psql -tAc \"SELECT 1 FROM pg_roles WHERE rolname='round'\"" | grep -q 1; then
default: su - postgres -c 'psql -c "create role round superuser login;"'
default: fi
default: CREATE ROLE
default:
default: if ! su - postgres -c "psql -lqt" | cut -d \| -f 1 | grep -qw 'roundware'; then
default: su - postgres -c 'psql -c "create database roundware"'
default: fi
default: CREATE DATABASE
default:
default: su - postgres -c 'psql -c "grant all on database roundware to round"'
default: GRANT
default: su - postgres -c "psql -c \"alter user round password 'round'\""
default: ALTER ROLE
default:
default: # File/directory configurations
default: mkdir -p $MEDIA_PATH
default: mkdir -p $STATIC_PATH
default:
default: # copy test audio file to media storage
default: cp $SOURCE_PATH/files/rw_test_audio1.wav $MEDIA_PATH
default: cp $SOURCE_PATH/files/rw_test_audio1.mp3 $MEDIA_PATH
default:
default: # Copy default production settings file
default: mkdir -p $WWW_PATH/settings
default: cp $SOURCE_PATH/files/var-www-roundware-settings.py $WWW_PATH/settings/roundware_production.py
default:
default: # Setup roundware log and logrotate
default: touch /var/log/roundware
default: chown $USERNAME:$USERNAME /var/log/roundware
default:
default: # Run the production upgrade/deployment script
default: $SOURCE_PATH/deploy.sh
default:
default: # Store the script start path
default: SOURCE_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
default:
default: # Check if we are installing via vagrant (assuming standard Vagrant /vagrant share)
default: if [ -d "/vagrant" ]; then
default: echo "Found Vagrant."
default: FOUND_VAGRANT=true
default: fi
default: Found Vagrant.
default:
default: # Default user name.
default: USERNAME="roundware"
default:
default: # Use vagrant username/directories used when available.
default: if [ "$FOUND_VAGRANT" = true ]; then
default: # Change the user to the vagrant default.
default: USERNAME="vagrant"
default: fi
default:
default: # Set paths/directories
default: WWW_PATH="/var/www/roundware"
default: CODE_PATH="$WWW_PATH/source"
default: VENV_PATH="$WWW_PATH"
default:
default: # Install/Update the production code
default: # TODO: Better deployment method.
default: rm -rf $CODE_PATH
default: mkdir -p $CODE_PATH
default: cp -R $SOURCE_PATH/. $CODE_PATH
default:
default: # Activate the environment
default: source $VENV_PATH/bin/activate
default: # This file must be used with "source bin/activate" *from bash*
default: # you cannot run it directly
default:
default: deactivate () {
default: # reset old environment variables
default: if [ -n "${_OLD_VIRTUAL_PATH:-}" ] ; then
default: PATH="${_OLD_VIRTUAL_PATH:-}"
default: export PATH
default: unset _OLD_VIRTUAL_PATH
default: fi
default: if [ -n "${_OLD_VIRTUAL_PYTHONHOME:-}" ] ; then
default: PYTHONHOME="${_OLD_VIRTUAL_PYTHONHOME:-}"
default: export PYTHONHOME
default: unset _OLD_VIRTUAL_PYTHONHOME
default: fi
default:
default: # This should detect bash and zsh, which have a hash command that must
default: # be called to get it to forget past commands. Without forgetting
default: # past commands the $PATH changes we made may not be respected
default: if [ -n "${BASH:-}" -o -n "${ZSH_VERSION:-}" ] ; then
default: hash -r
default: fi
default:
default: if [ -n "${_OLD_VIRTUAL_PS1:-}" ] ; then
default: PS1="${_OLD_VIRTUAL_PS1:-}"
default: export PS1
default: unset _OLD_VIRTUAL_PS1
default: fi
default:
default: unset VIRTUAL_ENV
default: if [ ! "${1:-}" = "nondestructive" ] ; then
default: # Self destruct!
default: unset -f deactivate
default: fi
default: }
default:
default: # unset irrelevant variables
default: deactivate nondestructive
default:
default: VIRTUAL_ENV="/var/www/roundware"
default: export VIRTUAL_ENV
default:
default: _OLD_VIRTUAL_PATH="$PATH"
default: PATH="$VIRTUAL_ENV/bin:$PATH"
default: export PATH
default:
default: # unset PYTHONHOME if set
default: # this will fail if PYTHONHOME is set to the empty string (which is bad anyway)
default: # could use `if (set -u; : $PYTHONHOME) ;` in bash
default: if [ -n "${PYTHONHOME:-}" ] ; then
default: _OLD_VIRTUAL_PYTHONHOME="${PYTHONHOME:-}"
default: unset PYTHONHOME
default: fi
default:
default: if [ -z "${VIRTUAL_ENV_DISABLE_PROMPT:-}" ] ; then
default: _OLD_VIRTUAL_PS1="${PS1:-}"
default: if [ "x(roundware) " != x ] ; then
default: PS1="(roundware) ${PS1:-}"
default: else
default: if [ "`basename \"$VIRTUAL_ENV\"`" = "__" ] ; then
default: # special case for Aspen magic directories
default: # see https://aspen.io/
default: PS1="[`basename \`dirname \"$VIRTUAL_ENV\"\``] $PS1"
default: else
default: PS1="(`basename \"$VIRTUAL_ENV\"`)$PS1"
default: fi
default: fi
default: export PS1
default: fi
default:
default: # This should detect bash and zsh, which have a hash command that must
default: # be called to get it to forget past commands. Without forgetting
default: # past commands the $PATH changes we made may not be respected
default: if [ -n "${BASH:-}" -o -n "${ZSH_VERSION:-}" ] ; then
default: hash -r
default: fi
default:
default: # Set python path to use production code
default: export PYTHONPATH=$CODE_PATH
default:
default: # Install upgrade pip
default: python -m pip install -U pip wheel setuptools
default: Collecting pip
default: Using cached pip-22.3-py3-none-any.whl (2.1 MB)
default: Collecting wheel
default: Downloading wheel-0.37.1-py2.py3-none-any.whl (35 kB)
default: Collecting setuptools
default: Downloading setuptools-65.5.0-py3-none-any.whl (1.2 MB)
default: Installing collected packages: pip, wheel, setuptools
default: Attempting uninstall: pip
default: Found existing installation: pip 20.0.2
default: Uninstalling pip-20.0.2:
default: Successfully uninstalled pip-20.0.2
default: Attempting uninstall: setuptools
default: Found existing installation: setuptools 44.0.0
default: Uninstalling setuptools-44.0.0:
default: Successfully uninstalled setuptools-44.0.0
default: Successfully installed pip-22.3 setuptools-65.5.0 wheel-0.37.1
default:
default: # Install Roundware requirements
default: python -m pip install -r $CODE_PATH/requirements.txt --upgrade
default: Collecting Django==3.0
default: Downloading Django-3.0-py3-none-any.whl (7.4 MB)
default: ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 7.4/7.4 MB 3.4 MB/s eta 0:00:00
default: Collecting djangorestframework
default: Downloading djangorestframework-3.14.0-py3-none-any.whl (1.1 MB)
default: ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 1.1/1.1 MB 7.6 MB/s eta 0:00:00
default: Collecting django-filter<2.3
default: Downloading django_filter-2.2.0-py3-none-any.whl (69 kB)
default: ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 69.6/69.6 kB 10.1 MB/s eta 0:00:00
default: Collecting django-guardian==2.2.0
default: Downloading django_guardian-2.2.0-py3-none-any.whl (104 kB)
default: ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 104.9/104.9 kB 4.7 MB/s eta 0:00:00
default: Collecting psutil==3.4.2
default: Downloading psutil-3.4.2.tar.gz (274 kB)
default: ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 274.4/274.4 kB 6.2 MB/s eta 0:00:00
default: Preparing metadata (setup.py): started
default: Preparing metadata (setup.py): finished with status 'done'
default: Collecting python-magic==0.4.8
default: Downloading python-magic-0.4.8.tar.gz (132 kB)
default: ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 132.3/132.3 kB 9.1 MB/s eta 0:00:00
default: Preparing metadata (setup.py): started
default: Preparing metadata (setup.py): finished with status 'done'
default: Collecting django-braces==1.14.0
default: Downloading django_braces-1.14.0-py2.py3-none-any.whl (14 kB)
default: Collecting django-crispy-forms==1.9.1
default: Downloading django_crispy_forms-1.9.1-py2.py3-none-any.whl (108 kB)
default: ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 108.3/108.3 kB 10.2 MB/s eta 0:00:00
default: Collecting django-floppyforms==1.9.0
default: Downloading django_floppyforms-1.9.0-py2.py3-none-any.whl (306 kB)
default: ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 306.2/306.2 kB 3.1 MB/s eta 0:00:00
default: Collecting django-extra-views==0.13.0
default: Downloading django-extra-views-0.13.0.tar.gz (13 kB)
default: Preparing metadata (setup.py): started
default: Preparing metadata (setup.py): finished with status 'done'
default: Collecting django-sortedm2m==0.8.1
default: Downloading django-sortedm2m-0.8.1.tar.gz (26 kB)
default: Preparing metadata (setup.py): started
default: Preparing metadata (setup.py): finished with status 'error'
default: error: subprocess-exited-with-error
default:
default: × python setup.py egg_info did not run successfully.
default: │ exit code: 1
default: ╰─> [29 lines of output]
default: running egg_info
default: creating /tmp/pip-pip-egg-info-e391so_0/django_sortedm2m.egg-info
default: writing /tmp/pip-pip-egg-info-e391so_0/django_sortedm2m.egg-info/PKG-INFO
default: Traceback (most recent call last):
default: File "<string>", line 2, in <module>
default: File "<pip-setuptools-caller>", line 34, in <module>
default: File "/tmp/pip-install-z3ze529i/django-sortedm2m_2befd3b6ef174277927f2f6dd12bab84/setup.py", line 55, in <module>
default: setup(
default: File "/var/www/roundware/lib/python3.8/site-packages/setuptools/__init__.py", line 87, in setup
default: return distutils.core.setup(**attrs)
default: File "/var/www/roundware/lib/python3.8/site-packages/setuptools/_distutils/core.py", line 185, in setup
default: return run_commands(dist)
default: File "/var/www/roundware/lib/python3.8/site-packages/setuptools/_distutils/core.py", line 201, in run_commands
default: dist.run_commands()
default: File "/var/www/roundware/lib/python3.8/site-packages/setuptools/_distutils/dist.py", line 968, in run_commands
default: self.run_command(cmd)
default: File "/var/www/roundware/lib/python3.8/site-packages/setuptools/dist.py", line 1217, in run_command
default: super().run_command(command)
default: File "/var/www/roundware/lib/python3.8/site-packages/setuptools/_distutils/dist.py", line 987, in run_command
default: cmd_obj.run()
default: File "/var/www/roundware/lib/python3.8/site-packages/setuptools/command/egg_info.py", line 301, in run
default: writer(self, ep.name, os.path.join(self.egg_info, ep.name))
default: File "/var/www/roundware/lib/python3.8/site-packages/setuptools/command/egg_info.py", line 675, in write_pkg_info
default: metadata.write_pkg_info(cmd.egg_info)
default: File "/var/www/roundware/lib/python3.8/site-packages/setuptools/_distutils/dist.py", line 1136, in write_pkg_info
default: self.write_pkg_file(pkg_info)
default: File "/var/www/roundware/lib/python3.8/site-packages/setuptools/dist.py", line 233, in write_pkg_file
default: if not long_description.endswith("\n"):
default: AttributeError: 'UltraMagicString' object has no attribute 'endswith'
default: [end of output]
default:
default: note: This error originates from a subprocess, and is likely not a problem with pip.
default: error: metadata-generation-failed
default:
default: × Encountered error while generating package metadata.
default: ╰─> See above for output.
default:
default: note: This is an issue with the package mentioned above, not pip.
default: hint: See above for details.
The SSH command responded with a non-zero exit status. Vagrant
assumes that this means the command failed. The output for this command
should be in the log above. Please read the output to determine what
went wrong.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment