🏡 index : github.com/captn3m0/nebula.git

author Nemo <me@captnemo.in> 2019-04-16 0:38:40.0 +05:30:00
committer Nemo <me@captnemo.in> 2019-04-16 0:38:40.0 +05:30:00
commit
071a16dc9413c3974d29158d9b896e4c18880f2b [patch]
tree
a90c669a7dc5f39841343a66c8bccb05b15b4f2b
parent
d9ef272286c391ba308c97e38de2f23ab945b1c1
download
071a16dc9413c3974d29158d9b896e4c18880f2b.tar.gz

Improve NextCloud Networking



Diff

 miniflux.tf  |  2 +-
 nextcloud.tf | 36 +++++++++++++++++++++++++++---------
 2 files changed, 27 insertions(+), 11 deletions(-)

diff --git a/miniflux.tf b/miniflux.tf
index f95edee..beae524 100644
--- a/miniflux.tf
+++ a/miniflux.tf
@@ -1,7 +1,7 @@
module "miniflux-container" {

  name   = "miniflux"
  source = "modules/container"
  image  = "miniflux/miniflux:2.0.14"
  image  = "miniflux/miniflux:2.0.15"

  web {

    expose = true
diff --git a/nextcloud.tf b/nextcloud.tf
index 75381a8..f31442f 100644
--- a/nextcloud.tf
+++ a/nextcloud.tf
@@ -7,7 +7,7 @@
module "nextcloud-container" {

  source = "modules/container"
  name   = "nextcloud"
  image  = "nextcloud:15-apache"
  image  = "nextcloud:16-rc-apache"

  volumes = [{

    container_path = "/var/www/html"
@@ -35,18 +35,34 @@
    host   = "c.${var.root-domain}"
  }

  # module.docker.traefik-network-id,
  networks = "${list(

    data.docker_network.bridge.id,
    module.db.postgres-network-id
  )}"
  networks_advanced = [

    {
      name = "traefik"
    },
    {
      name = "nextcloud"
    },
    {
      name = "postgres"
    },
  ]
}

resource "docker_network" "nextcloud" {

  name     = "nextcloud"
  internal = true
}

module "nextcloud-redis" {

  name     = "nextcloud-redis"
  source   = "modules/container"
  image    = "redis:alpine"
  networks = ["${data.docker_network.bridge.id}"]
  name   = "nextcloud-redis"
  source = "modules/container"
  image  = "redis:alpine"

  networks_advanced = [

    {
      name = "nextcloud"
    },
  ]

  # ThisSucks
  web {