forked from nikhilm/qhttpserver
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathDockerfile-debian12
24 lines (19 loc) · 1.1 KB
/
Dockerfile-debian12
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
FROM debian:12
ARG TRAVIS_JOB_NUMBER
ENV DEBIAN_FRONTEND=noninteractive
# Setup
RUN apt-get update -y -qq && apt-get install -y apt-utils wget bzip2 git gcc g++ cmake cmake-data ninja-build qt6-base-dev-tools qt6-declarative-dev packaging-dev -qq
RUN mkdir -p /src/
COPY . /src/qhttpserver
RUN mkdir -p /src/qhttpserver/build
# Build
WORKDIR /src/qhttpserver/build
RUN cmake -G Ninja -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=Release ..
RUN ninja all && ninja package
RUN echo "export packagefile=`find /src/qhttpserver/build/ -maxdepth 1 -name *.deb`" > /envfile
RUN echo "export fullname=\$(basename -- \$packagefile)" >> /envfile
RUN echo "export extension=\${fullname##*.}" >> /envfile
RUN echo "export filename=\${fullname%.*}" >> /envfile
RUN . /envfile && install -D ${packagefile} "/usr/share/apps/qhttpserver/packages/${filename}-debian12r.deb"
## install github-release to be able to deploy packages
#RUN wget https://github.com/aktau/github-release/releases/download/v0.7.2/linux-amd64-github-release.tar.bz2 && tar xjf linux-amd64-github-release.tar.bz2 && cp bin/linux/amd64/github-release /usr/bin