Deploy memcached on deposit instance
So the authentication token cached during its validity period can be shared amongst threads.
Related to T3166
Test Plan
octocatalog-diff
$ bin/octocatalog-diff --octocatalog-diff-args --no-truncate-details --to staging moma
Found host moma.softwareheritage.org
*** Running octocatalog-diff on host moma.softwareheritage.org
I, [2021-03-24T09:49:51.822272 #18198] INFO -- : Catalogs compiled for moma.softwareheritage.org
I, [2021-03-24T09:49:54.646341 #18198] INFO -- : Diffs computed for moma.softwareheritage.org
I, [2021-03-24T09:49:54.646405 #18198] INFO -- : No differences
*** End octocatalog-diff on moma.softwareheritage.org
$ bin/octocatalog-diff --octocatalog-diff-args --no-truncate-details --to staging deposit.internal.staging.swh.network
Found host deposit.internal.staging.swh.network
*** Running octocatalog-diff on host deposit.internal.staging.swh.network
I, [2021-03-24T09:49:04.449118 #11450] INFO -- : Catalogs compiled for deposit.internal.staging.swh.network
I, [2021-03-24T09:49:06.580434 #11450] INFO -- : Diffs computed for deposit.internal.staging.swh.network
diff origin/production/deposit.internal.staging.swh.network current/deposit.internal.staging.swh.network
*******************************************
+ File[/etc/memcached.conf] =>
parameters =>
"group": 0
"mode": "0644"
"notify": "Service[memcached]"
"owner": "root"
"content": >>>
# File managed by puppet
# Run memcached as a daemon.
-d
# pidfile
-P /var/run/memcached.pid
# Log memcached's output
logfile /var/log/memcached.log
# Use <num> MB memory max to use for object storage.
-m 398
# IP to listen on
-l 127.0.0.1
# TCP port to listen on
-p 11211
# UDP port to listen on
-U 11211
# Run daemon as user
-u nobody
# Limit the number of simultaneous incoming connections.
-c 8192
# Number of threads to use to process incoming requests.
-t 4
<<<
*******************************************
File[/etc/softwareheritage/deposit/server.yml] =>
parameters =>
content =>
@@ -28,4 +28,5 @@
server_url: https://auth.softwareheritage.org/auth/
realm_name: SoftwareHeritageStaging
+cache_uri: 127.0.0.1:11211
allowed_hosts:
- deposit.staging.swh.network
*******************************************
+ Package[memcached] =>
parameters =>
"ensure": "present"
*******************************************
+ Service[memcached] =>
parameters =>
"enable": true
"ensure": "running"
"hasrestart": true
"hasstatus": false
*******************************************
*** End octocatalog-diff on deposit.internal.staging.swh.network
vagrant checks (provisioning step fine and services started without complaints):
- deposit.staging: ok
- prod-moma: ok
Migrated from D5317 (view on Phabricator)