Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I want to install juju-gui using local provider (re lxc) on a cloud instance. However, the problem I have is that juju-gui will be installed into an lxc container itself and that container will be a non-routeable 10.x.x.x address.

I made some progress following these general instructions

After, creating my key files I made sure that the juju-gui container had a copy of them as well as the host (/etc/ssl/certs and /etc/ssl/private in the host and /var/lib/lxc/cn_name/rootfs/etc/ssl/certs and /var/lib/lxc/cn_name/rootfs/etc/ssl/private in the container).

Pointing my Browser to the Public IP of the Host cloud instance I do get redirected to juju-gui web Admin login page but it just keeps spinning with "Connecting to Juju environment" ??

I'm sure someone has done this before but I'm now stuck trying to figure out what is not configured right.

My goal is to be able to point my browser to the Cloud instance public address, login to juju-gui and because I'm setup for local provider deploy additional charms/services into more LXC containers within that Cloud instance.

share|improve this question
    
can you be more specific on what cloud you were testing this on? In order to help us duplicate and debug it'd be helpful. The thing to note is that the GUI talks to Juju over a wss websocket connection and it needs to be able to locate and connect to it in order to function. It sounds like this was not able to occur in your setup. –  Rick Jul 1 at 18:04

2 Answers 2

The short answer is that this is not currently a tested and supported way of setting up the Juju GUI. It needs to have direct wss communication with the juju state servers to function. The team is interested in this though and I'm curious if you could share some more specifics about your setup to see if there's work we can do to enable it and support it.

share|improve this answer

I finally just used the following IPTABLES commands to forward HTTP and HTTPS access to the LXC container that the JUJU-GUI is running in:

sudo iptables -t nat -I PREROUTING -p tcp -d <host-ip> --dport 443 -j DNAT --to <lxc-ip>:443
sudo iptables -t nat -I PREROUTING -p tcp -d <host-ip> --dport 80 -j DNAT --to <lxc-ip>:80
sudo iptables -A FORWARD -p tcp -d <lxc-ip> --dport 443 -j ACCEPT
sudo iptables -A FORWARD -p tcp -d <lxc-ip> --dport 80 -j ACCEPT

Using the above I am now able to access Juju-GUI running in an LXC container in "local" provider mode from the Internet.

Any charms deployed ... deploy to other LXC containers on the same host.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.