<div dir="auto"><div>*the local snapd<br><div class="gmail_extra"><br><div class="gmail_quote">On Jan 23, 2017 8:04 PM, "Gustavo Niemeyer" <<a href="mailto:gustavo@niemeyer.net">gustavo@niemeyer.net</a>> wrote:<br type="attribution"><blockquote class="quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="auto">Indeed, that smells like a bug, certainly because snap download doesn't use the local snaps to actually download the file. That should be transparent to the CLI though.<div dir="auto"><br></div><div dir="auto">Can you please file an issue?</div><div dir="auto"><br></div><div dir="auto">Thanks!</div></div><div class="elided-text"><div class="gmail_extra"><br><div class="gmail_quote">On Jan 23, 2017 5:26 PM, "Max Brustkern" <<a href="mailto:max.brustkern@canonical.com" target="_blank">max.brustkern@canonical.com</a>> wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div>Okay, you're right. I was testing with snap download, which doesn't seem to use to proxy, whereas snap refresh does. Is that intended behavior, or should I report it somewhere?<br><br></div>Thanks,<br></div>Max<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Jan 23, 2017 at 2:04 PM, Gustavo Niemeyer <span dir="ltr"><<a href="mailto:gustavo.niemeyer@canonical.com" target="_blank">gustavo.niemeyer@canonical.co<wbr>m</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="auto">This should work fine across reboots.</div><div class="m_8362273385493904998m_-7576983333757221059HOEnZb"><div class="m_8362273385493904998m_-7576983333757221059h5"><div class="gmail_extra"><br><div class="gmail_quote">On Jan 23, 2017 4:49 PM, "Max Brustkern" <<a href="mailto:max.brustkern@canonical.com" target="_blank">max.brustkern@canonical.com</a>> wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div><div>So I've been able to get it to work by creating<br>/etc/systemd/system/snapd.serv<wbr>ice.d/proxy.conf<br></div>with the correct settings. Any suggestions on getting that to persist across reboots?<br><br></div>Thanks,<br></div>Max<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Jan 12, 2017 at 2:28 PM, Michael Hudson-Doyle <span dir="ltr"><<a href="mailto:michael.hudson@canonical.com" target="_blank">michael.hudson@canonical.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote"><span>On 13 January 2017 at 08:14, Max Brustkern <span dir="ltr"><<a href="mailto:max.brustkern@canonical.com" target="_blank">max.brustkern@canonical.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div><div><div><div>So I created a system directory with the contents of /lib/systemd/system. I edited that file to contain the environment variables:<br>nuclearbob@localhost:~$ cat /lib/systemd/system/snapd.serv<wbr>ice <br>[Unit]<br>Description=Snappy daemon<br>Requires=snapd.socket<br><br>[Service]<br>ExecStart=/usr/lib/snapd/snapd<br>EnvironmentFile=/etc/environme<wbr>nt<br>Restart=always<br>http_proxy=<a href="http://squid.internal:3128" target="_blank">http://squid.intern<wbr>al:3128</a><br>https_proxy=<a href="https://squid.internal:3128" target="_blank">https://squid.inte<wbr>rnal:3128</a></div></div></div></div></div></blockquote><div><br></div></span><div>That's not the right syntax, it should be</div><div><br></div><div>Environment=http_proxy=<a href="http://squid.internal:3128/" target="_blank">http://<wbr>squid.internal:3128</a> https_prox<wbr>y=<a href="https://squid.internal:3128/" target="_blank">https://squid.internal:3128</a></div><div><br></div><div>See man systemd.exec for more details on this.</div><div><br></div><div>Cheers,</div><div>mwh</div><div><div class="m_8362273385493904998m_-7576983333757221059m_-64196931053817837m_-5449674102728976068h5"><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div><div><div><div><br>[Install]<br>WantedBy=multi-user.target<br><br></div>I then did:<br>nuclearbob@localhost:~$ sudo systemctl daemon-reload<br>nuclearbob@localhost:~$ sudo service snapd restart<br><br></div>I still don't seem to see snapd picking up on the proxy. I tried:<br>sudo systemctl edit snapd<br></div>I pasted in the file contents to there, but after that I get:<br>nuclearbob@localhost:~$ sudo service snapd restart<br>Failed to restart snapd.service: Unit snapd.service is not loaded properly: Invalid argument.<br>See system logs and 'systemctl status snapd.service' for details.<br>nuclearbob@localhost:~$ systemctl status snapd.service<br>● snapd.service - Snappy daemon<br> Loaded: error (Reason: Invalid argument)<br> Drop-In: /etc/systemd/system/snapd.serv<wbr>ice.d<br> └─override.conf<br> Active: active (running) since Thu 2017-01-12 19:11:46 UTC; 2min 26s ago<br> Main PID: 1339 (snapd)<br> CGroup: /system.slice/snapd.service<br> └─1339 /usr/lib/snapd/snapd<br><br></div>Any additional tips to get snapd running on ubuntu core in the lab?<br><div><div><div><div><div><div class="gmail_extra"><br><div class="gmail_quote"><div><div class="m_8362273385493904998m_-7576983333757221059m_-64196931053817837m_-5449674102728976068m_6115015415556405190gmail-h5">On Wed, Jan 11, 2017 at 11:49 PM, Stuart Bishop <span dir="ltr"><<a href="mailto:stuart.bishop@canonical.com" target="_blank">stuart.bishop@canonical.com</a>></span> wrote:<br></div></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div><div class="m_8362273385493904998m_-7576983333757221059m_-64196931053817837m_-5449674102728976068m_6115015415556405190gmail-h5"><div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote"><span class="m_8362273385493904998m_-7576983333757221059m_-64196931053817837m_-5449674102728976068m_6115015415556405190gmail-m_1319056982746270045gmail-">On 12 January 2017 at 01:44, Max Brustkern <span dir="ltr"><<a href="mailto:max.brustkern@canonical.com" target="_blank">max.brustkern@canonical.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div><div><div>I'm trying to run ubuntu core 16 in a kvm instance in an internal lab that requires a web proxy. This bug:<br><a href="https://bugs.launchpad.net/ubuntu/+source/snapd/+bug/1579652" target="_blank">https://bugs.launchpad.net/ubu<wbr>ntu/+source/snapd/+bug/1579652</a><br></div>seems to cover how to do this on classic ubuntu, but the files that hold the environment variables used by snapd on an ubuntu core system are all on read-only filesystems. How do I set HTTPS_PROXY in a persistent way for snapd on that system?<br></div></div></div></blockquote></span><div><br><a href="https://bugs.launchpad.net/snappy/+bug/1533899" target="_blank">https://bugs.launchpad.net/sna<wbr>ppy/+bug/1533899</a> is similar, but about adding support for proxies to snapd (rather than have it use the system environment variables, which is one implementation option but not always what you want since that affects everything on the system). But that doesn't help with your read-only filesystem sorry :-(<br><br></div><div>(Hmm... disgusting hack idea.... since you can't create /etc/systemd/system/snapd.serv<wbr>ice.d/ on your read-only filesystem, try mounting that directory from somewhere. Extra points for using systemd to mount the systemd service file overrides and setting up dependencies so it does everything in the right order :-) )<span class="m_8362273385493904998m_-7576983333757221059m_-64196931053817837m_-5449674102728976068m_6115015415556405190gmail-m_1319056982746270045gmail-HOEnZb"><font color="#888888"><br></font></span></div></div><span class="m_8362273385493904998m_-7576983333757221059m_-64196931053817837m_-5449674102728976068m_6115015415556405190gmail-m_1319056982746270045gmail-HOEnZb"><font color="#888888"><br clear="all"><br>-- <br><div class="m_8362273385493904998m_-7576983333757221059m_-64196931053817837m_-5449674102728976068m_6115015415556405190gmail-m_1319056982746270045gmail-m_258486575297686928gmail_signature">Stuart Bishop <<a href="mailto:stuart.bishop@canonical.com" target="_blank">stuart.bishop@canonical.com</a>></div>
</font></span></div></div>
<br></div></div><span class="m_8362273385493904998m_-7576983333757221059m_-64196931053817837m_-5449674102728976068m_6115015415556405190gmail-HOEnZb"><font color="#888888">--<br>
Snapcraft mailing list<br>
<a href="mailto:Snapcraft@lists.snapcraft.io" target="_blank">Snapcraft@lists.snapcraft.io</a><br>
Modify settings or unsubscribe at: <a href="https://lists.ubuntu.com/mailman/listinfo/snapcraft" rel="noreferrer" target="_blank">https://lists.ubuntu.com/mailm<wbr>an/listinfo/snapcraft</a><br>
<br></font></span></blockquote></div><br></div></div></div></div></div></div></div>
<br>--<br>
Snapcraft mailing list<br>
<a href="mailto:Snapcraft@lists.snapcraft.io" target="_blank">Snapcraft@lists.snapcraft.io</a><br>
Modify settings or unsubscribe at: <a href="https://lists.ubuntu.com/mailman/listinfo/snapcraft" rel="noreferrer" target="_blank">https://lists.ubuntu.com/mailm<wbr>an/listinfo/snapcraft</a><br>
<br></blockquote></div></div></div><br></div></div>
<br>--<br>
Snapcraft mailing list<br>
<a href="mailto:Snapcraft@lists.snapcraft.io" target="_blank">Snapcraft@lists.snapcraft.io</a><br>
Modify settings or unsubscribe at: <a href="https://lists.ubuntu.com/mailman/listinfo/snapcraft" rel="noreferrer" target="_blank">https://lists.ubuntu.com/mailm<wbr>an/listinfo/snapcraft</a><br>
<br></blockquote></div><br></div>
<br>--<br>
Snapcraft mailing list<br>
<a href="mailto:Snapcraft@lists.snapcraft.io" target="_blank">Snapcraft@lists.snapcraft.io</a><br>
Modify settings or unsubscribe at: <a href="https://lists.ubuntu.com/mailman/listinfo/snapcraft" rel="noreferrer" target="_blank">https://lists.ubuntu.com/mailm<wbr>an/listinfo/snapcraft</a><br>
<br></blockquote></div></div>
</div></div><br>--<br>
Snapcraft mailing list<br>
<a href="mailto:Snapcraft@lists.snapcraft.io" target="_blank">Snapcraft@lists.snapcraft.io</a><br>
Modify settings or unsubscribe at: <a href="https://lists.ubuntu.com/mailman/listinfo/snapcraft" rel="noreferrer" target="_blank">https://lists.ubuntu.com/mailm<wbr>an/listinfo/snapcraft</a><br>
<br></blockquote></div><br></div>
<br>--<br>
Snapcraft mailing list<br>
<a href="mailto:Snapcraft@lists.snapcraft.io" target="_blank">Snapcraft@lists.snapcraft.io</a><br>
Modify settings or unsubscribe at: <a href="https://lists.ubuntu.com/mailman/listinfo/snapcraft" rel="noreferrer" target="_blank">https://lists.ubuntu.com/mailm<wbr>an/listinfo/snapcraft</a><br>
<br></blockquote></div></div>
</div></blockquote></div><br></div></div></div>