all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: "Léo Le Bouter via Guix-patches via" <guix-patches@gnu.org>
To: 47081@debbugs.gnu.org
Cc: "Léo Le Bouter" <lle-bout@zaclys.net>
Subject: [bug#47081] [PATCH v2 5/6] services: Remove mongodb service.
Date: Fri, 12 Mar 2021 01:59:14 +0100	[thread overview]
Message-ID: <20210312005915.14100-5-lle-bout@zaclys.net> (raw)
In-Reply-To: <20210312005915.14100-1-lle-bout@zaclys.net>

* gnu/services/databases.scm (mongodb-configuration, mongodb-configuration?,
mongodb-configuration-mongodb, mongodb-configuration-config-file,
mongodb-configuration-data-directory, mongodb-service-type,
%default-mongodb-configuration-file, %mongodb-accounts, mongodb-activation,
mongodb-shepherd-service): Remove.
---
 gnu/services/databases.scm | 88 --------------------------------------
 1 file changed, 88 deletions(-)

diff --git a/gnu/services/databases.scm b/gnu/services/databases.scm
index 979f3dd6c8..a841e7a50e 100644
--- a/gnu/services/databases.scm
+++ b/gnu/services/databases.scm
@@ -79,13 +79,6 @@
             memcached-configuration-udp-port
             memcached-configuration-additional-options
 
-            mongodb-configuration
-            mongodb-configuration?
-            mongodb-configuration-mongodb
-            mongodb-configuration-config-file
-            mongodb-configuration-data-directory
-            mongodb-service-type
-
             mysql-service
             mysql-service-type
             mysql-configuration
@@ -521,87 +514,6 @@ created after the PostgreSQL database is started.")))
                                           (const %memcached-accounts))))
                 (default-value (memcached-configuration))))
 
-\f
-;;;
-;;; MongoDB
-;;;
-
-(define %default-mongodb-configuration-file
-  (plain-file
-   "mongodb.yaml"
-   "# GNU Guix: MongoDB default configuration file
-processManagement:
-  pidFilePath: /var/run/mongodb/pid
-storage:
-  dbPath: /var/lib/mongodb
-"))
-
-
-(define-record-type* <mongodb-configuration>
-  mongodb-configuration make-mongodb-configuration
-  mongodb-configuration?
-  (mongodb             mongodb-configuration-mongodb
-                       (default mongodb))
-  (config-file         mongodb-configuration-config-file
-                       (default %default-mongodb-configuration-file))
-  (data-directory      mongodb-configuration-data-directory
-                       (default "/var/lib/mongodb")))
-
-(define %mongodb-accounts
-  (list (user-group (name "mongodb") (system? #t))
-        (user-account
-         (name "mongodb")
-         (group "mongodb")
-         (system? #t)
-         (comment "Mongodb server user")
-         (home-directory "/var/lib/mongodb")
-         (shell (file-append shadow "/sbin/nologin")))))
-
-(define mongodb-activation
-  (match-lambda
-    (($ <mongodb-configuration> mongodb config-file data-directory)
-     #~(begin
-         (use-modules (guix build utils))
-         (let ((user (getpwnam "mongodb")))
-           (for-each
-            (lambda (directory)
-              (mkdir-p directory)
-              (chown directory
-                     (passwd:uid user) (passwd:gid user)))
-            '("/var/run/mongodb" #$data-directory)))))))
-
-(define mongodb-shepherd-service
-  (match-lambda
-    (($ <mongodb-configuration> mongodb config-file data-directory)
-     (shepherd-service
-      (provision '(mongodb))
-      (documentation "Run the Mongodb daemon.")
-      (requirement '(user-processes loopback))
-      (start #~(make-forkexec-constructor
-                `(,(string-append #$mongodb "/bin/mongod")
-                  "--config"
-                  ,#$config-file)
-                #:user "mongodb"
-                #:group "mongodb"
-                #:pid-file "/var/run/mongodb/pid"
-                #:log-file "/var/log/mongodb.log"))
-      (stop #~(make-kill-destructor))))))
-
-(define mongodb-service-type
-  (service-type
-   (name 'mongodb)
-   (description "Run the MongoDB document database server.")
-   (extensions
-    (list (service-extension shepherd-root-service-type
-                             (compose list
-                                      mongodb-shepherd-service))
-          (service-extension activation-service-type
-                             mongodb-activation)
-          (service-extension account-service-type
-                             (const %mongodb-accounts))))
-   (default-value
-     (mongodb-configuration))))
-
 \f
 ;;;
 ;;; MySQL.
-- 
2.30.2





  parent reply	other threads:[~2021-03-12  1:00 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-12  0:56 [bug#47081] [PATCH 0/5] gnu: Remove mongodb Léo Le Bouter via Guix-patches via
2021-03-12  0:57 ` [bug#47081] [PATCH 1/5] gnu: Remove mongo-tools Léo Le Bouter via Guix-patches via
2021-03-12  0:57   ` [bug#47081] [PATCH 2/5] doc: Remove mongodb-service-type Léo Le Bouter via Guix-patches via
2021-03-12  0:57   ` [bug#47081] [PATCH 3/5] tests: databases: Remove mongodb test Léo Le Bouter via Guix-patches via
2021-03-12  0:57   ` [bug#47081] [PATCH 4/5] services: Remove mongodb service Léo Le Bouter via Guix-patches via
2021-03-12  0:57   ` [bug#47081] [PATCH 5/5] gnu: Remove mongodb Léo Le Bouter via Guix-patches via
2021-03-12  0:59 ` [bug#47081] [PATCH v2 1/6] gnu: Remove go-gopkg.in-mgo.v2 Léo Le Bouter via Guix-patches via
2021-03-12  0:59   ` [bug#47081] [PATCH v2 2/6] gnu: Remove mongo-tools Léo Le Bouter via Guix-patches via
2021-03-12  0:59   ` [bug#47081] [PATCH v2 3/6] doc: Remove mongodb-service-type Léo Le Bouter via Guix-patches via
2021-03-12  0:59   ` [bug#47081] [PATCH v2 4/6] tests: databases: Remove mongodb test Léo Le Bouter via Guix-patches via
2021-03-12  0:59   ` Léo Le Bouter via Guix-patches via [this message]
2021-03-14 14:54     ` [bug#47081] [PATCH v2 5/6] services: Remove mongodb service Christopher Baines
2021-03-14 14:58       ` Léo Le Bouter via Guix-patches via
2021-03-14 15:31         ` Christopher Baines
2021-03-16 10:11           ` bug#47081: " Léo Le Bouter via Guix-patches via
2021-03-12  0:59   ` [bug#47081] [PATCH v2 6/6] gnu: Remove mongodb Léo Le Bouter via Guix-patches via
2021-03-17 16:56 ` Why [bug#47081] Remove mongodb? zimoun
2021-03-17 17:09   ` Léo Le Bouter
2021-03-17 17:56     ` zimoun
2021-03-17 18:16       ` Léo Le Bouter
2021-03-17 18:51         ` zimoun
2021-03-17 19:05           ` Léo Le Bouter
2021-03-17 19:11           ` Léo Le Bouter
2021-03-17 21:24             ` zimoun
2021-03-20 11:37     ` Ludovic Courtès
2021-03-21 22:15       ` Léo Le Bouter
2021-03-22  9:55         ` Efraim Flashner
2021-03-22 16:14         ` Ludovic Courtès
2021-03-22 16:45           ` Jack Hill
2021-03-17 17:20   ` Léo Le Bouter

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210312005915.14100-5-lle-bout@zaclys.net \
    --to=guix-patches@gnu.org \
    --cc=47081@debbugs.gnu.org \
    --cc=lle-bout@zaclys.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.