Note: you can check the Quickstart guide for list of commands that can quickly get you going.
git clone git@github.com:3scale/zync.git
To run Zync you need access to a running PostgreSQL server. You can install one with your operating system package manager, as a container or run it remotely.
The minimum requirement for the machine running Zync is to have
- Ruby 3.1
psql
client tool - needed when running fordb:setup
libpq-devel
- needed to buildpg
gem duringbundle install
.
You may have to adjust config/database.yml
or DATABASE_URL
environment variable, see below.
There is a setup
script to install gem dependencies,
seed the database and run Zync server.
./bin/setup
Make sure to edit configuration or set needed environment variables beforehand. Most important environment variables you can use:
ZYNC_AUTHENTICATION_TOKEN
- this one must match your running Porta configurationDATABASE_URL
- depending on your PostgreSQL anddatabase.yml
configuration, you may want to set this onePROMETHEUS_EXPORTER_PORT
- in case you are running other 3scale components likeque
and Porta, you may need to set a different port for each of them through this variable to avoid conflict between themPORT
- change port where Zync is running (e.g.5000
) to avoid conflict with a locally running Porta server or other software, you can also use the-p 5000
command line option
When starting Zync, make sure to use a non-conflicting port on your machine
bundle exec rails server -p 5000
When starting que, make sure to set a non-conflicting Prometheus port
PROMETHEUS_EXPORTER_PORT=9395 bundle exec rake que