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

Toolsadmin.wikimedia.org: Difference between revisions

From Wikitech-static
Jump to navigation Jump to search
imported>Krinkle
m (Krinkle moved page Striker to Toolsadmin.wikimedia.org)
 
imported>BryanDavis
 
(14 intermediate revisions by 6 users not shown)
Line 1: Line 1:
{{ptag|Striker}}
[[File:La fragua.jpg|alt=The Forge (Goya)|thumb|''The Forge'' by Goya shows a striker and another apprentice assisting a blacksmith]]
[[File:La fragua.jpg|alt=The Forge (Goya)|thumb|''The Forge'' by Goya shows a striker and another apprentice assisting a blacksmith]]
'''toolsadmin.wikimedia.org''' is where maintainers of [[Help:Tool Labs|Tool Labs]] tools can manage their tools. The software that runs this interface is codenamed [[#Service|Striker]].
'''toolsadmin.wikimedia.org''' is where maintainers of [[Help:Toolforge|Toolforge]] tools can manage their tools. The software that runs this interface is codenamed [[#Service|Striker]].


== Features ==
== Features ==
* Associate Wikitech LDAP account, Wikimedia SUL account, and Phabricator account.
* [https://toolsadmin.wikimedia.org/register/ Wikimedia developer account creation wizard]
* Create Git repositories in Differential associated with a tool.
* [https://toolsadmin.wikimedia.org/profile/settings/ssh-keys SSH public key management]
* [https://toolsadmin.wikimedia.org/profile/settings/accounts Associate Wikimedia developer account, Wikimedia SUL account, and Phabricator account]
* [https://toolsadmin.wikimedia.org/tools/create Create new tool accounts]
* Create/update metadata describing a tool. This metadata is a superset of the data needed for [[toolforge:hay/directory/|Hay's directory]] and published there.
* Create Git repositories in [[:mw:Phabricator/Differential|Differential]] associated with a tool.
* Create [[mw:Phabricator/Project management|Phabricator projects]] associated with a tool.


== Service ==
=={{anchor|Striker}} Service ==
'''Striker''' is an [[:en:Django (web framework)|Django]] application for managing Tool Labs tools. A [[:en:Blacksmith#Blacksmith.27s_striker|blacksmith's striker]] is an assistant to a blacksmith whose job is to swing a heavy hammer at the direction of the blacksmith. Similarly, Striker performs various tasks at the direction of a tool maintainer.
 
'''Striker''' is an [[:en:Django (web framework)|Django]] application for managing Toolforge tools. A [[:en:Blacksmith#Blacksmith.27s_striker|blacksmith's striker]] is an assistant to a blacksmith whose job is to swing a heavy hammer at the direction of the blacksmith. Similarly, Striker performs various tasks at the direction of a tool maintainer.
 
=== Production deployment ===
Toolsadmin.wikimedia.org is provisioned via the <code>role::striker::web</code> Puppet class on [[labweb1001]] and [[labweb1002]]. This class sets up memcached, an Apache vhost, and a uwsgi service. The striker application code is deployed into the uwsgi service by [[scap3]] from the [[Deployment.eqiad.wmnet|deployment host]]. The application is configured by the <code>/etc/striker/striker.ini</code> file that is provisioned by Puppet and populated with data from hiera. The application's local database is hosted on the [[MariaDB/misc#m5|m5 section]]. The application also connects to the LDAP server for authn/authz and data lookup, Phabricator's public API, metawiki for OAuth authentication, and OpenStack's keystone API.
 
=== Testing deployment ===
https://striker.wmcloud.org in the [[Nova Resource:Striker|Striker project]] hosts a testing deployment that is used for beta testing. This deployment is managed with docker-compose similarly to the local development environment, but uses a production ready container for the striker service itself.
 
=== Local development ===
The local development environment uses [https://docs.docker.com/compose/ docker-compose] and [[w:GNU Make|GNU Make]] to manage a container hosting the project. Additional containers are provisioned to provide:
* a MariaDB database service
* an OpenLDAP service
* a Phabricator instance
* a Keystone service
* a MediaWiki wiki acting as a meta.wikimedia.org substitute
* a MediaWiki wiki acting as a wikitech.wikimedia.org substitute
 
{{Codesample|lang=shell-session|scheme=light|code=
$ git clone https://gerrit.wikimedia.org/r/labs/striker
$ cd striker
$ make start tail
  So much stuff scrolls by...
  Still scrolling...
  Will it ever stop?
  It should, but be on the lookout for repeating loops
  Eventually (~1-3 minutes) things should stop scrolling
  ^c
$ make init
More scrolling...
This should only take a few seconds...
$ open http://striker.local.wmftest.net:8080/
}}
{{Note|<code>open</code> is a MacOS command to open a file, directory, or url in the default application for that media type. On a Linux host you can either manually open the URL or use a similar URL opening script like <code>xdg-open</code>, <code>sensible-browser</code>, <code>x-www-browser</code>, or <code>gnome-open</code>.}}
See [[gerrit:plugins/gitiles/labs/striker/+/refs/heads/master/contrib/docker/README.md|contrib/docker/README.md]] for additional manual steps needed once the initial startup is complete.
 
=== Contributing ===
Submit patches to the [[gerrit:#/projects/labs/striker,dashboards/default:recent|labs/striker gerrit project]]. Tests and linting can be done locally using <code>tox</code>.


== See also ==
== See also ==
* [[/FAQ|Frequently (un)asked questions]]
* [[/Deployments|Deployment log]]
* [[/Build|Build and deploy process]]
* [[Meta:Community Tech/Tool Labs support/Tool Labs vision|Tool Labs vision]]
* [[Meta:Community Tech/Tool Labs support/Tool Labs vision|Tool Labs vision]]
* [[Phab:T136256]]
* [[Phab:T136256]] (Deploy "Striker" Tool Labs console to WMF production)
* [[phab:phame/post/view/67/tool_creation_added_to_toolsadmin.wikimedia.org/|Tool creation added to toolsadmin.wikimedia.org]] (28 August 2017 blog post)
* [[Nova Resource:Striker]]


== External link ==
== External link ==
Line 17: Line 65:


{{lowercase}}
{{lowercase}}
[[Category:Current]]
[[Category:Software]]
[[Category:Services]]
[[Category:Services]]
[[Category:Toolforge|admin]]

Latest revision as of 15:05, 8 May 2022

The Forge (Goya)
The Forge by Goya shows a striker and another apprentice assisting a blacksmith

toolsadmin.wikimedia.org is where maintainers of Toolforge tools can manage their tools. The software that runs this interface is codenamed Striker.

Features

Service

Striker is an Django application for managing Toolforge tools. A blacksmith's striker is an assistant to a blacksmith whose job is to swing a heavy hammer at the direction of the blacksmith. Similarly, Striker performs various tasks at the direction of a tool maintainer.

Production deployment

Toolsadmin.wikimedia.org is provisioned via the role::striker::web Puppet class on labweb1001 and labweb1002. This class sets up memcached, an Apache vhost, and a uwsgi service. The striker application code is deployed into the uwsgi service by scap3 from the deployment host. The application is configured by the /etc/striker/striker.ini file that is provisioned by Puppet and populated with data from hiera. The application's local database is hosted on the m5 section. The application also connects to the LDAP server for authn/authz and data lookup, Phabricator's public API, metawiki for OAuth authentication, and OpenStack's keystone API.

Testing deployment

https://striker.wmcloud.org in the Striker project hosts a testing deployment that is used for beta testing. This deployment is managed with docker-compose similarly to the local development environment, but uses a production ready container for the striker service itself.

Local development

The local development environment uses docker-compose and GNU Make to manage a container hosting the project. Additional containers are provisioned to provide:

  • a MariaDB database service
  • an OpenLDAP service
  • a Phabricator instance
  • a Keystone service
  • a MediaWiki wiki acting as a meta.wikimedia.org substitute
  • a MediaWiki wiki acting as a wikitech.wikimedia.org substitute
$ git clone https://gerrit.wikimedia.org/r/labs/striker
$ cd striker
$ make start tail
  So much stuff scrolls by...
  Still scrolling...
  Will it ever stop?
  It should, but be on the lookout for repeating loops
  Eventually (~1-3 minutes) things should stop scrolling
  ^c
$ make init
 More scrolling...
 This should only take a few seconds...
$ open http://striker.local.wmftest.net:8080/

See contrib/docker/README.md for additional manual steps needed once the initial startup is complete.

Contributing

Submit patches to the labs/striker gerrit project. Tests and linting can be done locally using tox.

See also

External link