Skip to content

Commit 63d952e

Browse files
committed
Update docker files
1 parent a03fa6d commit 63d952e

File tree

3 files changed

+16
-3
lines changed

3 files changed

+16
-3
lines changed
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
11
# Ignore build artifacts
22
bin/
33
obj/
4+
out/
5+
nupkg/
6+
artifacts/

docker/Dockerfile

+12-3
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,21 @@ FROM ${BASE_IMAGE} AS build
55

66
WORKDIR /app
77

8+
COPY *.props .
89
COPY NuGet.Config .
9-
COPY src/Cli/func .
1010
COPY tools/ tools/
11+
COPY eng/*.props eng/
12+
COPY src/*.props src/
13+
COPY src/Cli/func src/Cli/func
14+
COPY AzureFunctions-CLI.ico .
15+
COPY eng/scripts/download-templates.sh .
1116

1217
ARG TARGET_RUNTIME=linux-x64
13-
RUN dotnet publish /p:BuildNumber="9999" /p:CommitHash="N/A" -o /cli -c Release -f net8.0 --self-contained -r ${TARGET_RUNTIME}
18+
RUN dotnet publish src/Cli/func /p:BuildNumber="9999" /p:CommitHash="N/A" -o /cli -c Release -f net8.0 --self-contained -r ${TARGET_RUNTIME}
1419

15-
FROM ${RUNTIME_IMAGE} AS runtime
20+
RUN bash ./download-templates.sh --output /cli
21+
22+
FROM ${BASE_IMAGE} AS runtime
1623

1724
WORKDIR /cli
1825

@@ -21,5 +28,7 @@ COPY --from=build /cli .
2128
# Add cli to path so it can be run from anywhere
2229
ENV PATH="$PATH:/cli"
2330

31+
WORKDIR /playground
32+
2433
# Run forever
2534
ENTRYPOINT ["tail", "-f", "/dev/null"]

docker/docker-compose.yml

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
# Run: docker-compose up --build -d && docker exec -it func-cli bash
12
services:
23
func-cli:
34
build:

0 commit comments

Comments
 (0)