CI/CD for Tyk Policies


How I can store policies and other artifacts for Tyk into a source control repository like Git and how these can be deployed/promoted to different environments like DEV, TEST and PROD.


Hi guaravve,

Yes, since all these artefacts are files you can do this with CE. With Pro / Dash you need to use the API to import and export them.
Otherwise you could wait for v2.3 where you can use our new Import / Export API :smiley:


Kos @ Tyk Support Team

Hi Kos,
I am eagerly waiting for 2.3 in that case. Any release dates yet?

Have a few more questions:

  1. I am using pro on a trial licence. Can you point me to some document which shows me how to export from command line?
  2. I was wondering where the files are stored on the filesystem and if those can be checked into git and deployed directly to target nodes? If yes, do we need to restart the gateway for that?
  3. When running a tyk cluster do I need to import APIs on every node?


Hi Gaurav,

1.Currently is hard to export from CLI and there is no documentation for it.
2. Mongo manages data in its own way, so I suggest to use a Mongo client and explore the Tyk database. Some free tools you could possibly use is Robomongo which is desktop-based client, Humongous which is web-based client.
3.You don’t need to do it manually, as long as your cluster uses the same Redis/Mongo settings it will be fine.

v2.3 will be out soon!

Kos @ Tyk Support Team

Can you tell me where the files are located?

Hi Gauravve,

our product has different methods of handling the data depending on the edition.
Community Edition is file-based, it has policies and apps directories whereas in Pro edition (your case) Mongo is holding the information.

Kos @ Tyk Support Team

1 Like