forked from acouzens/open5gs
[build] Use local sources to build applications (#1583)
"build" Docker image previously downloaded latest version of Open5GS from github, and built the project from that. Use local source files for building instead.
This commit is contained in:
parent
0f93ec23ab
commit
d2cbcf7118
|
@ -0,0 +1,10 @@
|
||||||
|
**/*.md
|
||||||
|
**/docker-compose*.yml
|
||||||
|
**/docker-compose*.yaml
|
||||||
|
**/Dockerfile*
|
||||||
|
.git
|
||||||
|
.dockerignore
|
||||||
|
.cache
|
||||||
|
.gitignore
|
||||||
|
.github
|
||||||
|
build
|
|
@ -5,15 +5,8 @@ FROM ${username}/${dist}-${tag}-open5gs-base
|
||||||
|
|
||||||
MAINTAINER Sukchan Lee <acetcom@gmail.com>
|
MAINTAINER Sukchan Lee <acetcom@gmail.com>
|
||||||
|
|
||||||
WORKDIR /root
|
WORKDIR /open5gs
|
||||||
COPY setup.sh /root
|
COPY docker/build/setup.sh /root
|
||||||
|
COPY ./ /open5gs
|
||||||
|
|
||||||
ARG USER=open5gs
|
RUN meson build && ninja -C build install
|
||||||
ARG REPO=open5gs
|
|
||||||
ARG BRANCH=main
|
|
||||||
RUN git clone https://github.com/$USER/$REPO
|
|
||||||
ADD https://api.github.com/repos/$USER/$REPO/git/refs/heads/$BRANCH /root/open5gs-ver.json
|
|
||||||
|
|
||||||
RUN cd $REPO && \
|
|
||||||
git fetch && git checkout -f -B $BRANCH origin/$BRANCH && \
|
|
||||||
meson build && ninja -C build install
|
|
||||||
|
|
|
@ -33,7 +33,8 @@ services:
|
||||||
|
|
||||||
build:
|
build:
|
||||||
build:
|
build:
|
||||||
context: ./build
|
context: ../
|
||||||
|
dockerfile: docker/build/Dockerfile
|
||||||
args:
|
args:
|
||||||
dist: ${DIST-ubuntu}
|
dist: ${DIST-ubuntu}
|
||||||
tag: ${TAG-latest}
|
tag: ${TAG-latest}
|
||||||
|
|
Loading…
Reference in New Issue