https://pulumi.com logo
c

creamy-potato-29402

10/22/2018, 9:39 PM
cloud might be a laggard. 🙂 let me look
@tall-monitor-77779 it uses the standard build infrastructure so
make test_all
should work
also much of pulumi/pulumi contributing.md should apply here as well.
t

tall-monitor-77779

10/22/2018, 9:40 PM
yeah just reading thru that now thanks!
cloud.Service
is killing me
c

creamy-potato-29402

10/22/2018, 9:43 PM
yeah that makes sense
I don’t know much about the cloud package though so I’m not sure how much I can help……
t

tall-monitor-77779

10/22/2018, 9:43 PM
I love it and hate it
such a powerful abstraction, removing the need to manually create VPC’s, Security Groups etc.
and its ALMOST perfect
w

white-balloon-205

10/22/2018, 9:44 PM
Cc @lemon-spoon-91807 who may be able to help with some of the questions here.
c

creamy-potato-29402

10/22/2018, 9:45 PM
Yeah, personally, I find this to be true of most new noun-based abstractions. 🙂
t

tall-monitor-77779

10/22/2018, 9:45 PM
I’ve been down a rabbit hole today with it
c

creamy-potato-29402

10/22/2018, 9:45 PM
same could be said of Kubernetes
Service
and
Ingress
t

tall-monitor-77779

10/22/2018, 9:45 PM
true
c

creamy-potato-29402

10/22/2018, 9:45 PM
In the limit the complexity of new nouns becomes the transitive closure of all subcomponents that it abstracts.
t

tall-monitor-77779

10/22/2018, 9:45 PM
thanks @white-balloon-205 will look forward to chatting wit him
l

lemon-spoon-91807

10/22/2018, 9:46 PM
Hi there 🙂
t

tall-monitor-77779

10/22/2018, 9:46 PM
Hola
I have 2 requirements: 1. not to publish my service externally 2. to use DNS for service discovery
I’ve used
cloud-aws:usePrivateNetwork: "true"
which is fair enough, tho I think we really should be able to pass such parameters when constructing the
cloud.Service
l

lemon-spoon-91807

10/22/2018, 9:48 PM
slack crashed 🙂
t

tall-monitor-77779

10/22/2018, 9:48 PM
there is lots of spagetti there, you wind up chasing your arse to figure out what
getOrCreateNetwork
and
getCluster
does
then you find out that you can alter its behaviour with parameters
l

lemon-spoon-91807

10/22/2018, 9:49 PM
yup. the feedback makes sense
note: i'm not a particular expert in this area. @white-balloon-205 is there a reason that hte Network portion of cloud.Service is not something that a user can supply when making a Service?
t

tall-monitor-77779

10/22/2018, 9:50 PM
so I thought, I’ll folk and PR to add
useLoadBalancer?: boolean;
to
ServiceArguments
and then skip
createLoadBalancer
at
aws/service.ts#723
if this is set to
false
l

lemon-spoon-91807

10/22/2018, 9:52 PM
my concern there would be:
t

tall-monitor-77779

10/22/2018, 9:52 PM
but then got into a whole world of pain (see above)
l

lemon-spoon-91807

10/22/2018, 9:52 PM
if we don't create a load balancer, later on other stuff will not be happy
like line: 237
t

tall-monitor-77779

10/22/2018, 9:53 PM
const hostname = info.host.dnsName;
?
l

lemon-spoon-91807

10/22/2018, 9:53 PM
yes
t

tall-monitor-77779

10/22/2018, 9:54 PM
umm
l

lemon-spoon-91807

10/22/2018, 9:54 PM
i'm just trying to compute out hte downstream impact of not having a load balancer
t

tall-monitor-77779

10/22/2018, 9:54 PM
I think @white-balloon-205 agreed the other day that DNS for service discover was a good thing
l

lemon-spoon-91807

10/22/2018, 9:55 PM
(this is not an area of expertise for me)
t

tall-monitor-77779

10/22/2018, 9:55 PM
that was going to be my next task after disabling LB
l

lemon-spoon-91807

10/22/2018, 9:55 PM
sorry, i'm not questioning the ask 🙂 or hte desire. I'm just trying to figure out what would need to happen in the code to make this feasible 🙂
t

tall-monitor-77779

10/22/2018, 9:55 PM
yeah thats fair, np
l

lemon-spoon-91807

10/22/2018, 9:56 PM
i.e. it doesn't look as simple as just 'do not create the load balancer'. since code a few steps down looks lke it will just crash.
however, it looks like this is just being done to create some environment variables. so maybe it's fine to just not do that
So: question for you. If you try this locally (i.e. just comment out the line that makes the load balance, and comment out the line that uses that later on to create environment variables), do things otherwise work for you?
do you get the resultant set of infrastructure you want, confiured properly for your needs?
t

tall-monitor-77779

10/22/2018, 9:58 PM
good question, lets see
l

lemon-spoon-91807

10/22/2018, 9:58 PM
Ok 🙂
let me know what you discover/learn
because that can feed into an appropriate PR with a suitable design to address things here
t

tall-monitor-77779

10/22/2018, 9:59 PM
(never easy going thru the TS generated JS) 😕
l

lemon-spoon-91807

10/22/2018, 10:00 PM
it shouldn't be too bad 🙂 it's just an NPM package. so you can whack away to your heart's content 😄
can i help with anything else? or is this a reasonable starting point to just see if we can get enough info to proceed?
t

tall-monitor-77779

10/22/2018, 10:17 PM
sorry deleting a
aws:ec2:Subnet
seems to be taking an absolute age
just waiting for that before I run with the LB commented out
l

lemon-spoon-91807

10/22/2018, 10:19 PM
indeed, tens of minutes sometimes
t

tall-monitor-77779

10/22/2018, 10:32 PM
yeah so
function getEndpoints
isn’t happy, needs
dnsName
so going into another rabbit hole
so yeah, thats not a simple change to skip the LB create
l

lemon-spoon-91807

10/22/2018, 10:33 PM
ah yup. that's another location
getEndpoints shouldn't be too hard to update though
t

tall-monitor-77779

10/22/2018, 10:34 PM
I’m defeated! lost an whole day on this 😕
looks like I’m gunna have to manually construct an ECS cluster with much the same code as
cloud.Service
😞
l

lemon-spoon-91807

10/22/2018, 10:35 PM
oh no! that sucks 😞 I'm going to open a bug for us to track this. I'm a little wary about it as i'm not sure the entire implications of not having a load balancer
but it's something we can try to make better in the future
Also, what's your github alias, so i can tag you in the issue? Thanks!
t

tall-monitor-77779

10/22/2018, 10:36 PM
I think its really worth putting some attention to, its a great feature of pulumi, but its in need of some simplification and less black magic
danny-waite
is my github user
l

lemon-spoon-91807

10/22/2018, 10:37 PM
Working on a potential PR now for Danny to try out