summaryrefslogtreecommitdiff
path: root/doc/forum/Getting_Info_from_containers/comment_2_347f67e1be11f69fab571d8f9e7612b5._comment
blob: 5db271fd9277c53e4e1c00ffb265db4d067858dd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
[[!comment format=mdwn
 username="Nicolas.Schodet"
 avatar="http://cdn.libravatar.org/avatar/0d7ec808ec329d04ee9a93c0da3c0089"
 subject="containerToHost?"
 date="2019-04-16T17:23:16Z"
 content="""
Would it be possible to add a `containerToHost` wrapper that takes a container
and returns a host?

It would be something like this:

	hosts :: [Host]
	hosts =
		[ myHost
		, myContainerHost
		]

	myHost = host \"myhost.mydomain\" $ props
		& ...
		& myContainerSpawn myContainer

	myContainer :: Systemd.Container
	myContainer = Systemd.debContainer \"mycontainer\" $ props
		& ...

	myContainerHost = containerToHost \"mycontainer.mydomain\" myContainer

"""]]