staff-api

Version, currently 1.02 versions

github.com/PlaceOS/staff-api

PlaceOS workplace management API.

0 stars
0 dependents
License: NOASSERTION

Nothing has been indexed for 1.0 yet. The tag is recorded, its shard.yml has not been read, so the manifest and dependency list below are empty because they are unknown rather than because they are absent.

Installation

# Add this to your shard.yml
dependencies:
  staff-api:
    github: PlaceOS/staff-api
    version: ~> 1.0

Then run:

shards install

shard.yml

No shard.yml has been indexed for 1.0. You can read it on the repository.

Dependencies

Unknown: the shard.yml for this version has not been read yet.

README

This README is the one indexed from the repository at its latest ref, not from the tag for this version.

PlaceOS Staff API

Build Dev Image CI

Service for integrating PlaceOS with the workplace.

Environment

These environment variables are required for configuring an instance of Staff API

SG_ENV=production  # When set to production, the auth token in the request header will be used for auth, instead of static credentials from environment variables

# Database config:
PG_DATABASE_URL=postgresql://user:password@hostname/placeos

# Size of the connection pool
PG_CONNECTION_POOL_SIZE=5

# Public key for decrypting and validating JWT tokens
JWT_PUBLIC=base64-public-key  #same one used by PlaceOS rest-api

# Location of PlaceOS API
PLACE_URI=https://example.place.technology

Optional

# Default Timezone
STAFF_TIME_ZONE=Australia/Sydney #default to UTC if not provided

SSL_VERIFY_NONE=true # Whether staff-api should verify the SSL cert that PlaceOS rest-api presents

# Sentry monitoring
SENTRY_DSN=<sentry dsn>

# Logstash log ingest
LOGSTASH_HOST=example.com
LOGSTASH_PORT=12345

# Sentry monitoring
SENTRY_DSN=<sentry dsn>

# Logstash log ingest
LOGSTASH_HOST=example.com
LOGSTASH_PORT=12345

Development

The test script spins up a configured development environment, and can be used like so...

./test

or, to run specs as you make changes...

./test --watch

Note: pass the -Dquiet flag to silence the SQL loging