1
1
mirror of https://gitlab.archlinux.org/archlinux/infrastructure.git synced 2025-01-18 08:06:16 +01:00
Commit Graph

79 Commits

Author SHA1 Message Date
Kristian Klausen
8fd7e903ec
Remove obsolete "pacman-website" playbook
Fixes: c4f13d3a ("archweb: Redirect /pacman/ to new pacman subdomain[1]")
2024-12-31 16:27:31 +01:00
Sven-Hendrik Haase
07cac01fd8
Fix packer and update plugins 2024-11-19 11:34:37 +01:00
Evangelos Foutras
d5e6e39f0c
tasks/sync-ssh-hostkeys: quiet ssh-keyscan banners
We don't want these comments to be added to docs/ssh-known_hosts.txt.

From OpenSSH 9.8 release notes [1]:

 * ssh-keyscan(1): this tool previously emitted comment lines
   containing the hostname and SSH protocol banner to standard error.
   This release now emits them to standard output, but adds a new
   "-q" flag to silence them altogether.

[1] https://www.openssh.com/txt/release-9.8
2024-08-18 16:45:31 +03:00
Kristian Klausen
4e5550a877
Decommission bugs.archlinux.org and replace it with a static copy[1]
As announced[2][3] the bugtracker has been migrated to gitlab, so
bugs.a.o can be decommissioned and replaced with a static copy[1](to
avoid link rot).

[1] https://gitlab.archlinux.org/archlinux/bugs-archive/
[2] https://archlinux.org/news/bugtracker-migration-to-gitlab-completed/
[3] https://lists.archlinux.org/hyperkitty/list/arch-dev-public@lists.archlinux.org/thread/WYXDTJ3TR2DWRQCDZK44BQDH67IDVGTS/

Fix #550
Fix #551
2024-02-10 17:07:38 +01:00
Evangelos Foutras
0f612e2f6f
tasks/upgrade-servers: avoid "meta: end_host" task
This allows for tasks/include/upgrade-server.yml to be reused elsewhere.
2023-08-20 14:34:05 +03:00
Evangelos Foutras
404f8b3aae
sshd: remove support for custom ssh.d directory
The same drop-in functionality is now provided by the openssh package
via /etc/ssh/sshd_config.d/.
2023-08-13 22:06:10 +03:00
Evangelos Foutras
902704364f
tasks/upgrade-servers: exclude bugs.archlinux.org
Its php7 package can easily break from library upgrades like ICU.
2023-07-20 20:17:13 +03:00
Jelle van der Waa
4159a61f5e dbscripts: switch to Git packaging
This drops all svn specific functionality and switches to dbscripts git
version. Drops the community repository as it's merged into extra.
2023-05-22 13:04:27 +00:00
Evangelos Foutras
6fae977112
tasks/sync-ssh-hostkeys: support ansible_port var
gitlab.archlinux.org's host SSH daemon now listens on port 2222. Adjust
the sync-ssh-hostkeys task to take this into account. Port 22 is for GL.
2023-05-20 13:56:50 +03:00
Evangelos Foutras
3b9a0d4141
tasks/upgrade-servers: upgrade Keycloak box first
matrix.archlinux.org doesn't like it when accounts.archlinux.org is
unavailable at start-up. Try to work around this by upgrading
accounts.archlinux.org first and doing a health check before proceeding
to update the rest of the servers.

Fixes: #496
2023-02-27 18:27:39 +02:00
Evangelos Foutras
66224e0d08
tasks/upgrade-servers: host-specific post-upgrades
The Ansible output is too noisy with all the skipped tasks; avoid this
by moving host-speicific tasks into their own files that get included.
2022-09-20 15:03:10 +03:00
Evangelos Foutras
d381d81800
Move 'noqa' tags next to the name instead of module
This avoid having extra-long lines and works fine for task-based rules.
2022-08-23 08:07:09 +03:00
Evangelos Foutras
ab7edadf0b
Replace noqa tag '208' with 'risky-file-permissions' 2022-08-23 07:06:34 +03:00
Evangelos Foutras
26f289b72b
Capitalize the first letter of all task names
ansible-lint 6.5.0 complains about:

  name: All names should start with an
        uppercase letter. (name[casing])
2022-08-23 06:57:13 +03:00
nl6720
e74066e3c8
Use C.UTF-8 as the default locale
The glibc 2.35-6 package ships with the C.UTF-8 locale included which
means there is now a usable UTF-8 locale available by default.

en_US.UTF-8 will still be generated because PostgreSQL clusters are
created with that locale. Migrating the clusters to C.UTF-8 is
possible, but that requires dumping and recreating them.
2022-07-23 19:13:59 +03:00
Evangelos Foutras
83f0066a14
Replace references to Packet.net with Equinix Metal
Also tweak the documentation on rebuilderd workers and add runner1.
2022-07-10 12:42:15 +03:00
Evangelos Foutras
a9e0790f53
Remove the three dashes from all YAML documents
These are used to signal the start of the document in a stream of many
documents. As Ansible only supports one YAML document per file this is
unnecessary. About a third of our YAML documents already lacked these.
2022-06-08 14:35:45 +03:00
Evangelos Foutras
b4d60ae2f6
Move highly sensitive secrets to new "super" vault
The idea bebind this is to be able to give vault access to new DevOps
members without giving away more important credentials like Hetzner's.
2022-05-07 17:45:19 +03:00
Evangelos Foutras
1f6cf2dfa5
install_arch: download the latest bootstrap image 2022-04-26 03:40:40 +03:00
Evangelos Foutras
ec52eb098f
Update packer build and use smaller BIOS boot partition
- Create packer builder in FSN1 and change image to ubuntu-20.04
- Add "use_proxy: false" to provisioner config to work around [1]
- Reduce the size of the BIOS boot partition to 1M (from 10M) [2]
- Update bootstrap_version to 2022.03.01

[1] https://github.com/hashicorp/packer-plugin-ansible/issues/69
[2] https://www.gnu.org/software/grub/manual/grub/html_node/BIOS-installation.html
2022-03-28 02:26:20 +03:00
Evangelos Foutras
7d5fd109dd
tasks/upgrade-servers: tweak pacman upgrade logic
Avoid updating the cache in the same task w/ the upgrade as the former
causes the combined task to always return changed=True. For up-to-date
hosts, stop early instead of following through to the end and skipping
the final reboot task.

Before Ansible 5.4.0, combined cache update + package upgrade would not
always return changed=True but instead depended on whether the were any
packages to upgrade.
2022-03-05 17:06:00 +02:00
Evangelos Foutras
aa4b54958b
tasks/sync-ssh-hostkeys: use blocks for shell cmds
Do the same for the hostkeys/known_hosts templates and disable fact
gathering.
2022-02-26 11:08:30 +02:00
Evangelos Foutras
dc0f4655df
Remove our two borg hosts from the inventory
These are managed services and Ansible doesn't run on them. It got
boring writing 'all,!rsync_net,!hetzner_storageboxes' in playbooks
and ad-hoc commands, so remove these borg hosts from our inventory.
2022-02-26 11:08:30 +02:00
Evangelos Foutras
6c60c6bd40
tasks/sync-ssh-hostkeys: allow custom known_hosts
Change docs/ssh-known_hosts.txt to be partially managed by Ansible, so
custom entries can be added to the top of the file. Use the new format
to write down the host keys of our two borg hosts.
2022-02-25 09:16:35 +02:00
Evangelos Foutras
f6a0208e77
tasks: skip reboot if /backup mountpoint exists
Service facts did not provide enough information about the state of
the borg-backup{,-offsite} services. While runnning, their state is
reported as stopped by service_facts and "activating" by systemctl.
2022-02-05 17:17:17 +02:00
Evangelos Foutras
b6972fda76
tasks: stop arch-svntogit.timer before rebooting
In a recent execution of the server upgrade task, svntogit was started
shortly before the reboot command was issued. Therefore, it was killed
two seconds into its run, leaving behind a lock file that prevented it
from starting again after gemini was rebooted.

Avoid the above timing issue by stopping the timer before rebooting.
2022-01-09 19:28:07 +02:00
Jelle van der Waa
3d079f7952
tasks: skip reboot when borg-backup{,-offsite} is running 2022-01-02 19:29:27 +01:00
Evangelos Foutras
69994e900a
Complete rsync.net account migration
New username; separate and longer account manager + storage passwords.

