Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ubuntu 20.04 as a base image for CVAT Dockerfile #2101

Merged
merged 6 commits into from
Sep 2, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

### Changed
- UI models (like DEXTR) were redesigned to be more interactive (<https://github.com/opencv/cvat/pull/2054>)
- Used Ubuntu:20.04 as a base image for CVAT Dockerfile (<https://github.com/opencv/cvat/pull/2101>)

### Deprecated
-
Expand Down
15 changes: 2 additions & 13 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,25 +14,14 @@ Next steps should work on clear Ubuntu 18.04.

- Install necessary dependencies:
```sh
sudo apt-get update && sudo apt-get --no-install-recommends install -y ffmpeg build-essential curl redis-server python3-dev python3-pip python3-venv python3-tk libldap2-dev libsasl2-dev
sudo apt-get update && sudo apt-get --no-install-recommends install -y build-essential curl redis-server python3-dev python3-pip python3-venv python3-tk libldap2-dev libsasl2-dev pkg-config libavformat-dev libavcodec-dev libavdevice-dev libavutil-dev libswscale-dev libswresample-dev libavfilter-dev
```
Also please make sure that you have installed ffmpeg with all necessary libav* libraries and pkg-config package.
Please make sure you have installed FFmpeg libraries (libav*) version 4.0 or higher.
```sh
# Node and npm (you can use default versions of these packages from apt (8.*, 3.*), but we would recommend to use newer versions)
curl -sL https://deb.nodesource.com/setup_12.x | sudo -E bash -
sudo apt-get install -y nodejs

# General dependencies
sudo apt-get install -y pkg-config

# Library components
sudo apt-get install -y \
libavformat-dev libavcodec-dev libavdevice-dev \
libavutil-dev libswscale-dev libswresample-dev libavfilter-dev
```
See [PyAV Dependencies installation guide](http://docs.mikeboers.com/pyav/develop/overview/installation.html#dependencies)
for details.

- Install [Visual Studio Code](https://code.visualstudio.com/docs/setup/linux#_debian-and-ubuntu-based-distributions)
for development

Expand Down
25 changes: 9 additions & 16 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:16.04
FROM ubuntu:20.04

ARG http_proxy
ARG https_proxy
Expand All @@ -23,8 +23,6 @@ ENV DJANGO_CONFIGURATION=${DJANGO_CONFIGURATION}
RUN apt-get update && \
apt-get --no-install-recommends install -yq \
software-properties-common && \
add-apt-repository ppa:mc3man/xerus-media -y && \
add-apt-repository ppa:mc3man/gstffmpeg-keep -y && \
apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get --no-install-recommends install -yq \
apache2 \
Expand All @@ -33,15 +31,13 @@ RUN apt-get update && \
build-essential \
libapache2-mod-xsendfile \
supervisor \
ffmpeg \
gstreamer0.10-ffmpeg \
libavcodec-dev \
libavdevice-dev \
libavfilter-dev \
libavformat-dev \
libavutil-dev \
libswresample-dev \
libswscale-dev \
libavcodec-dev=7:4.2.4-1ubuntu0.1 \
libavdevice-dev=7:4.2.4-1ubuntu0.1 \
libavfilter-dev=7:4.2.4-1ubuntu0.1 \
libavformat-dev=7:4.2.4-1ubuntu0.1 \
libavutil-dev=7:4.2.4-1ubuntu0.1 \
libswresample-dev=7:4.2.4-1ubuntu0.1 \
libswscale-dev=7:4.2.4-1ubuntu0.1 \
libldap2-dev \
libsasl2-dev \
pkg-config \
Expand All @@ -50,16 +46,13 @@ RUN apt-get update && \
tzdata \
p7zip-full \
git \
git-lfs \
ssh \
poppler-utils \
curl && \
curl https://packagecloud.io/install/repositories/github/git-lfs/script.deb.sh | bash && \
apt-get --no-install-recommends install -y git-lfs && git lfs install && \
python3 -m pip install --no-cache-dir -U pip==20.0.1 setuptools==49.6.0 wheel==0.35.1 && \
ln -fs /usr/share/zoneinfo/${TZ} /etc/localtime && \
dpkg-reconfigure -f noninteractive tzdata && \
add-apt-repository --remove ppa:mc3man/gstffmpeg-keep -y && \
add-apt-repository --remove ppa:mc3man/xerus-media -y && \
rm -rf /var/lib/apt/lists/* && \
echo 'application/wasm wasm' >> /etc/mime.types

Expand Down
15 changes: 9 additions & 6 deletions Dockerfile.ci
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,20 @@ FROM cvat/server
ENV DJANGO_CONFIGURATION=testing
USER root

RUN curl https://dl-ssl.google.com/linux/linux_signing_key.pub | apt-key add - && \
echo 'deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main' | tee /etc/apt/sources.list.d/google-chrome.list && \
curl https://deb.nodesource.com/setup_12.x | bash - && \
apt-get update && \
RUN apt-get update && \
DEBIAN_FRONTEND=noninteractive apt-get --no-install-recommends install -yq \
gpg-agent \
apt-utils \
build-essential \
python3-dev \
ruby \
&& \
curl https://dl-ssl.google.com/linux/linux_signing_key.pub | apt-key add - && \
echo 'deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main' | tee /etc/apt/sources.list.d/google-chrome.list && \
curl https://deb.nodesource.com/setup_12.x | bash - && \
DEBIAN_FRONTEND=noninteractive apt-get --no-install-recommends install -yq \
google-chrome-stable \
nodejs \
python3-dev \
ruby \
&& \
rm -rf /var/lib/apt/lists/*;

Expand Down
10 changes: 2 additions & 8 deletions cvat/requirements/base.txt
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ rjsmin==1.1.0
requests==2.24.0
rq==1.5.1
rq-scheduler==0.10.0
scipy==1.4.1
sqlparse==0.3.1
django-sendfile==0.3.11
dj-pagination==2.5.0
Expand All @@ -34,19 +33,14 @@ Pygments==2.6.1
drf-yasg==1.17.1
Shapely==1.7.1
pdf2image==1.14.0
pascal_voc_writer==0.1.4
django-rest-auth[with_social]==0.9.5
cython==0.29.21
matplotlib==3.0.3
scikit-image==0.15.0
tensorflow==2.2.0
keras==2.4.2
opencv-python==4.4.0.42
h5py==2.10.0
imgaug==0.4.0
django-cors-headers==3.5.0
furl==2.1.0
av==6.2.0
av==8.0.2 --no-binary=av
tensorflow==2.2.0 # Optional requirement of Datumaro
# The package is used by pyunpack as a command line tool to support multiple
# archives. Don't use as a python module because it has GPL license.
patool==1.12
2 changes: 1 addition & 1 deletion datumaro/requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Cython>=0.27.3 # include before pycocotools
defusedxml>=0.6.0
GitPython>=3.0.8
lxml>=4.4.1
matplotlib<3.1 # 3.1+ requires python3.6, but we have 3.5 in cvat
matplotlib>=3.3.1
opencv-python-headless>=4.1.0.25
Pillow>=6.1.0
pycocotools>=2.0.0
Expand Down