Closed ktsakalozos closed 1 year ago
If the user sets the two SnapstoreProxyDomain SnapstoreProxyId configuration options the snapd registers to the designated snapstore proxy.
Tested manually based on the instructions in https://docs.ubuntu.com/snap-store-proxy/en/install. In short, in a VM next to the CAPI cluster do:
sudo snap install snap-store-proxy sudo apt install postgresql
Get the IP or host endpoint and put it in:
sudo snap-proxy config proxy.domain=<IP or host domain>
Configure postgress with something like:
$ cat ./ps.sql CREATE ROLE "snapproxy-user" LOGIN CREATEROLE PASSWORD 'snapproxy-password'; CREATE DATABASE "snapproxy-db" OWNER "snapproxy-user"; \connect "snapproxy-db" CREATE EXTENSION "btree_gist";
and
sudo -u postgres psql < ps.sql sudo snap-proxy config proxy.db.connection="postgresql://snapproxy-user@localhost:5432/snapproxy-db"
Register the proxy:
sudo snap-proxy register
Get the store proxy ID and endpoint with:
snap-proxy status
After merging this work we need to create a tag and have the MicroK8s controlplane provider use the tag so it gets updated with the new spec.
Can we also add a test case for the snapstore proxy configuration?
Added some tests, thanks for bringing it up.
If the user sets the two SnapstoreProxyDomain SnapstoreProxyId configuration options the snapd registers to the designated snapstore proxy.
Testing
Tested manually based on the instructions in https://docs.ubuntu.com/snap-store-proxy/en/install. In short, in a VM next to the CAPI cluster do:
Get the IP or host endpoint and put it in:
Configure postgress with something like:
and
Register the proxy:
Get the store proxy ID and endpoint with:
Do not forget
After merging this work we need to create a tag and have the MicroK8s controlplane provider use the tag so it gets updated with the new spec.