Skip to content

Instantly share code, notes, and snippets.

@jayhale
Created May 7, 2019 12:07
Show Gist options
  • Save jayhale/4ac4009e5e7cbc06f5dbcb1fd6f6ed7c to your computer and use it in GitHub Desktop.
Save jayhale/4ac4009e5e7cbc06f5dbcb1fd6f6ed7c to your computer and use it in GitHub Desktop.
Django staticfiles on Zeit Now: now_build_staticfiles.sh
# now_build_staticfiles.sh
# Install Python 3.6 since it is missing in the Now build environment
yum install -y https://centos6.iuscommunity.org/ius-release.rpm
yum install -y python36u
# Install pip
curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py
python3.6 get-pip.py
# Install project requirements
pip install -r requirements.txt
# Build staticfiles
python3.6 manage.py collectstatic
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment