|
| 1 | +By default when dependent services such as MongoDB, RabbitMQ and PostgreSQL are installed, they |
| 2 | +have authentication disabled or use a default static password. As such, after you install those |
| 3 | +services you should configure them and enable authentication with strong randomly generated |
| 4 | +passwords. |
| 5 | + |
| 6 | +Configuring authorization and passwords for those services is out of the scope for this documentation. |
| 7 | +For more information refer to the links below: |
| 8 | + |
| 9 | +* MongoDB - https://docs.mongodb.com/manual/tutorial/enable-authentication/, https://docs.mongodb.com/manual/core/authorization/ |
| 10 | +* RabbitMQ - https://www.rabbitmq.com/authentication.html |
| 11 | +* PostgreSQL - https://www.postgresql.org/docs/9.4/static/auth-methods.html |
| 12 | + |
| 13 | +After you enable authentication for those components, you will also need to configure StackStorm |
| 14 | +services so they can talk to them. |
| 15 | + |
| 16 | +This means editing the following configuration options: |
| 17 | + |
| 18 | +1. StackStorm config - ``/etc/st2/st2.conf`` |
| 19 | + |
| 20 | + * ``database.username`` - MongoDB database username. |
| 21 | + * ``database.password`` - MongoDB database password. |
| 22 | + * ``messaging.url`` - RabbitMQ transport url (``amqp://<username>:<password>@<hostname>:5672``) |
| 23 | + |
| 24 | +2. Mistral config - ``/etc/mistral/mistral.conf`` |
| 25 | + |
| 26 | + * ``database.connection`` - PostgreSQL database connection string (``postgresql://<username>:<password>@<hostname>/mistral``) |
| 27 | + * ``transport_url`` - RabbitMQ transport url (``rabbit://<username>:<password>@<hostname>:5672``) |
| 28 | + |
| 29 | +In addition, you are strongly encouraged to follow these best practices for running network |
| 30 | +services: |
| 31 | + |
| 32 | +* Ensure communication between services is encrypted. Enable SSL / TLS for all the services - |
| 33 | + MongoDB, RabbitMQ, PostgreSQL. |
| 34 | +* Configure services to only listen on localhost, and where needed, internal IP addresses. There |
| 35 | + is usually no need for most services which are used by |st2| (MongoDB, RabbitMQ, PostgreSQL) to |
| 36 | + be available to the public and listen on an external (public) IP address. |
| 37 | +* Configure a firewall and set up a whitelist. You should set up a firewall and only allow services |
| 38 | + and users which need access to the services to be able to access them. API and auth service |
| 39 | + usually need to be accessible to your users, but other dependent services such as MongoDB, |
| 40 | + RabbitMQ and PostgreSQL aren't. These should not be directly accessible by users, and only |
| 41 | + StackStorm components should be allowed to talk to them. |
| 42 | +* Where possible and available, you should also utilize additional network-based isolation and |
| 43 | + security features such as DMZs. |
| 44 | + |
| 45 | +The steps mentioned above are especially important for distributed production deployments where |st2| |
| 46 | +components are running on multiple servers. |
0 commit comments