From 0ef5a1c943e4c13f9fb342276ecf4e57dd7c92f3 Mon Sep 17 00:00:00 2001 From: Yoshiki Obinata Date: Sat, 20 Jul 2024 12:01:35 +0900 Subject: [PATCH] initial commit for noble --- .github/workflows/sudoer.yml | 2 ++ roles/emacs/tasks/main.yml | 8 ++++++++ test/docker/ubuntu-noble.Dockerfile | 29 +++++++++++++++++++++++++++++ 3 files changed, 39 insertions(+) create mode 100644 test/docker/ubuntu-noble.Dockerfile diff --git a/.github/workflows/sudoer.yml b/.github/workflows/sudoer.yml index e6729d7..7ed3571 100644 --- a/.github/workflows/sudoer.yml +++ b/.github/workflows/sudoer.yml @@ -23,6 +23,8 @@ jobs: CODENAME: focal - OS: ubuntu CODENAME: jammy + - OS: ubuntu + CODENAME: noble steps: - name: Free disk space run: | diff --git a/roles/emacs/tasks/main.yml b/roles/emacs/tasks/main.yml index c92c8b6..8a413b1 100644 --- a/roles/emacs/tasks/main.yml +++ b/roles/emacs/tasks/main.yml @@ -28,6 +28,13 @@ environment: PIP_BREAK_SYSTEM_PACKAGES: 1 +- name: Install common packages for emacs29 in Ubuntu noble + apt: + name: ['libgccjit-13-dev'] + state: present + become: yes + when: ansible_facts['distribution'] == "Ubuntu" and ansible_facts['distribution_major_version'] == "24" + - name: Install common packages for emacs29 in Debian bookworm apt: name: ['libgccjit-12-dev'] @@ -102,6 +109,7 @@ state: present filename: llvm-toolchain become: true + when: not (ansible_facts['distribution'] == "Ubuntu" and ansible_facts['distribution_major_version'] == "24") - name: Install clang tools apt: diff --git a/test/docker/ubuntu-noble.Dockerfile b/test/docker/ubuntu-noble.Dockerfile new file mode 100644 index 0000000..6982426 --- /dev/null +++ b/test/docker/ubuntu-noble.Dockerfile @@ -0,0 +1,29 @@ +FROM ubuntu:noble + +ENV DEBIAN_FRONTEND=noninteractive + +# For manage user +RUN apt update -qq && \ + apt upgrade -y -qq && \ + apt install -y -qq --no-install-recommends sudo software-properties-common + +# install prerequisites +RUN apt install -y -qq --no-install-recommends \ + git \ + ansible + +# Add non root user +ARG USERNAME=user +ARG PASSWORD=user +ARG GROUPNAME=user +ARG UID=1000 +ARG GID=1000 +RUN groupadd -g $GID $GROUPNAME && \ + useradd -m -s /bin/bash -u $UID -g $GID -G sudo $USERNAME && \ + echo $USERNAME:$PASSWORD | chpasswd && \ + echo "$USERNAME ALL=(ALL) NOPASSWD:ALL" >> /etc/sudoers +USER $USERNAME + +WORKDIR /home/$USERNAME/dotfiles +COPY ./ . +RUN ./test/docker/run_deb \ No newline at end of file