Ubuntu 18.04 support

This commit is contained in:
Sergei Antipov 2018-07-13 18:50:23 -04:00
parent ca9bc78c9f
commit 8cfc47bb7a
4 changed files with 42 additions and 1 deletions

View File

@ -7,6 +7,11 @@ language: python
python:
- "2.7"
env:
- >
DISTRIBUTION=ubuntu
DIST_VERSION=18_04-builded
MONGODB_VERSION=3.6
MONGODB_PACKAGE=mongodb
- >
DISTRIBUTION=ubuntu
DIST_VERSION=16_04-builded

View File

@ -14,6 +14,7 @@ MongoDB support matrix:
| ------------ |:-------------:|:-----------:|:-----------:|:-----------:|
| Ubuntu 14.04 | :no_entry: | :white_check_mark:| :white_check_mark:| :white_check_mark:|
| Ubuntu 16.04 | :no_entry: | :white_check_mark:| :white_check_mark:| :white_check_mark:|
| Ubuntu 18.04 | :no_entry: | :x:| :x:| :white_check_mark:|
| Debian 8.x | :no_entry: | :white_check_mark:| :white_check_mark:| :white_check_mark:|
| Debian 9.x | :no_entry: | :white_check_mark:| :x:| :white_check_mark:|
| RHEL 6.x | :no_entry: | :white_check_mark: | :white_check_mark: | :white_check_mark:|

View File

@ -23,7 +23,13 @@
when: (mongodb_package == 'mongodb-org' and
(mongodb_version is not defined
or mongodb_repository[mongodb_major_version] is not defined
or mongodb_version != "3.6") and ansible_distribution_release == "stretch")
or mongodb_version != '3.6') and ansible_distribution_release == 'stretch')
- name: Fail when used wrong mongodb_version variable with Debian Stretch
fail:
msg: "mongodb_version variable should be '3.6' and mongodb_package should be 'mongodb' for Ubuntu 18.04"
when: ((mongodb_package == 'mongodb-org' or mongodb_version != '3.6')
and ansible_distribution_release == "bionic")
- name: Fail when used wrong mongodb_version variable
fail:

View File

@ -0,0 +1,29 @@
FROM ubuntu:18.04
ARG DEBIAN_FRONTEND=noninteractive
RUN apt update && \
apt install --yes python-minimal systemd gnupg
RUN cd /lib/systemd/system/sysinit.target.wants/ && \
ls | grep -v systemd-tmpfiles-setup.service | xargs rm -f && \
rm -f /lib/systemd/system/sockets.target.wants/*udev* && \
systemctl mask -- \
tmp.mount \
etc-hostname.mount \
etc-hosts.mount \
etc-resolv.conf.mount \
-.mount \
swap.target \
getty.target \
getty-static.service \
dev-mqueue.mount \
cgproxy.service \
systemd-tmpfiles-setup-dev.service \
systemd-remount-fs.service \
systemd-ask-password-wall.path \
systemd-logind.service && \
systemctl set-default multi-user.target || true
RUN sed -ri /etc/systemd/journald.conf \
-e 's!^#?Storage=.*!Storage=volatile!'