Fix build for debian
This commit is contained in:
parent
549307f93f
commit
498269a7eb
6 changed files with 35 additions and 17 deletions
|
@ -5,9 +5,9 @@ packages:
|
||||||
- iptables
|
- iptables
|
||||||
- coreutils
|
- coreutils
|
||||||
- git
|
- git
|
||||||
- base-devel
|
# - base-devel
|
||||||
- docker
|
- docker
|
||||||
- avahi
|
- avahi-daemon
|
||||||
- nodejs
|
- nodejs
|
||||||
- npm
|
- npm
|
||||||
|
|
||||||
|
|
|
@ -1,8 +1,24 @@
|
||||||
- name: Install docker
|
- name: Install docker
|
||||||
package:
|
package:
|
||||||
name: docker
|
name:
|
||||||
|
- docker
|
||||||
|
- ca-certificates
|
||||||
|
- curl
|
||||||
|
- gnupg
|
||||||
|
- lsb-release
|
||||||
state: latest
|
state: latest
|
||||||
|
|
||||||
|
- name: Add docker gpg key
|
||||||
|
shell: curl -fsSL https://download.docker.com/linux/debian/gpg | sudo gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg
|
||||||
|
|
||||||
|
- name: Add deb
|
||||||
|
shell: echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/debian bullseye stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
|
||||||
|
|
||||||
|
- name: Update packages
|
||||||
|
apt:
|
||||||
|
update_cache: yes
|
||||||
|
upgrade: yes
|
||||||
|
|
||||||
- name: Install essential packages
|
- name: Install essential packages
|
||||||
package:
|
package:
|
||||||
name:
|
name:
|
||||||
|
|
|
@ -1,22 +1,21 @@
|
||||||
- name: Change machine hostname to tipi.local
|
- name: Change machine hostname to tipi.local
|
||||||
shell: hostnamectl set-hostname tipi.local
|
shell: hostnamectl set-hostname tipi.local
|
||||||
|
|
||||||
- name: Update packages
|
# - name: Update packages
|
||||||
become: yes
|
# apt:
|
||||||
pacman:
|
# update_cache: yes
|
||||||
update_cache: yes
|
# upgrade: yes
|
||||||
upgrade: yes
|
|
||||||
|
|
||||||
- name: Add user to root group
|
|
||||||
user:
|
|
||||||
name: "{{ username }}"
|
|
||||||
group: root
|
|
||||||
|
|
||||||
- name: Install essential packages
|
- name: Install essential packages
|
||||||
package:
|
package:
|
||||||
name: "{{ packages }}"
|
name: "{{ packages }}"
|
||||||
state: latest
|
state: latest
|
||||||
|
|
||||||
|
- name: Add user to root group
|
||||||
|
user:
|
||||||
|
name: "{{ username }}"
|
||||||
|
group: root
|
||||||
|
|
||||||
- name: Disable SSH password auth
|
- name: Disable SSH password auth
|
||||||
lineinfile:
|
lineinfile:
|
||||||
dest: /etc/ssh/sshd_config
|
dest: /etc/ssh/sshd_config
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
- name: Install "pm2" package globally.
|
- name: Install "pm2" package globally.
|
||||||
community.general.npm:
|
community.general.npm:
|
||||||
name: yarn
|
name: pm2
|
||||||
global: yes
|
global: yes
|
||||||
|
|
||||||
- name: Run pm2 first time
|
- name: Run pm2 first time
|
||||||
|
|
|
@ -1,3 +1,6 @@
|
||||||
|
#!/usr/bin/env bash
|
||||||
|
set -e # Exit immediately if a command exits with a non-zero status.
|
||||||
|
|
||||||
ROOT_FOLDER="$(readlink -f $(dirname "${BASH_SOURCE[0]}")/..)"
|
ROOT_FOLDER="$(readlink -f $(dirname "${BASH_SOURCE[0]}")/..)"
|
||||||
|
|
||||||
# Constants
|
# Constants
|
||||||
|
@ -33,10 +36,9 @@ ENV_FILE="./templates/.env"
|
||||||
# Install ansible if not installed
|
# Install ansible if not installed
|
||||||
if ! command -v ansible-playbook > /dev/null; then
|
if ! command -v ansible-playbook > /dev/null; then
|
||||||
echo "Installing Ansible..."
|
echo "Installing Ansible..."
|
||||||
sudo apt-get install -y software-properties-common
|
|
||||||
sudo apt-add-repository -y ppa:ansible/ansible
|
|
||||||
sudo apt-get update
|
sudo apt-get update
|
||||||
sudo apt-get install -y ansible
|
sudo apt-get install python3 python3-pip -y
|
||||||
|
sudo pip3 install ansible
|
||||||
fi
|
fi
|
||||||
|
|
||||||
ansible-playbook ansible/setup.yml -i ansible/hosts -K
|
ansible-playbook ansible/setup.yml -i ansible/hosts -K
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
set -e # Exit immediately if a command exits with a non-zero status.
|
||||||
|
|
||||||
# use greadlink instead of readlink on osx
|
# use greadlink instead of readlink on osx
|
||||||
if [[ "$(uname)" == "Darwin" ]]; then
|
if [[ "$(uname)" == "Darwin" ]]; then
|
||||||
|
|
Loading…
Add table
Reference in a new issue