Skip to content

Commit 01c6ff3

Browse files
committed
various updates
1 parent 76f790f commit 01c6ff3

File tree

3 files changed

+38
-1
lines changed

3 files changed

+38
-1
lines changed

contributing/quickstart.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ Now the website will run locally. You have some options on how to set up the dat
1919
## (2) DATABASE SETUP
2020
There are two options here - a "test" database with generated data, or the production database (with sensitive information removed).
2121
1. **Test database**: Quick to set up, but may not mirror real-world data well. `docker exec -it rails bash -c "bin/rake db:reset"`
22-
2. **Exported database**: Takes 60-90 minutes to set up, but uses actual data from the live website. `docker exec -it rails bash -c "bin/rake db:load:development"`
22+
2. **Exported database**: Takes 60-90 minutes to set up, but uses actual data from the live website. `docker exec -it rails bash -c "bin/rake db:load:development[reload]"`
2323

2424
## (3) RUNNING TESTS
2525
Two options - running while your docker server is running, or running tests independently.

wst-processes/common_requests.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,3 +34,9 @@ AWS will send an email with the title "Action Required - Your certificate renewa
3434
3. Click on the certificate with the relevant name in the "Domain name" column
3535
4. Click "Create records in Route 53"
3636
5. Confirm with "Create records"
37+
38+
# Resetting a Password
39+
40+
We never reset a password on someone's behalf - they should use the built-in password change feature.
41+
42+
# Transferring an Account

wst-processes/internal_processes.md

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,3 +120,34 @@ For example, `3.2.1` --> `4.0.0` (first digit)
120120
You should skim the changelog for any breaking changes that could be relevant.
121121
If it's a crucial part of our infrastructure (see above), get a second pair of eyes to review.
122122

123+
# Removing Duplicate Motions
124+
125+
Motions are stored in an S3 bucket:
126+
127+
Currently, motions are not deleted when a new set is deployed. We have to delete them manually, and clear the cache key.
128+
1. Delete the old file
129+
1. Navigate to: https://us-west-2.console.aws.amazon.com/s3/buckets/wca-documents?region=us-west-2&bucketType=general&prefix=documents%2Fmotions%2F&showversions=false&tab=objects
130+
1. Select the file and select delete
131+
1. Confirm that you are targeting the correct file, and enter "permanently delete"
132+
1. Clear the cache
133+
1. Connect to the production instance
134+
1. Enter the rails console with `bin/rails console`
135+
1. Find the cache key for the documents list with the following code:
136+
```ruby
137+
Rails.cache.redis.with do |redis|
138+
cursor = "0"
139+
keys = []
140+
loop do
141+
cursor, batch = redis.scan(cursor)
142+
keys.concat(batch.select { |key| key.include?("documents") })
143+
break if cursor == "0"
144+
end
145+
keys
146+
end
147+
```
148+
1. Optionally, run `rails.cache.read(cache_key_from_previous_command)` to confirm you are targeting the correct key
149+
1. Run `rails.cache.delete(cache_key_from_previous_command)`
150+
151+
## How are motions deployed?
152+
153+

0 commit comments

Comments
 (0)