Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
H
hypha
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ots
hypha
Commits
e3f31424
Commit
e3f31424
authored
7 years ago
by
Todd Dembrey
Browse files
Options
Downloads
Patches
Plain Diff
Update the settings to get the vagrant box to run correctly
parent
1b554ecb
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
README.md
+1
-1
1 addition, 1 deletion
README.md
Vagrantfile
+1
-1
1 addition, 1 deletion
Vagrantfile
vagrant/provision.sh
+3
-2
3 additions, 2 deletions
vagrant/provision.sh
with
5 additions
and
4 deletions
README.md
+
1
−
1
View file @
e3f31424
...
...
@@ -20,7 +20,7 @@ To set up a new build:
```
bash
git clone git@github.com:OpenTechFund/opentech.fund.git
cd
opentech
cd
opentech
.fund
vagrant up
vagrant ssh
```
...
...
This diff is collapsed.
Click to expand it.
Vagrantfile
+
1
−
1
View file @
e3f31424
...
...
@@ -78,7 +78,7 @@ Vagrant.configure(2) do |config|
# sudo apt-get update
# sudo apt-get install -y apache2
# SHELL
config
.
vm
.
provision
:shell
,
:path
=>
"vagrant/provision.sh"
,
:args
=>
"opentech"
config
.
vm
.
provision
:shell
,
:path
=>
"vagrant/provision.sh"
,
:args
=>
[
"opentech.fund"
,
"opentech"
]
# Enable agent forwarding over SSH connections.
config
.
ssh
.
forward_agent
=
true
...
...
This diff is collapsed.
Click to expand it.
vagrant/provision.sh
+
3
−
2
View file @
e3f31424
#!/bin/bash
PROJECT_NAME
=
$1
MODULE_NAME
=
$2
PROJECT_DIR
=
/vagrant
VIRTUALENV_DIR
=
/home/vagrant/.virtualenvs/
$PROJECT_NAME
...
...
@@ -10,8 +11,8 @@ PIP=$VIRTUALENV_DIR/bin/pip
# Create database
su - vagrant
-c
"createdb
$PROJECT_NAME
"
su - vagrant
-c
"createdb
$MODULE_NAME
"
# Virtualenv setup for project
su - vagrant
-c
"virtualenv --python=python3
$VIRTUALENV_DIR
"
...
...
@@ -40,7 +41,7 @@ chmod a+x $PROJECT_DIR/manage.py
# Add a couple of aliases to manage.py into .bashrc
cat
<<
EOF
>> /home/vagrant/.bashrc
export PYTHONPATH=
$PROJECT_DIR
export DJANGO_SETTINGS_MODULE=
$
PROJECT
_NAME
.settings.dev
export DJANGO_SETTINGS_MODULE=
$
MODULE
_NAME
.settings.dev
alias dj="django-admin.py"
alias djrun="dj runserver 0.0.0.0:8000"
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment