Commit Graph

24 Commits

Author SHA1 Message Date
6f18eed04e Change the public key of HashiCorp apt key. 2023-01-28 10:34:54 +09:00
bc2f8128ff apt updateコマンドの実行回数を減らす 2022-08-11 12:21:39 +09:00
4a57c21614 Deploy example Consul Connect job. 2022-03-14 23:19:25 +09:00
ef40d3dc01 Create /etc/nomad.d/jobs 2022-03-14 23:19:25 +09:00
9a5a78d657 Deploy /etc/nomad.d/policies/anonymous.hcl. 2022-03-14 23:19:25 +09:00
ce7a80db7a Create /etc/nomad.d/policies/ directory. 2022-03-14 23:17:44 +09:00
a882f52b3f Delete shared_dir.rb. 2022-03-14 23:17:32 +09:00
64066ab78f Add consul stanza. 2022-03-14 23:17:12 +09:00
2bec4d88f3 Do not deploy docker-registry.hcl. 2022-01-14 23:52:59 +09:00
8c712e6ffa Delete /etc/nomad.d/datadir.hcl. 2022-01-14 23:52:59 +09:00
5e176ff230 Modify /etc/nomad.d/client.hcl:
```
--- a/cookbooks/nomad/files/etc/nomad.d/client.hcl
+++ b/cookbooks/nomad/files/etc/nomad.d/client.hcl
@@ -1,13 +1,3 @@
-# /etc/nomad.d/server.hcl
-
 client {
-  enabled          = true
-}
-
-plugin "docker" {
-  config {
-    volumes {
-      enabled = true
-    }
-  }
+  enabled        = true
 }
```
2022-01-14 23:52:58 +09:00
935f773bca Deploy csi settings. 2022-01-14 23:52:58 +09:00
de06f5575c Add logrotated config for nomad log files.
```
--- /dev/null
+++ b/cookbooks/nomad/files/etc/logrotate.d/nomad
@@ -0,0 +1,13 @@
+/var/log/nomad.log
+{
+        rotate 4
+        weekly
+        missingok
+        notifempty
+        compress
+        delaycompress
+        sharedscripts
+        postrotate
+                /usr/lib/rsyslog/rsyslog-rotate
+        endscript
+}
```
2022-01-10 15:29:00 +09:00
dffb57e2fc Add rsyslog config for nomad. 2022-01-10 15:29:00 +09:00
9e6b05fbab Specify Loki endpoint.
```
--- a/cookbooks/nomad/attributes.rb
+++ b/cookbooks/nomad/attributes.rb
@@ -4,6 +4,7 @@
 node.reverse_merge!({
   'nomad' => {
     'manager' => false,
-    'client' => false
+    'client' => false,
+    'lokiendpoint' => 'loki.service.consul:3100'
   }
 })
```
2022-01-10 15:29:00 +09:00
d824d6afc8 Add systemd config for Promtail monitoring nomad. 2022-01-10 15:29:00 +09:00
a7363ef7b1 Add Promtail setting for nomad. 2022-01-10 15:29:00 +09:00
96ba6e7757 Modify # of nomad servers:
```
--- a/cookbooks/nomad/files/etc/nomad.d/server.hcl
+++ b/cookbooks/nomad/files/etc/nomad.d/server.hcl
@@ -1,4 +1,4 @@
 server {
   enabled          = true
-  bootstrap_expect = 1
+  bootstrap_expect = 3
 }
```
2021-11-03 12:39:44 +09:00
9eddfaf514 Execute modprobe for the necessary kernel parameer. 2021-11-03 12:36:33 +09:00
cb368a1445 Deploy /etc/nomad.d/acl.hcl. 2021-06-19 19:56:45 +09:00
531dde8bff Deploy /etc/nomad.d/server.hcl. 2021-06-19 19:56:45 +09:00
bd4f65dcf5 Change the default config to install nomad only. 2021-06-19 19:56:45 +09:00
d5060f84f4 Install nomad even if the node is not nomad server/client. 2021-06-19 19:55:17 +09:00
010a53a58b Deploy nomad. 2021-05-02 19:08:17 +09:00