1+ .. _readme :
2+
13mongodb
24=======
35
6+ |img_travis | |img_sr |
7+
8+ .. |img_travis | image :: https://travis-ci.com/saltstack-formulas/mongodb-formula.svg?branch=master
9+ :alt: Travis CI Build Status
10+ :scale: 100%
11+ :target: https://travis-ci.com/saltstack-formulas/mongodb-formula
12+ .. |img_sr | image :: https://img.shields.io/badge/%20%20%F0%9F%93%A6%F0%9F%9A%80-semantic--release-e10079.svg
13+ :alt: Semantic Release
14+ :scale: 100%
15+ :target: https://github.com/semantic-release/semantic-release
16+
417Install and configure MongoDB products on GNU/Linux and MacOS.
518
6- Meta states
7- ================
19+ .. contents :: **Table of Contents**
20+
21+ General notes
22+ -------------
23+
24+ See the full `SaltStack Formulas installation and usage instructions
25+ <https://docs.saltstack.com/en/latest/topics/development/conventions/formulas.html> `_.
26+
27+ If you are interested in writing or contributing to formulas, please pay attention to the `Writing Formula Section
28+ <https://docs.saltstack.com/en/latest/topics/development/conventions/formulas.html#writing-formulas> `_.
29+
30+ If you want to use this formula, please pay attention to the ``FORMULA `` file and/or ``git tag ``,
31+ which contains the currently released version. This formula is versioned according to `Semantic Versioning <http://semver.org/ >`_.
32+
33+ See `Formula Versioning Section <https://docs.saltstack.com/en/latest/topics/development/conventions/formulas.html#versioning >`_ for more details.
34+
35+ If you need (non-default) configuration, please pay attention to the ``pillar.example `` file and/or `Special notes `_ section.
36+
37+ Contributing to this repo
38+ -------------------------
39+
40+ **Commit message formatting is significant!! **
41+
42+ Please see `How to contribute <https://github.com/saltstack-formulas/.github/blob/master/CONTRIBUTING.rst >`_ for more details.
43+
44+ Special notes
45+ -------------
46+
47+ None
48+
49+ Available states
50+ ----------------
51+
52+ .. contents ::
53+ :local:
854
955``mongodb ``
10- -----------
56+ ^^^^^^^^^^^
1157
1258Metastate to deploy MongoDB products from packages and/or archive files.
1359
1460``mongodb.server ``
15- -------------------
61+ ^^^^^^^^^^^^^^^^^^
1662
1763Deploy and configure MongoDB "Community Server" and start 'mongos' and 'mongod' services.
1864
1965``mongodb.bic ``
20- -------------------
66+ ^^^^^^^^^^^^^^^
2167
2268Deploy and configure MongoDB "Connector for BI" and start 'mongosqld' service.
2369
2470``mongodb.compass ``
25- -------------------
71+ ^^^^^^^^^^^^^^^^^^^
2672
2773Deploy Compass, the GUI for MongoDB
2874
2975``mongodb.robo3t ``
30- -------------------
76+ ^^^^^^^^^^^^^^^^^^
3177
3278Deploy Robo 3T (formerly Robomongo), another GUI for MongoDB
3379
3480``mongodb.clean ``
35- -----------
81+ ^^^^^^^^^^^^^^^^^
3682
3783Metastate to uninstall MongoDB products
3884
3985Other states
40- ================
86+ ------------
4187
4288``mongodb.server.config ``
4389
@@ -53,35 +99,72 @@ Other states
5399
54100
55101Pillar Data
56- ===============
57- Use linux distribution repo::
102+ -----------
103+ Use Linux distribution repo::
58104
59105 mongodb:
60106 server:
61107 version: '4.0'
62108
63- Use official upstream repo::
109+ Use official upstream repo::
64110
65111 mongodb:
66112 server:
67- use_repo: True
113+ use_repo: true
68114 version: '4.0'
69115
70116Use official upstream archives::
71117
72118 mongodb:
73119 server:
74- use_archive: True
120+ use_archive: true
75121 version: '4.0.3'
76122 bic:
77123 version: 2.7.0
78124
79125Testing
80- ========
81- This formula works "out-of-the-box", or with pillars, on these operating systems.
126+ -------
127+
128+ Linux testing is done with ``kitchen-salt ``.
129+
130+ Requirements
131+ ^^^^^^^^^^^^
132+
133+ * Ruby
134+ * Docker
135+
136+ .. code-block :: bash
137+
138+ $ gem install bundler
139+ $ bundle install
140+ $ bin/kitchen test [platform]
141+
142+ Where ``[platform] `` is the platform name defined in ``kitchen.yml ``,
143+ e.g. ``debian-9-2019-2-py3 ``.
144+
145+ ``bin/kitchen converge ``
146+ ^^^^^^^^^^^^^^^^^^^^^^^^
147+
148+ Creates the docker instance and runs the ``mongodb `` main state, ready for testing.
149+
150+ ``bin/kitchen verify ``
151+ ^^^^^^^^^^^^^^^^^^^^^^
152+
153+ Runs the ``inspec `` tests on the actual instance.
154+
155+ ``bin/kitchen destroy ``
156+ ^^^^^^^^^^^^^^^^^^^^^^^
157+
158+ Removes the docker instance.
159+
160+ ``bin/kitchen test ``
161+ ^^^^^^^^^^^^^^^^^^^^
162+
163+ Runs all of the stages above in one go: i.e. ``destroy `` + ``converge `` + ``verify `` + ``destroy ``.
164+
165+ ``bin/kitchen login ``
166+ ^^^^^^^^^^^^^^^^^^^^^
82167
83- - Ubuntu 16.04
84- - Centos 7.5.1804 (firewall + selinux enforcing)
85- - MacOS/Darwin
168+ Gives you SSH access to the instance for manual testing.
86169
87170.. vim: fenc=utf-8 spell spl=en cc=100 tw=99 fo=want sts=2 sw=2 et
0 commit comments