mirror of
https://github.com/scratchfoundation/scratch-www.git
synced 2024-11-26 17:16:11 -05:00
Purge all after configuring Fastly
This commit is contained in:
parent
dd1c2c1627
commit
fce7c0cd9b
2 changed files with 12 additions and 7 deletions
15
README.md
15
README.md
|
@ -70,13 +70,14 @@ pip install -r requirements.txt
|
||||||
make deploy
|
make deploy
|
||||||
```
|
```
|
||||||
|
|
||||||
| Variable | Default | Description |
|
| Variable | Default | Description |
|
||||||
| ----------------------- | ------- | ----------------------------------------------- |
|
| ------------------------ | ------- | ------------------------------------------------ |
|
||||||
| `FASTLY_SERVICE_ID` | `''` | Fastly service ID for `bin/configure-fastly.js` |
|
| `FASTLY_SERVICE_ID` | `''` | Fastly service ID for `bin/configure-fastly.js` |
|
||||||
| `FASTLY_API_KEY` | `''` | Fastly API key for `bin/configure-fastly.js` |
|
| `FASTLY_API_KEY` | `''` | Fastly API key for `bin/configure-fastly.js` |
|
||||||
| `AWS_ACCESS_KEY_ID` | `''` | AWS access key id for S3 |
|
| `FASTLY_ACTIVATE_CHANGES`| `false` | Activate changes and purge all after configuring |
|
||||||
| `AWS_SECRET_ACCESS_KEY` | `''` | AWS secret access key for S3 |
|
| `AWS_ACCESS_KEY_ID` | `''` | AWS access key id for S3 |
|
||||||
| `S3_BUCKET_NAME` | `''` | S3 bucket name to deploy into |
|
| `AWS_SECRET_ACCESS_KEY` | `''` | AWS secret access key for S3 |
|
||||||
|
| `S3_BUCKET_NAME` | `''` | S3 bucket name to deploy into |
|
||||||
|
|
||||||
|
|
||||||
### Current issues with the development
|
### Current issues with the development
|
||||||
|
|
|
@ -255,6 +255,10 @@ async.auto({
|
||||||
fastly.activateVersion(results.version, function (err, response) {
|
fastly.activateVersion(results.version, function (err, response) {
|
||||||
if (err) throw new Error(err);
|
if (err) throw new Error(err);
|
||||||
process.stdout.write('Successfully configured and activated version ' + response.number + '\n');
|
process.stdout.write('Successfully configured and activated version ' + response.number + '\n');
|
||||||
|
fastly.purgeAll(FASTLY_SERVICE_ID, function (err) {
|
||||||
|
if (err) throw new Error(err);
|
||||||
|
process.stdout.write('Purged all.\n');
|
||||||
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue