Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .envrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
use flake
32 changes: 0 additions & 32 deletions .github/workflows/main.yml

This file was deleted.

1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,3 @@ result

# Keep it secret, keep it safe.
.env
.envrc
23 changes: 15 additions & 8 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,23 @@ There are three more directories containing code for the registry.

Finally, the `flake.nix` file orchestrates builds for the whole repository.

## Running the Registry Server Locally

The registry server requires a `.env` file and an initialized database. To run the server for development:

```sh
# 1. Ensure database is initialized (only needed once)
dbmate up

# 2. Run the server (from the nix shell)
cd app && spago run
```

The server will load environment variables from the `.env` file in the project root and run on port 8080 by default.

## Available Nix Commands

The Registry server can be run locally:
You can also run the packaged registry server:

```sh
nix run .#server
Expand Down Expand Up @@ -81,13 +95,6 @@ There is an integration test that will deploy the registry server and make reque
nix build .#checks.x86_64-linux.integration
```

You can "deploy" the registry server to a local VM and manually hit the API as if it were the production server:

```sh
# The server will be available at localhost:8080
nix run
```

### Testing Guidelines

The PureScript code in the registry is well-tested, ranging from tests for individual functions to full end-to-end tests for the registry server running in a NixOS machine configured the same way as the deployed machine. The smaller and more pure the test, the easier it is to write and maintain; most code is tested via unit tests written with `spec`, and only the core pipelines are run in the integration test.
Expand Down
160 changes: 0 additions & 160 deletions app/default.nix

This file was deleted.

68 changes: 15 additions & 53 deletions flake.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading