You are browsing a read-only backup copy of Wikitech. The live site can be found at wikitech.wikimedia.org

Difference between revisions of "Deployment server"

From Wikitech-static
Jump to navigation Jump to search
imported>Dzahn
(Created page with "Deployment servers are servers used for deployment. As of May 2019 the deployment servers are: deploy1001 in eqiad and deploy2001 in codfw. There is also...")
 
imported>Dzahn
Line 6: Line 6:
  
 
A former deployment server was [[tin]].
 
A former deployment server was [[tin]].
 +
 +
 +
=== How to setup a deployment server in a cloud VPS project ===
 +
 +
* create a new cloud VPS instance of size:
 +
* in [[Horizon]] apply the puppet 'role::deployment_server' on the instance
 +
* in the operations/puppet repo in ./hieradata/labs/yourproject/common.yaml or in Horizon add Hiera key/value pairs:
 +
 +
<pre>
 +
has_lvs: false
 +
has_tls: false
 +
mcrouter::has_ssl: false
 +
mcrouter::port: 11213
 +
mcrouter::shards:
 +
  wancache:
 +
    eqiad:
 +
      shard01:
 +
        host: deployment-memc04
 +
        port: 11211
 +
      shard02:
 +
        host: deployment-memc05
 +
        port: 11211
 +
      shard03:
 +
        host: deployment-memc08
 +
        port: 11211
 +
profile::kubernetes::deployment_server::git_group: wikidev
 +
profile::kubernetes::deployment_server::git_owner: trebuchet
 +
profile::mediawiki::apc_shm_size: 128M
 +
profile::mediawiki::deployment::server::rsync_host: deploy1001.devtools.eqiad.wmflabs
 +
profile::mediawiki::php::enable_fpm: true
 +
profile::mediawiki::php::php_version: '7.2'
 +
profile::rsyslog::kafka_shipper::kafka_brokers: []
 +
profile::services_proxy::ensure: absent
 +
profile::services_proxy::services:
 +
  dummy:
 +
    hostname: dummy.example.net
 +
    localport: 9999
 +
    port: 9999
 +
    scheme: https
 +
    timeout: 600
 +
redis::shards:
 +
  sessions:
 +
    eqiad:
 +
      shard01:
 +
        host: 172.16.5.76
 +
        port: 6379
 +
      shard02:
 +
        host: 172.16.5.17
 +
        port: 6379
 +
      shard03:
 +
        host: 172.16.5.12
 +
        port: 6379
 +
      shard04:
 +
        host: 172.16.5.2
 +
        port: 6379
 +
scap::dsh::groups:
 +
  librenms:
 +
    hosts:
 +
    - deployment-netbox.deployment-prep.eqiad.wmflabs
 +
  mediawiki-api-canaries:
 +
    hosts: []
 +
  mediawiki-appserver-canaries:
 +
    hosts:
 +
    - deployment-mediawiki-07.deployment-prep.eqiad.wmflabs
 +
  mediawiki-installation:
 +
    hosts:
 +
    - deployment-jobrunner03.deployment-prep.eqiad.wmflabs
 +
    - deployment-mediawiki-09.deployment-prep.eqiad.wmflabs
 +
    - deployment-mediawiki-07.deployment-prep.eqiad.wmflabs
 +
    - deployment-snapshot01.deployment-prep.eqiad.wmflabs
 +
    - deployment-deploy01.deployment-prep.eqiad.wmflabs
 +
    - deployment-deploy02.deployment-prep.eqiad.wmflabs
 +
    - deployment-mwmaint01.deployment-prep.eqiad.wmflabs
 +
    - deployment-mediawiki-parsoid10.deployment-prep.eqiad.wmflabs
 +
  restbase-betacluster:
 +
    hosts:
 +
    - deployment-restbase01.deployment-prep.eqiad.wmflabs
 +
    - deployment-restbase02.deployment-prep.eqiad.wmflabs
 +
  webperf:
 +
    hosts:
 +
    - deployment-webperf11.deployment-prep.eqiad.wmflabs
 +
scap::sources:
 +
  gerrit/gerrit:
 +
    repository: operations/software/gerrit
 +
  gervert/deploy:
 +
    repository: operations/software/gerrit/tools/gervert/deploy
 +
  phabricator/deployment:
 +
    repository: phabricator/deployment
 +
