1
0
Fork 0
mirror of https://github.com/portainer/portainer.git synced 2025-08-05 13:55:21 +02:00

feat(dockerfile): layered images [EE-4879] (#8301)

* multistage build to target production and storybook

* missing slash

* add storybook for windows too and build targets

* feature flag the storybook api

* remove kompose and prep for new FF lib

* todo comment for FF

* update to new feature flags library

* simplify logic

* fix compilation error

* simplified it
This commit is contained in:
Matt Hook 2023-02-13 11:28:32 +13:00 committed by GitHub
parent 58d66d3142
commit b2105f3614
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 60 additions and 24 deletions

View file

@ -5,10 +5,10 @@ ENV GIT_VERSION 2.30.0
ENV GIT_PATCH_VERSION 2
RUN mkdir mingit/ \
&& wget https://github.com/git-for-windows/git/releases/download/v$GIT_VERSION.windows.$GIT_PATCH_VERSION/MinGit-$GIT_VERSION.$GIT_PATCH_VERSION-busybox-64-bit.zip \
&& unzip MinGit-$GIT_VERSION.$GIT_PATCH_VERSION-busybox-64-bit.zip -d mingit/
&& wget https://github.com/git-for-windows/git/releases/download/v$GIT_VERSION.windows.$GIT_PATCH_VERSION/MinGit-$GIT_VERSION.$GIT_PATCH_VERSION-busybox-64-bit.zip \
&& unzip MinGit-$GIT_VERSION.$GIT_PATCH_VERSION-busybox-64-bit.zip -d mingit/
FROM mcr.microsoft.com/windows/nanoserver:${OSVERSION}
FROM mcr.microsoft.com/windows/nanoserver:${OSVERSION} as production
ENV PATH "C:\mingit\cmd;C:\Windows\system32;C:\Windows;"
COPY --from=downloader /mingit mingit/
@ -16,7 +16,16 @@ COPY --from=core /Windows/System32/netapi32.dll /Windows/System32/netapi32.dll
USER ContainerAdministrator
COPY dist /
COPY dist/docker.exe /
COPY dist/docker-compose.exe /
COPY dist/helm.exe /
COPY dist/kubectl.exe /
COPY dist/mustache-templates /mustache-templates/
COPY dist/portainer.exe /
COPY dist/public /public/
# storybook exists only in portainerci builds
COPY dist/storybook* /storybook/
EXPOSE 9000
EXPOSE 9443