Skip to content

Commit ce3331e

Browse files
committed
Manual revert of docker related changes
1 parent e67757f commit ce3331e

File tree

5 files changed

+11
-69
lines changed

5 files changed

+11
-69
lines changed

.github/workflows/docker-publish.yml

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,7 @@ name: Container Image
22

33
on:
44
push:
5-
branches:
6-
- master
7-
- sandhose/oidc-login
5+
branches: [ master ]
86
tags: [ 'v*' ]
97
pull_request:
108
branches: [ master ]
@@ -25,9 +23,6 @@ jobs:
2523
- name: Checkout repository
2624
uses: actions/checkout@v2
2725

28-
- name: Set up Docker Buildx
29-
uses: docker/setup-buildx-action@v1
30-
3126
- name: Log into registry ${{ env.REGISTRY }}
3227
uses: docker/login-action@v1
3328
with:
@@ -40,17 +35,10 @@ jobs:
4035
uses: docker/metadata-action@v3
4136
with:
4237
images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}
43-
tags: |
44-
type=ref,event=branch
45-
type=ref,event=pr
46-
type=semver,pattern={{version}}
47-
type=semver,pattern={{major}}.{{minor}}
48-
type=sha
4938

5039
- name: Build and push Docker image
5140
uses: docker/build-push-action@v2
5241
with:
53-
platforms: linux/amd64,linux/arm64,linux/arm/v7
5442
push: ${{ github.event_name != 'pull_request' }}
5543
tags: ${{ steps.meta.outputs.tags }}
5644
labels: ${{ steps.meta.outputs.labels }}

Dockerfile

Lines changed: 5 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,9 @@
1-
FROM --platform=${BUILDPLATFORM} docker.io/library/node:16.13-alpine3.15 as builder
1+
FROM docker.io/node:alpine as builder
22
RUN apk add --no-cache git python3 build-base
3+
COPY . /app
34
WORKDIR /app
5+
RUN yarn install \
6+
&& yarn build
47

5-
# Install the dependencies first
6-
COPY yarn.lock package.json ./
7-
RUN yarn install
8-
9-
# Copy the rest and build the app
10-
COPY . .
11-
RUN yarn build
12-
13-
# Remove the default config, replace it with a symlink to somewhere that will be updated at runtime
14-
RUN rm -f target/config.json \
15-
&& ln -sf /tmp/config.json target/config.json
16-
17-
FROM --platform=${TARGETPLATFORM} docker.io/nginxinc/nginx-unprivileged:1.21-alpine
18-
19-
# Copy the config template as well as the templating script
20-
COPY ./docker/config.json.tmpl /config.json.tmpl
21-
COPY ./docker/config-template.sh /docker-entrypoint.d/99-config-template.sh
22-
23-
# Copy the built app from the first build stage
8+
FROM docker.io/nginx:alpine
249
COPY --from=builder /app/target /usr/share/nginx/html
25-
26-
# Values from the default config that can be overridden at runtime
27-
ENV PUSH_APP_ID="io.element.hydrogen.web" \
28-
PUSH_GATEWAY_URL="https://matrix.org" \
29-
PUSH_APPLICATION_SERVER_KEY="BC-gpSdVHEXhvHSHS0AzzWrQoukv2BE7KzpoPO_FfPacqOo3l1pdqz7rSgmB04pZCWaHPz7XRe6fjLaC-WPDopM" \
30-
DEFAULT_HOMESERVER="matrix.org"

doc/docker.md

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -35,17 +35,15 @@ To stop the container, simply hit `ctrl+c`.
3535

3636
In this repository, create a Docker image:
3737

38-
```sh
39-
# Enable BuildKit https://docs.docker.com/develop/develop-images/build_enhancements/
40-
export DOCKER_BUILDKIT=1
38+
```
4139
docker build -t hydrogen .
4240
```
4341

44-
Or, pull the Docker image the GitHub Container Registry:
42+
Or, pull the docker image from GitLab:
4543

4644
```
47-
docker pull ghcr.io/vector-im/hydrogen
48-
docker tag ghcr.io/vector-im/hydrogen hydrogen
45+
docker pull registry.gitlab.com/jcgruenhage/hydrogen-web
46+
docker tag registry.gitlab.com/jcgruenhage/hydrogen-web hydrogen
4947
```
5048

5149
### Start container image
@@ -55,6 +53,6 @@ Then, start up a container from that image:
5553
```
5654
docker run \
5755
--name hydrogen \
58-
--publish 8080:80 \
56+
--publish 80:80 \
5957
hydrogen
6058
```

docker/config-template.sh

Lines changed: 0 additions & 7 deletions
This file was deleted.

docker/config.json.tmpl

Lines changed: 0 additions & 16 deletions
This file was deleted.

0 commit comments

Comments
 (0)