diagrams icon indicating copy to clipboard operation
diagrams copied to clipboard

Alignement issue

Open YannBrrd opened this issue 2 years ago • 2 comments

Hi,

With the following code

from diagrams import Cluster, Diagram, Edge
from diagrams.aws.security import KMS
from diagrams.onprem.compute import Server
from diagrams.onprem.client import User, Users
from diagrams.onprem.network import Haproxy
from diagrams.generic.blank import Blank


graph_attributes = {

}

with Diagram("C1", graph_attr=graph_attributes) as diag:
    with Cluster("DC1"):
        kms_1 = KMS("KMS")
        users = Users("Users")
        security_proxy = Haproxy("HAPrx)")
        sec_ops = User("Secops")
        kms_1 << sec_ops

    with Cluster("DC2"):
        blank = Blank()
        pscpt = Server("Compute")
        kms_2 = KMS("KMS 2")
        kms_2 >> pscpt

        pscpt << Edge(label="https") << security_proxy << users
        kms_1 << Edge(color="firebrick", style="dashed", label="sync") << kms_2
        

is there a way my KMS get aligned ? c1

Thanks

YannBrrd avatar Aug 23 '22 10:08 YannBrrd

like this?

with Diagram("C1"):
    with Cluster("DC1"):
        sec_ops = User("Secops")
        users = Users("Users")
        security_proxy = Haproxy("HAPrx)")
        kms_1 = KMS("KMS")

    with Cluster("DC2"):
        pscpt = Server("Compute")
        kms_2 = KMS("KMS 2")

    sec_ops >> kms_1
    users >> security_proxy >> Edge(label="https") >> pscpt
    kms_2 >> Edge(minlen="0") >> pscpt
    kms_1 << Edge(color="firebrick", style="dashed", label="sync") << kms_2

image

clayms avatar Sep 10 '22 17:09 clayms

Yes thx

YannBrrd avatar Sep 21 '22 15:09 YannBrrd