Also, have to use --remote-path=borg1 when interacting with rsync.net.
2021-11-06 19:50:31 +02:00
Evangelos Foutras
312738318e
Update pacman website to 6.0.1 and switch to meson
Also adjust indentation and make the uploaded files owned by nobody.
2021-09-10 11:20:12 +03:00
Evangelos Foutras
5ff9037832
Do not reboot gemini if there are logged on users
This is done to avoid killing db-update and related processes.
2021-08-23 21:15:49 +03:00
Evangelos Foutras
4986190a69
Skip rebooting if package builds are running 2021-08-23 21:15:49 +03:00
Evangelos Foutras
485e26bb53
Wait for svntogit before rebooting after upgrade 2021-08-22 19:46:40 +03:00
Evangelos Foutras
19084fe336
Abort the play if any hosts fail to upgrade 2021-08-22 19:46:40 +03:00
Evangelos Foutras
7605e7ee78
Use serial = 1 for servers without rescue shell 2021-08-22 19:46:39 +03:00
Evangelos Foutras
871f9a208e
Do rolling upgrades in batches of 20% 2021-08-22 19:46:39 +03:00
Evangelos Foutras
55199ad75a
Update archlinux-keyring before full system upgrade 2021-08-22 19:46:39 +03:00
Evangelos Foutras
0bc7a762bf
upgrade-servers: Don't reboot if no upgrades occurred 2021-08-22 19:46:39 +03:00
Evangelos Foutras
ad14ad7db8
Add simple playbook task for upgrading servers
We want to treat our servers as cattle; hopefully when this is fleshed
out a bit more, it can accomplish the job without too many casualties.
2021-08-22 19:46:39 +03:00
Sven-Hendrik Haase
47d4f0801f
install_arch: Update bootstrap_version to 2021.04.01 2021-04-30 18:52:34 +02:00
Sven-Hendrik Haase
a2ca65b5aa
Bump pacman version 2021-03-19 13:51:46 +01:00
Kristian Klausen
4112bdf9fd Make ansible-lint happy
yaml: truthy value should be one of [false, true] (truthy)
yaml: wrong indentation: expected 4 but found 2 (indentation)
yaml: too few spaces before comment (comments)
yaml: missing starting space in comment (comments)
yaml: too many blank lines (1 > 0) (empty-lines)
yaml: too many spaces after colon (colons)
yaml: comment not indented like content (comments-indentation)
yaml: no new line character at the end of file (new-line-at-end-of-file)
load-failure: Failed to load or parse file
parser-error: couldn't resolve module/action 'hosts'. This often indicates a misspelling, missing collection, or incorrect module path.
2021-02-14 14:22:05 +01:00
Sven-Hendrik Haase
aed624bbcb
Upgrade to current bootstrap image 2021-01-10 22:59:37 +01:00
Giancarlo Razzolini
48b3687031 plabooks: Change the archweb db variable to point to archlinux.org
Change the archweb_db_host variable to point to archlinux.org instead of
apollo. This is of particular importance to gemini.
2020-12-20 11:21:31 +00:00
Jakub Klinkovský
13b5367d33
Set LC_COLLATE for the ssh-keyscan command
Just in case, locales are complicated...
2020-10-26 22:22:41 +01:00
Jakub Klinkovský
592d18964f
Fix non-deterministic behavior of sync-ssh-hostkeys.yml
Fixes #196
2020-10-26 21:47:32 +01:00
Sven-Hendrik Haase
c3e96a35a6
fetch-borg-keys: Remove mode=preserve flag
It's not even implemented for file.
2020-10-22 21:44:28 +02:00
Sven-Hendrik Haase
26f4f08dcc
Update hostkeys
We forget doing this too often. :(
2020-10-22 19:52:05 +02:00
Sven-Hendrik Haase
6cf9fe317d
Upgrade bootstrap image version 2020-10-12 19:30:20 +02:00
Sven-Hendrik Haase
d68771ea7a
Fix for ansible 2.10 (fixes #149) 2020-09-23 22:22:34 +02:00
Frederik Schwan
63887d3b09 fix E208 'File permissions not mentioned' 2020-08-27 05:29:00 +00:00