Skip to content
This repository has been archived by the owner on Aug 4, 2021. It is now read-only.
/ peacecorps-site Public archive

A place to think and work on a new Peace Corps website.

License

Notifications You must be signed in to change notification settings

forumone/peacecorps-site

Repository files navigation

peacecorps-site

A place to think and work on a new Peace Corps website.

User Documentation

See the extended User Documentation for more information.

Setup

This is a Django application that depends on Python 3. For easy of use, we've included a Vagrantfile that will get you up and running in a nice, easy to use development environment.

Installing Vagrant

Download and install Vagrant from https://www.vagrantup.com/

Get Started

From the project directory, start up Vagrant:

$ vagrant up

This will kick off a process to provision and set up a development environment for you. If you'd prefer to do this on your own, you can see what happens in provision/dev/bootstrap.sh.

Once the initalization has finished, ssh in to the machine and start up Django's runserver:

$ vagrant ssh
$ python manage.py runserver 0.0.0.0:8000

To enable other users on your network to view in-progress work, the network configuration for Vagrant has been update to:

config.vm.network "public_network", type: "dhcp"

This sets up a bridged mode (you will be asked to select a network device to bridge).

When you vagrant ssh you can see what IP address your VM obtained from DHCP.

The setup script also creates an initial superuser for you. You can access the Django admin page at http://localhost:8000/admin and the username and password are provided below:

Username: testuser@peacecorps.gov Password: 0QDOyB!gfKkY23$UspzDM35%

Running Additional Django Commands

If you wish to run additional vagrant commands (like migrations), SSH in to the Vagrant virtual machine (vagrant ssh) and then run them like normal. For instance:

$ vagrant ssh
$ python manage.py makemigrations

Or, to run tests:

$ python manage.py test --settings=peacecorps.settings.test

Front end development

See front end development