<commit_before># #! Admin Tools

Ansible playbooks and other admin tools/docs for maintaining the #! network.

## Requirements

  * Recent version of Ansible
  * Local [#! pass database](https://github.com/hashbang/password-store)
  * User with sudo access on all servers

## Usage

### Install a package

  1. Connect to any shell server as yourself

      ```bash
      ssh you@ny1.hashbang.sh
      ```

  2. Install Package

      ```bash
      sudo apt-get install some-package
      ```

  3. Update packages.txt list

      ```bash
      sudo dpkg --get-selections > /etc/packages.txt
      ```

  3. Commit changes via etckeeper

      ```bash
      sudo etckeeper commit -m 'Updated some package'
      ```

### Making a configuration change

  1. Connect to any shell server as yourself

      ```bash
      ssh you@ny1.hashbang.sh
      ```

  2. Make and test any desired changes to files in /etc

      ```bash
      sudo vim /etc/some-config/file
      ```

  3. Commit changes via etckeeper

      ```bash
      sudo etckeeper commit -m 'updated some-config with some change'
      ```

### Sync packages/config across all servers

  1. Run Ansible playbook "sync"

      ```bash
     ansible-playbook -K -u your-sudo-user sync.yml
      ```<commit_msg>README: Add `-i hosts` argument<commit_after># #! Admin Tools

Ansible playbooks and other admin tools/docs for maintaining the #! network.

## Requirements

  * Recent version of Ansible
  * Local [#! pass database](https://github.com/hashbang/password-store)
  * User with sudo access on all servers

## Usage

### Install a package

  1. Connect to any shell server as yourself

      ```bash
      ssh you@ny1.hashbang.sh
      ```

  2. Install Package

      ```bash
      sudo apt-get install some-package
      ```

  3. Update packages.txt list

      ```bash
      sudo dpkg --get-selections > /etc/packages.txt
      ```

  3. Commit changes via etckeeper

      ```bash
      sudo etckeeper commit -m 'Updated some package'
      ```

### Making a configuration change

  1. Connect to any shell server as yourself

      ```bash
      ssh <EMAIL>
      ```

  2. Make and test any desired changes to files in /etc

      ```bash
      sudo vim /etc/some-config/file
      ```

  3. Commit changes via etckeeper

      ```bash
      sudo etckeeper commit -m 'updated some-config with some change'
      ```

### Sync packages/config across all servers

  1. Run Ansible playbook "sync"

      ```bash
     ansible-playbook -K -u your-sudo-user -i hosts sync.yml
      ```
{'fraction_non_alphanumeric': 0.10505684045472363, 'fraction_numerical': 0.007448059584476676, 'mean_word_length': 2.2844272844272844, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 6, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 3, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7068696', 'n_tokens_mistral': 803, 'n_tokens_neox': 724, 'n_words': 274}