Skip to content

Commit

Permalink
Post-frontend rewrite fixes (#419)
Browse files Browse the repository at this point in the history
  • Loading branch information
florimondmanca authored Jan 26, 2024
1 parent 2af881c commit ed5a16f
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 63 deletions.
40 changes: 0 additions & 40 deletions .github/workflows/deploy.yml

This file was deleted.

10 changes: 5 additions & 5 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -80,10 +80,10 @@ database-migrate: ## Database migrations
npm run migration:migrate

database-test-init: up ## Initialize test database
make compose CMD="exec -T database dropdb --if-exists permacoop_hotwire_test"
make compose CMD="exec -T database createdb permacoop_hotwire_test"
make database-migrate DATABASE_NAME=permacoop_hotwire_test
make database-seed DATABASE_NAME=permacoop_hotwire_test
make compose CMD="exec -T database dropdb --if-exists permacoop_test"
make compose CMD="exec -T database createdb permacoop_test"
make database-migrate DATABASE_NAME=permacoop_test
make database-seed DATABASE_NAME=permacoop_test

database-migration: ## Generate a database migration
npm run migration:generate -- migrations/$(NAME)
Expand All @@ -98,7 +98,7 @@ ci: up ## Run CI checks
make install
make linter
make test-cov
make test-e2e CI=1 DATABASE_NAME=permacoop_hotwire
make test-e2e CI=1 DATABASE_NAME=permacoop

scalingo-postbuild:
make build
Expand Down
23 changes: 5 additions & 18 deletions docs/deployment.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,26 +23,23 @@ WWW ------- app (:$PORT) |

## How to deploy

Push to the branch `feat-hotwire`.
Push to the branch `master`.

## Environnements

Environments are copies of the Permacoop infrastructure. Currently the deployed environments are:

| Name | Description | URL | Deploy branch |
|------|-------------|-----|---------------|
| prod-scaleway | Legacy production environment | https://permacoop.fairness.coop | main |
| prod-scalingo | Rewrite production environment | https://permacoop.osc-fr1.scalingo.io/ | feat-hotwire |
| prod-scalingo | Production environment | https://permacoop.fairness.coop (CNAME to https://permacoop.osc-fr1.scalingo.io) | master |

Each environment makes use of several computing resources, listed below:

| Ressource | Environment | Location |
|---------------------|-------------|------------|
| VM | prod-scaleway | Scaleway |
| PostgreSQL instance | prod-scaleway | Scaleway |
| App | prod-scalingo | Scalingo |
| PostgreSQL instance | prod-scalingo | Scaleway |
| DNS records | * | Infomaniak |
| App | prod-scalingo | Scalingo |
| PostgreSQL instance | prod-scalingo | Scalingo |
| DNS records | * | Gandi |

## Configuration

Expand All @@ -63,13 +60,3 @@ If an environment is not used anymore, it should be decommissioned to remove unu
* Open, review and merge a PR with the following changes:
* Drop the environment from the environment list in this file.
* Drop the [computing resources](#computing-resources) allocated to the environment.

## Migration Scaleway

Voir https://doc.scalingo.com/databases/postgresql/dump-restore#restore

Déployer une copie de la DB Scaleway :

* Dans la Console Scaleway, récupérer un export de la DB (fichier `.custom`, par exemple `export.custom`)
* Récupérer la `DATABASE_URL` sur Scalingo
* Lancer `$ pg_restore --clean --if-exists --no-owner --no-privileges --no-comments --dbname $DATABASE_URL -v -Fc export.custom`

0 comments on commit ed5a16f

Please sign in to comment.