-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathpackages.yml
More file actions
163 lines (146 loc) · 4.85 KB
/
packages.yml
File metadata and controls
163 lines (146 loc) · 4.85 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
- name: Update and Install packages
hosts: localhost
vars:
# This is required for the RPMFusion repository URLs.
fedora_version: 42
tasks:
- name: Install rpmfusion repos
become: True
package:
name: "{{ item }}"
state: present
disable_gpg_check: true
with_items:
- http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-{{ fedora_version }}.noarch.rpm
- http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-{{ fedora_version }}.noarch.rpm
- name: Import Microsoft GPG key for VS Code
become: True
ansible.builtin.rpm_key:
state: present
key: https://packages.microsoft.com/keys/microsoft.asc
- name: Add Visual Studio Code repository
become: True
ansible.builtin.yum_repository:
name: vscode
description: Visual Studio Code
baseurl: https://packages.microsoft.com/yumrepos/vscode
enabled: true
gpgcheck: true
gpgkey: https://packages.microsoft.com/keys/microsoft.asc
- name: Install Visual Studio Code
become: True
tags: dev
package:
name: code
state: present
update_cache: yes # Ensure package cache is updated after adding the repo
- name: Install Cursor from official RPM
become: True
tags: dev
ansible.builtin.dnf:
name: "https://api2.cursor.sh/updates/download/golden/linux-x64-rpm/cursor/2.0"
state: present
disable_gpg_check: yes
- name: "Install basic packages"
become: True
package:
name: "{{ item }}"
state: present
with_items:
- bzip2
- curl
- readline-devel
- redhat-rpm-config
- zlib-devel
- rubygems
- fuse-encfs
- chromium
- python3-devel
- python3-libselinux
- NetworkManager-openvpn
- NetworkManager-openvpn-gnome
- name: "Install productivity tools"
become: True
tags: productivity
package:
name: "{{ item }}"
state: present
with_items:
- task
- the_silver_searcher
- tmux
- tree
- terminator
- keepassxc
- powerline
- powerline-fonts
- name: "Install dev packages"
become: True
tags: dev
package:
name: "{{ item }}"
state: present
with_items:
- vim
- git
- python-xdot
- python3-libselinux
- ruby-devel
- rubygems
- libyaml-devel
- gcc-c++
- make
- tox
- gedit
- name: "Install media related packages"
become: True
tags: media
package:
name: "{{ item }}"
state: present
with_items:
- vlc
- gimp
- name: "Install tmuxinator with ruby gem"
become: True
shell: gem install tmuxinator
# --- New tasks for nvm, node, and gemini-cli ---
- name: Install nvm (Node Version Manager)
tags: dev
become: false # Run as the current user, not root
shell: 'curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.7/install.sh | bash'
args:
# This makes the task idempotent; it won't run if nvm is already installed.
creates: "{{ ansible_env.HOME }}/.nvm/nvm.sh"
- name: Install latest node.js with nvm and set as default
tags: dev
become: false # Run as the current user
shell: '. {{ ansible_env.HOME }}/.nvm/nvm.sh && nvm install node && nvm alias default node'
args:
# This task won't run if a default node version is already set.
creates: "{{ ansible_env.HOME }}/.nvm/alias/default"
- name: Check if gemini-cli is already installed
tags: dev
become: false # Run as the current user
shell: '. {{ ansible_env.HOME }}/.nvm/nvm.sh && npm list -g @google/gemini-cli'
register: gemini_cli_check
changed_when: false # This task doesn't change anything
failed_when: false # Don't fail the playbook if the package isn't found
- name: Install gemini-cli with npm
tags: dev
become: false # Run as the current user
shell: '. {{ ansible_env.HOME }}/.nvm/nvm.sh && npm install -g @google/gemini-cli'
# Only run this task if the gemini-cli was not found in the previous step.
when: gemini_cli_check.rc != 0
- name: Install Dropbox package from official RPM
become: True
ansible.builtin.dnf:
name: "https://www.dropbox.com/download?dl=packages/fedora/nautilus-dropbox-2025.05.20-1.fc{{ fedora_version }}.x86_64.rpm"
state: present
disable_gpg_check: yes
- name: Download Dropbox CLI script
become: false # Run as the current user
ansible.builtin.get_url:
url: https://linux.dropbox.com/packages/dropbox.py
dest: "{{ ansible_env.HOME }}/dropbox.py"
mode: '0755'