-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into FF-331_lab_acl
- Loading branch information
Showing
76 changed files
with
36,328 additions
and
1,036 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
TODO: document beanstalk deployment | ||
|
||
|
||
|
||
## Dropping database | ||
|
||
For test environment the database is not dropped for each deploy. This means that new upserts, | ||
which change existing data will in most cases not execute succesfully on the test environment. | ||
|
||
When that happens we need to drop the database and recreate it, so the inserts can be run. | ||
|
||
Easiest way to do that is to ssh into the beanstalk instance and do the follow: | ||
|
||
** Note ** to ssh in first `pip install awsebcli` then follow the setup instructions. With that installed you can simply type eb ssh (ensuring that the master branch is checked out). | ||
|
||
Once conneted do the following: | ||
|
||
```bash | ||
source /opt/python/current/env | ||
sudo services httpd stop | ||
echo $RDS_PASSWORD | ||
|
||
dropdb -p $RDS_PORT -h $RDS_HOSTNAME -U $RDS_USERNAME -e $RDS_DB_NAME | ||
|
||
createdb -p $RDS_PORT -h $RDS_HOSTNAME -U $RDS_USERNAME -e $RDS_DB_NAME | ||
|
||
sudo shutdown -r now | ||
``` | ||
|
||
** Note ** this will temporarily bring the site down, for a couple of minutes | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
TODO: document beanstalk deployment | ||
## Dropping database | ||
|
||
For test environment the database is not dropped for each deploy. This means that new upserts, | ||
which change existing data will in most cases not execute succesfully on the test environment. | ||
|
||
When that happens we need to drop the database and recreate it, so the inserts can be run. | ||
|
||
Easiest way to do that is to ssh into the beanstalk instance and do the follow: | ||
|
||
** Note ** to ssh in first `pip install awsebcli` then follow the setup instructions. With that installed you can simply type eb ssh (ensuring that the master branch is checked out). | ||
|
||
Once conneted do the following: | ||
|
||
```bash | ||
source /opt/python/current/env | ||
sudo services httpd stop | ||
echo $RDS_PASSWORD | ||
|
||
>>>>>>> e657b55... forcing build | ||
dropdb -p $RDS_PORT -h $RDS_HOSTNAME -U $RDS_USERNAME -e $RDS_DB_NAME | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
TODO: document beanstalk deployment | ||
|
||
|
||
## Dropping database | ||
|
||
For test environment the database is not dropped for each deploy. This means that new upserts, | ||
which change existing data will in most cases not execute succesfully on the test environment. | ||
|
||
When that happens we need to drop the database and recreate it, so the inserts can be run. | ||
|
||
Easiest way to do that is to ssh into the beanstalk instance and do the follow: | ||
|
||
** Note ** to ssh in first `pip install awsebcli` then follow the setup instructions. With that installed you can simply type eb ssh (ensuring that the master branch is checked out). | ||
|
||
Once conneted do the following: | ||
|
||
```bash | ||
source /opt/python/current/env | ||
sudo services httpd stop | ||
echo $RDS_PASSWORD | ||
|
||
dropdb -p $RDS_PORT -h $RDS_HOSTNAME -U $RDS_USERNAME -e $RDS_DB_NAME | ||
|
||
createdb -p $RDS_PORT -h $RDS_HOSTNAME -U $RDS_USERNAME -e $RDS_DB_NAME | ||
|
||
sudo shutdown -r now | ||
``` | ||
|
||
** Note ** this will temporarily bring the site down, for a couple of minutes | ||
|
||
|
Oops, something went wrong.