Commit ccb12a26 authored by Recteur LP's avatar Recteur LP

Drop CentOS 7 support

DEPRECATION: Python 2.7 reached the end of its life on January 1st, 2020
parent 450d63be
Pipeline #1614 passed with stages
in 5 minutes and 43 seconds
......@@ -42,19 +42,6 @@ Fedora Build & Release:
- master
- tags
CentOS 7 Docker Build & Release:
stage: build
tags:
- buildah
script:
- make build27 CI_COMMIT_TAG=${CI_COMMIT_TAG:-latest}
- buildah push --authfile ~/.auth.json docker.io/pyrmin/pyrmin:27-${CI_COMMIT_TAG:-latest}
after_script:
- buildah rmi -p
only:
- master
- tags
CentOS 8 Docker Build & Release:
stage: build
tags:
......
......@@ -9,8 +9,7 @@ endif
help:
@echo "Please use \`make <target>' where <target> is one of"
@echo "If you are behind a proxy set your HTTP_PROXY env variable"
@echo " build build container Images for Fedora 32"
@echo " build27 build container Images for CentOS 7"
@echo " build build container Images for Fedora 33"
@echo " build-el8 build container Images for CentOS 8"
@echo " test-build build container Testing Images"
@echo " goss Run Podman Goss Test"
......@@ -29,10 +28,6 @@ build: vendor auto-proxy
@buildah bud --pull --no-cache --format docker -f container/pyrmin.container -v $(shell pwd):/opt/tmp -t docker.io/pyrmin/pyrmin
@buildah tag docker.io/pyrmin/pyrmin docker.io/pyrmin/pyrmin:$(CI_COMMIT_TAG)
build27: vendor auto-proxy
@buildah bud --pull --no-cache --format docker -f container/python2/pyrmin.container -v $(shell pwd):/opt/tmp -t docker.io/pyrmin/pyrmin:27-latest
@buildah tag docker.io/pyrmin/pyrmin:27-latest docker.io/pyrmin/pyrmin:27-$(CI_COMMIT_TAG)
build-el8: vendor auto-proxy
@buildah bud --pull --no-cache --format docker -f container/el8/pyrmin.container -v $(shell pwd):/opt/tmp -t docker.io/pyrmin/pyrmin:el8-latest
@buildah tag docker.io/pyrmin/pyrmin:el8-latest docker.io/pyrmin/pyrmin:el8-$(CI_COMMIT_TAG)
......
FROM centos:7
MAINTAINER pyrmin.io <support@pyrmin.io>
RUN yum -v -y install \
epel-release \
python-pip \
python-virtualenv \
PyYAML \
python-setuptools \
python2-createrepo_c \
python2-psutil \
python2-lxml \
git \
gcc \
rsync \
python-devel \
libyaml-devel \
redhat-rpm-config \
&& useradd pyrmin \
&& mkdir -p /etc/pyrmin/plugins /usr/share/pyrmin/plugins /var/log/pyrmin /static \
&& python2 -m virtualenv --system-site-packages /opt/pyrmin && source /opt/pyrmin/bin/activate \
&& cd /opt/tmp/ \
&& pip install -U setuptools pip \
&& pip install more-itertools==5.0.0 \
&& pip install "MarkupSafe<2.0.0" \
&& python2 setup.py install \
&& cd /opt \
&& cp /opt/tmp/conf/pyrmin.yml.default /etc/pyrmin/pyrmin.yml \
&& cp /opt/tmp/container/entrypoint.sh /entrypoint.sh \
&& chmod +rx /entrypoint.sh \
&& chown -R pyrmin /etc/pyrmin /usr/share/pyrmin/plugins /var/log/pyrmin /opt/pyrmin /static \
&& yum clean all \
&& rm -rf /usr/share/doc /usr/share/man /tmp/*
USER pyrmin
WORKDIR /var/log/pyrmin
EXPOSE 8080
VOLUME [ "/etc/pyrmin/plugins", "/usr/share/pyrmin/plugins", "/static" ]
CMD [ "/entrypoint.sh" ]
apiVersion: v1
kind: Pod
metadata:
name: pyrmin
spec:
securityContext:
runAsUser: 1000
fsGroup: 1000
volumes:
- name: config
hostPath:
path: /etc/pyrmin
type: Directory
- name: plugins
hostPath:
path: /usr/share/pyrmin/plugins
type: Directory
- name: static
hostPath:
path: /var/www/html/public
type: Directory
containers:
- name: pyrmin
image: docker.io/pyrmin/pyrmin:27-latest
volumeMounts:
- name: config
mountPath: /etc/pyrmin
- name: plugins
mountPath: /usr/share/pyrmin/plugins
- name: static
mountPath: /static
ports:
- containerPort: 8000
hostPort: 8000
protocol: TCP
env:
- name: UPGRADE
value: true
- name: DEBUG
value: true
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment