https://github.com/itsdouges/armory-services
🛡 Guild Wars 2 Armory Services | api.gw2armory.com
https://github.com/itsdouges/armory-services
armory docker guild guildwars2 javascript nodejs
Last synced: 3 months ago
JSON representation
🛡 Guild Wars 2 Armory Services | api.gw2armory.com
- Host: GitHub
- URL: https://github.com/itsdouges/armory-services
- Owner: itsdouges
- License: bsd-3-clause-clear
- Archived: true
- Created: 2015-08-08T00:40:41.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2018-11-10T04:30:45.000Z (about 7 years ago)
- Last Synced: 2024-10-02T08:43:31.007Z (over 1 year ago)
- Topics: armory, docker, guild, guildwars2, javascript, nodejs
- Language: JavaScript
- Homepage: https://api.gw2armory.com
- Size: 1.14 MB
- Stars: 9
- Watchers: 3
- Forks: 5
- Open Issues: 21
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- License: LICENSE
Awesome Lists containing this project
README
# api.gw2armory.com
[](https://travis-ci.org/madou/armory-services) [](https://david-dm.org/madou/armory-services)
[](https://david-dm.org/madou/armory-services?type=dev)
[](https://codecov.io/gh/madou/armory-services)
[](https://discord.gg/3BRbV7b)
[](https://www.patreon.com/bePatron?u=5546924)
## Usage
### Quick start
tl;dr -> develop with `npm run tdd` and `npm run tdd:int`, use `npm run dev` to run local environment.
### User image uploads
To have image uploads working locally you'll need a valid aws key/secret pair. Run it like so:
```bash
IMAGE_UPLOAD_ACCESS_KEY_ID=ACCESSKEYHERE IMAGE_UPLOAD_SECRET_ACCESS_KEY=SECRETKEYHERE npm run dev
```
### Email notifications
To have email notification working locally you'll need a valid aws key/secret pair. Run it like so:
```bash
SES_ACCESS_KEY_ID=ACCESSKEYHERE SES_SECRET_ACCESS_KEY=SECRETKEYHERE npm run dev
```
### Database migrations
Ensure any database migration is backwards compatible with a previous version of the api. This will keep deployments simple and clean.
```bash
ENV={ENV} npm run migrate
```
#### Migration test runs
##### Prepare step
Starts a database container and exposes it to 127.0.0.1:3306
```bash
npm run mtr-prepare
```
##### Run step
Runs the migration against the test database. Make sure to have your migrations written in `src/migration/scripts`, with the db models in their origin (pre-migrated) state in `src/lib/models`.
```bash
npm run mtr
```
##### Revert step
Run after running test migration to roll back changes.
```bash
npm run mtr-revert
```
## Deployments
Deployments to production are triggered by tagged commits, tag with `npm version major|minor|patch`. Deployments to test are done adhoc and are _almost_ manual.
## Pull Requests
Like to contribute? Look at the [issues](https://github.com/madou/armory-services/issues) tab or contact me on [reddit](https://www.reddit.com/r/gw2armory) or [twitter](https://twitter.com/itsmadou) to find something you'd like to work on, then make a pull request against the `master` branch.
© 2015-present gw2armory.com