diff --git a/.circleci/config.yml b/.circleci/config.yml index a6165ec..dd2e794 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -26,7 +26,7 @@ jobs: name: Install QEMU command: | sudo apt update - sudo apt install qemu-user-static -y + sudo apt install qemu-user-static binfmt-support -y # build - run: name: Build Docker Base Images @@ -59,3 +59,4 @@ workflows: - ubuntu-18.04 - ubuntu-20.04 - ubuntu-22.04 + - ubuntu-24.04 diff --git a/README.md b/README.md index 6ca3d38..544e522 100644 --- a/README.md +++ b/README.md @@ -18,6 +18,7 @@ The intended use of the Vagrant-friendly docker base images is to use them as a The following baseboxes are currently published on [Vagrant Cloud](https://app.vagrantup.com/boxes/search): + * [`tknerr/baseimage-ubuntu-24.04`](https://app.vagrantup.com/tknerr/boxes/baseimage-ubuntu-24.04) * [`tknerr/baseimage-ubuntu-22.04`](https://app.vagrantup.com/tknerr/boxes/baseimage-ubuntu-22.04) * [`tknerr/baseimage-ubuntu-20.04`](https://app.vagrantup.com/tknerr/boxes/baseimage-ubuntu-20.04) * [`tknerr/baseimage-ubuntu-18.04`](https://app.vagrantup.com/tknerr/boxes/baseimage-ubuntu-18.04) diff --git a/Rakefile b/Rakefile index 391ab4a..bf40496 100644 --- a/Rakefile +++ b/Rakefile @@ -2,7 +2,7 @@ require 'rubygems/package' ALL_PLATFORMS = { - ubuntu: [ "14.04", "16.04", "18.04", "20.04", "22.04"] + ubuntu: [ "14.04", "16.04", "18.04", "20.04", "22.04", "24.04"] } TARGET_ARCHITECTURES = ['amd64', 'arm64'] diff --git a/ubuntu-2404/Dockerfile b/ubuntu-2404/Dockerfile new file mode 100644 index 0000000..c366563 --- /dev/null +++ b/ubuntu-2404/Dockerfile @@ -0,0 +1,45 @@ +FROM ubuntu:24.04 + +ENV DEBIAN_FRONTEND noninteractive + +# install common dependencies +RUN apt-get update && apt-get install -y \ + locales \ + curl \ + lsb-release \ + openssh-server \ + sudo \ + python3 + +# ensure we have the en_US.UTF-8 locale available +RUN locale-gen en_US.UTF-8 + +# setup the vagrant user +RUN if ! getent passwd vagrant; then useradd -d /home/vagrant -m -s /bin/bash vagrant; fi \ + && echo vagrant:vagrant | chpasswd \ + && echo 'vagrant ALL=(ALL) NOPASSWD:ALL' >> /etc/sudoers \ + && mkdir -p /etc/sudoers.d \ + && echo 'vagrant ALL=(ALL) NOPASSWD:ALL' >> /etc/sudoers.d/vagrant \ + && chmod 0440 /etc/sudoers.d/vagrant + +# add the vagrant insecure public key +RUN mkdir -p /home/vagrant/.ssh \ + && chmod 0700 /home/vagrant/.ssh \ + && wget --no-check-certificate \ + https://raw.githubusercontent.com/mitchellh/vagrant/master/keys/vagrant.pub \ + -O /home/vagrant/.ssh/authorized_keys \ + && chmod 0600 /home/vagrant/.ssh/authorized_keys \ + && chown -R vagrant /home/vagrant/.ssh + +# don't clean packages, we might be using vagrant-cachier +RUN rm /etc/apt/apt.conf.d/docker-clean + +# create the privilege separation directory for sshd +RUN mkdir -p /run/sshd + +# run sshd in the foreground +CMD /usr/sbin/sshd -D \ + -o UseDNS=no\ + -o UsePAM=no\ + -o PasswordAuthentication=yes\ + -o PidFile=/tmp/sshd.pid \ No newline at end of file