Merge branch 'nginx-unpriviledged' into chore/all-my-stuffs

This commit is contained in:
ShareVB committed 2025-02-23 13:16:21 +01:00
commit a30b74780d
3 files changed
+12 -8

No files matched your search

+2 -2
View File
@@ -16,10 +16,10 @@ ENV BASE_URL=${BASE_URL}
RUN pnpm build
# production stage
FROM nginx:stable-alpine AS production-stage
FROM nginxinc/nginx-unprivileged:stable-alpine AS production-stage
ARG BASE_URL
ENV BASE_URL=${BASE_URL}
COPY --from=build-stage /app/dist /usr/share/nginx/html
COPY nginx.conf /etc/nginx/conf.d/default.conf
EXPOSE 80
EXPOSE 8080
CMD ["nginx", "-g", "daemon off;"]
+8 -4
View File
@@ -1,3 +1,7 @@
## BREAKING CHANGE for Docker Image
Since *Docker base image* is now `nginx-unpriviledged`, docker image now listen to **8080** and no more 80. So you need to update your port mapping, ie from `8080:80` to `8080:8080`.
### Check out these change here: <https://sharevb-it-tools.vercel.app/>
You can use my image in your docker-compose file if you want an update to date version of it-tools (with my PR and some of others) until the main branch has been updated.
@@ -15,7 +19,7 @@ Almost [all tools PR of it-tools](https://github.com/sharevb/it-tools/pulls).
According to https://github.com/sharevb/it-tools/pull/461#issuecomment-1602506049:
```
docker build -t it-tools --build-arg BASE_URL="/my-folder/" .
docker run -d --name it-tools --restart unless-stopped -p 8080:80 it-tools
docker run -d --name it-tools --restart unless-stopped -p 8080:8080 it-tools
```
## Use in Docker Compose file
@@ -28,7 +32,7 @@ services:
pull_policy: always
restart: unless-stopped
ports:
- 8080:80
- 8080:8080
```
## Installation methods
@@ -62,13 +66,13 @@ Self host solutions for your homelab
**From docker hub:**
```sh
docker run -d --name it-tools --restart unless-stopped -p 8080:80 corentinth/it-tools:latest
docker run -d --name it-tools --restart unless-stopped -p 8080:8080 corentinth/it-tools:latest
```
**From github packages:**
```sh
docker run -d --name it-tools --restart unless-stopped -p 8080:80 ghcr.io/corentinth/it-tools:latest
docker run -d --name it-tools --restart unless-stopped -p 8080:8080 ghcr.io/corentinth/it-tools:latest
```
**Other solutions:**
+2 -2
View File
@@ -1,5 +1,5 @@
server {
listen 80;
listen 8080;
server_name _;
root /usr/share/nginx/html;
index index.html;
@@ -7,4 +7,4 @@ server {
location / {
try_files $uri $uri/ /index.html;
}
}
}