</pre>
 +
 +
* adjust the "deployment::server::rsync_host" value to a host in your project
 +
* run puppet (a couple times)
 +
* run sudo -u trebuchet /usr/bin/scap deploy --init inside each of the repos under /srv/deployment/, so for example in /srv/deployment/gerrit/gerrit and so on but NOT in /srv/deployment/ directly.
 +
* run git init in /srv/deployment
 +
* run puppet again

Revision as of 00:10, 16 January 2020

Deployment servers are servers used for deployment.

As of May 2019 the deployment servers are: deploy1001 in eqiad and deploy2001 in codfw.

There is also a service alias deployment.eqiad.wmnet pointing to the current server.

A former deployment server was tin.


How to setup a deployment server in a cloud VPS project

  • create a new cloud VPS instance of size:
  • in Horizon apply the puppet 'role::deployment_server' on the instance
  • in the operations/puppet repo in ./hieradata/labs/yourproject/common.yaml or in Horizon add Hiera key/value pairs:
has_lvs: false
has_tls: false
mcrouter::has_ssl: false
mcrouter::port: 11213
mcrouter::shards:
  wancache:
    eqiad:
      shard01:
        host: deployment-memc04
        port: 11211
      shard02:
        host: deployment-memc05
        port: 11211
      shard03:
        host: deployment-memc08
        port: 11211
profile::kubernetes::deployment_server::git_group: wikidev
profile::kubernetes::deployment_server::git_owner: trebuchet
profile::mediawiki::apc_shm_size: 128M
profile::mediawiki::deployment::server::rsync_host: deploy1001.devtools.eqiad.wmflabs
profile::mediawiki::php::enable_fpm: true
profile::mediawiki::php::php_version: '7.2'
profile::rsyslog::kafka_shipper::kafka_brokers: []
profile::services_proxy::ensure: absent
profile::services_proxy::services:
  dummy:
    hostname: dummy.example.net
    localport: 9999
    port: 9999
    scheme: https
    timeout: 600
redis::shards:
  sessions:
    eqiad:
      shard01:
        host: 172.16.5.76
        port: 6379
      shard02:
        host: 172.16.5.17
        port: 6379
      shard03:
        host: 172.16.5.12
        port: 6379
      shard04:
        host: 172.16.5.2
        port: 6379
scap::dsh::groups:
  librenms:
    hosts:
    - deployment-netbox.deployment-prep.eqiad.wmflabs
  mediawiki-api-canaries:
    hosts: []
  mediawiki-appserver-canaries:
    hosts:
    - deployment-mediawiki-07.deployment-prep.eqiad.wmflabs
  mediawiki-installation:
    hosts:
    - deployment-jobrunner03.deployment-prep.eqiad.wmflabs
    - deployment-mediawiki-09.deployment-prep.eqiad.wmflabs
    - deployment-mediawiki-07.deployment-prep.eqiad.wmflabs
    - deployment-snapshot01.deployment-prep.eqiad.wmflabs
    - deployment-deploy01.deployment-prep.eqiad.wmflabs
    - deployment-deploy02.deployment-prep.eqiad.wmflabs
    - deployment-mwmaint01.deployment-prep.eqiad.wmflabs
    - deployment-mediawiki-parsoid10.deployment-prep.eqiad.wmflabs
  restbase-betacluster:
    hosts:
    - deployment-restbase01.deployment-prep.eqiad.wmflabs
    - deployment-restbase02.deployment-prep.eqiad.wmflabs
  webperf:
    hosts:
    - deployment-webperf11.deployment-prep.eqiad.wmflabs
scap::sources:
  gerrit/gerrit:
    repository: operations/software/gerrit
  gervert/deploy:
    repository: operations/software/gerrit/tools/gervert/deploy
  phabricator/deployment:
    repository: phabricator/deployment
  • adjust the "deployment::server::rsync_host" value to a host in your project
  • run puppet (a couple times)
  • run sudo -u trebuchet /usr/bin/scap deploy --init inside each of the repos under /srv/deployment/, so for example in /srv/deployment/gerrit/gerrit and so on but NOT in /srv/deployment/ directly.
  • run git init in /srv/deployment
  • run puppet again