~tcuthbert/ubuntu-repository-cache/squid-mem-max

« back to all changes in this revision

Viewing changes to README.md

  • Committer: Robert Jennings
  • Date: 2014-08-21 02:20:38 UTC
  • Revision ID: robert.jennings@canonical.com-20140821022038-16h2c7qgk51ynvwu
Updates to documentation and added missing copyright file

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
# Overview
2
2
 
3
 
This is a purpose-oriented charm, to provide a caching proxy mirror of the
4
 
Ubuntu archive on cloud platforms.
5
 
 
6
 
This is a hybrid mirror.  All data except /ubuntu/pool is synced from
7
 
upstream Ubuntu mirrors every 2 hours.  /ubuntu/pool is forwarded internally
8
 
to squid-deb-proxy, which keeps a local cache of .deb files as they are
9
 
requested.
 
3
** EXPERIMENTAL QUALITY WARNING **
 
4
 
 
5
This charm provides a partial caching proxy mirror of the 
 
6
[Ubuntu Software Repository](https://help.ubuntu.com/community/Repositories/Ubuntu
 
7
"Repository Documentation").  This is intended for deployment in cloud 
 
8
environments to provide a cloud-local repository.
 
9
 
 
10
This is a hybrid mirror / cache.  All data except /ubuntu/pool is synced from
 
11
upstream Ubuntu mirrors and checked to ensure that it is consistent.
 
12
Requests for package files in /ubuntu/pool are forwarded internally
 
13
to squid-deb-proxy, which keeps a local cache of .deb files as they
 
14
are requested.
10
15
 
11
16
# Usage
12
17
 
13
 
Deploy the charm with the command:
 
18
Deploy the charm with these [exmaple][id] commands:
14
19
 
 
20
    # Create cache units
15
21
    juju set-constraints --service ubuntu-repository-cache mem=8G root-disk=80G
16
22
    juju deploy ubuntu-repository-cache
17
23
 
18
 
You can then browse to http://ip-address to view the repository when complete or add a proxy in front of this service.
19
 
 
20
 
## Scale out Usage
21
 
 
22
 
Scale out is currently unsupported.
 
24
    # Provide ntp service with local NTP masters
 
25
    juju deploy ntp
 
26
    juju deploy -n 2 ntpmaster
 
27
    juju add-relationship ntp ntpmaster
 
28
    juju add-relationship ntp ubuntu-repository-cache
 
29
    
 
30
The ubuntu-repository-cache charm's constraint for disk size is optional, 
 
31
the intention is to allocate sufficient space for the metadata mirror
 
32
(approximately 4GB) plus as much space as can be afforded for squid to cache
 
33
package files.
 
34
 
 
35
Ideally this charm should be deployed with this disk space allocated as fast
 
36
storage (which may require ephemeral storage depending on the provider); use
 
37
of the manual provider may be necessary to achieve this.
 
38
 
 
39
When running, you can browse to http://ip-address to view the repository
 
40
when the initial mirror sync has completed.  Alternatively, you may add a
 
41
proxy in front of this service.
 
42
 
 
43
## Scale out usage
 
44
 
 
45
Scale out is currently unsupported but not blocked.  Scaling out past one unit
 
46
will result in units serving metadata from different points in time, when put
 
47
behind a load balancer the client will get an inconsistent view of the
 
48
repository which will break apt.  The result will be `hash sum mismatch`
 
49
errors for the apt client.
 
50
 
 
51
See the TODO file for items marked `[Scale]`.
23
52
 
24
53
## Known Limitations and Issues
25
54
 
26
 
Alpha quality
 
55
Early alpha quality
27
56
 
28
57
# Configuration
29
58
 
30
 
The configuration options will be listed on the charm store, however If you're making assumptions or opinionated decisions in the charm (like setting a default administrator password), you should detail that here so the user knows how to change it immediately, etc.
 
59
 
31
60
 
32
61
# Contact Information
33
62
 
34
 
Though this will be listed in the charm store itself don't assume a user will know that, so include that information here:
 
63
Though this will be listed in the charm store itself don't assume a user
 
64
will know that, so include that information here:
35
65
 
36
66
## Upstream Project Name
37
67