Browse Source
Changes to ci
Changes to ci
instead of docker layer caching, build binary in runner itself and copy binary to dockerfile old Dockerfile is now build.Dockerfile whereas new one is ci.Dockerfile caching docker layers was taking more time than building the image from scratch add powerpc build (for the 100th time) but without cross in it's own jobdevel
Rohan Sircar
3 years ago
5 changed files with 85 additions and 35 deletions
-
90.github/workflows/ci.yml
-
0build.Dockerfile
-
0build.Dockerfile.dockerignore
-
27ci.Dockerfile
-
3ci.Dockerfile.dockerignore
@ -0,0 +1,27 @@ |
|||
FROM debian:buster-slim |
|||
ARG APP=/usr/src/app |
|||
|
|||
RUN apt-get update \ |
|||
&& apt-get install -y ca-certificates tzdata \ |
|||
&& rm -rf /var/lib/apt/lists/* |
|||
|
|||
EXPOSE 8000 |
|||
|
|||
ENV TZ=Etc/UTC \ |
|||
APP_USER=appuser |
|||
|
|||
RUN groupadd $APP_USER \ |
|||
&& useradd -g $APP_USER $APP_USER \ |
|||
&& mkdir -p ${APP} |
|||
|
|||
COPY ./.env ${APP}/.env |
|||
COPY ./migrations ${APP}/migrations |
|||
COPY ./static ${APP}/static |
|||
COPY ./db/empty.db ${APP}/app.db |
|||
COPY ./target/release/actix-demo ${APP}/actix-demo |
|||
|
|||
RUN chown -R $APP_USER:$APP_USER ${APP} |
|||
|
|||
USER $APP_USER |
|||
WORKDIR ${APP} |
|||
CMD ["./actix-demo"] |
@ -0,0 +1,3 @@ |
|||
.git |
|||
.idea |
|||
.vscode |
Write
Preview
Loading…
Cancel
Save
Reference in new issue