Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add whiteboard container for nc30 #5063

Closed
Tracked by #5249
szaimen opened this issue Jul 29, 2024 · 22 comments · Fixed by #5274
Closed
Tracked by #5249

Add whiteboard container for nc30 #5063

szaimen opened this issue Jul 29, 2024 · 22 comments · Fixed by #5274
Assignees
Labels
2. developing Work in progress enhancement New feature or request
Milestone

Comments

@szaimen
Copy link
Collaborator

szaimen commented Jul 29, 2024

As option to the aio interface. See nextcloud/whiteboard#82 and #378 as reference

FYI @juliushaertl

@szaimen szaimen added 1. to develop Accepted and waiting to be taken care of enhancement New feature or request labels Jul 29, 2024
@szaimen szaimen self-assigned this Jul 29, 2024
@juliushaertl
Copy link
Member

Relevant occ commands to automate configuration are in the apps readme, caddy config can be adapted from https://socket.io/docs/v3/reverse-proxy/#caddy-2

@szaimen
Copy link
Collaborator Author

szaimen commented Aug 14, 2024

@szaimen
Copy link
Collaborator Author

szaimen commented Sep 4, 2024

@szaimen
Copy link
Collaborator Author

szaimen commented Sep 12, 2024

All good, thanks! I will be working on that for the next major release of AIO that will be shipping nc30 for everyone. It will likely come out when nc30.0.1 or nc30.0.2 is released.

@szaimen
Copy link
Collaborator Author

szaimen commented Sep 12, 2024

https://github.com/nextcloud-releases/whiteboard/pkgs/container/whiteboard/272546293?tag=v1.0.0-rc.1

@juliushaertl looks like the package is private or not reachable for me?

@juliushaertl
Copy link
Member

@szaimen
Copy link
Collaborator Author

szaimen commented Sep 12, 2024

yes, can see it 👍

@szaimen szaimen mentioned this issue Sep 12, 2024
37 tasks
@Zoey2936
Copy link
Collaborator

# syntax=docker/dockerfile:latest
FROM node:20.17.0-alpine3.20
SHELL ["/bin/ash", "-eo", "pipefail", "-c"]
ENV NODE_ENV=production
ARG WB_VER=v1.0.0-rc.1
WORKDIR /app
RUN apk upgrade --no-cache -a && \
    apk add --no-cache ca-certificates tzdata netcat-openbsd && \
    wget https://github.com/nextcloud-releases/whiteboard/archive/refs/tags/"$WB_VER".tar.gz -O - | tar xzC /app --strip-components=1 && \
    npm install --global clean-modules && \
    npm clean-install && \
    npm cache clean --force && \
    clean-modules --yes && \
    npm uninstall --global clean-modules && \
    chown -R nobody:nobody /app

USER nobody
ENTRYPOINT ["npm", "run", "server:start"]
HEALTHCHECK CMD nc -z 127.0.0.1 3002 || exit 1

should work (Dockerlint should be ok, it is just one run step) - workflow needed vor version updates

@szaimen
Copy link
Collaborator Author

szaimen commented Sep 12, 2024

Thanks @Zoey2936 but my idea was rather to re-use the existing container... WDYT?

@Zoey2936
Copy link
Collaborator

also possible, but then the upstream Dockerfile needs changes:

  1. it uses multiple run steps which makes it bigger then it needs (also I recommend clean-modules to remove bnot needed files from the node_modules folder)
  2. the docker image is not very strictly tagged, can be used, but I think it is not the best way
  3. tzdata is missing
  4. healthcheck is missing
  5. them CMD would not even work at this moment:
    https://github.com/nextcloud/whiteboard/blob/2e5014eff779a72d2e5dc2db220d50b0732200d2/Dockerfile#L27
    file does not exist: https://github.com/nextcloud/whiteboard/tree/v1.0.0-rc.1/websocket_server
    instead it should be npm run server:start or node websocket_server/main.js
    https://github.com/nextcloud/whiteboard/blob/2e5014eff779a72d2e5dc2db220d50b0732200d2/package.json#L16

@szaimen
Copy link
Collaborator Author

szaimen commented Sep 12, 2024

@juliushaertl FYI ⬆️

@Zoey2936
Copy link
Collaborator

Í can also open a PR at https://github.com/nextcloud/whiteboard

@szaimen
Copy link
Collaborator Author

szaimen commented Sep 12, 2024

Sounds good, thanks for the offer :)

@juliushaertl
Copy link
Member

Definitely, a pr there is much appreciated

@Zoey2936
Copy link
Collaborator

see nextcloud/whiteboard#145

@juliushaertl
Copy link
Member

Merged and released as 1.0.0-rc.2, thanks again @Zoey2936

@szaimen
Copy link
Collaborator Author

szaimen commented Sep 13, 2024

@juliushaertl I am wondering if we should rather wait for nextcloud/whiteboard#119 and not implement the container additionally in AIO as the app_api is already part of AIO.

@szaimen
Copy link
Collaborator Author

szaimen commented Sep 13, 2024

However users of https://github.com/nextcloud/all-in-one/tree/main/nextcloud-aio-helm-chart would then not be able to easily run it...

@juliushaertl
Copy link
Member

For now nextcloud/whiteboard#119 will have performance penalty as there is only a way to proxy requests through a PHP endpoint, so at least in the first iteration there is no websocket connection just polling. I think running the separate container is still the better approach.

@szaimen
Copy link
Collaborator Author

szaimen commented Sep 13, 2024

All right. Will add it then to aio directly 👍

@szaimen szaimen removed the 1. to develop Accepted and waiting to be taken care of label Sep 16, 2024
@szaimen szaimen added 2. developing Work in progress and removed upstream blocked labels Sep 16, 2024
@szaimen szaimen added this to the next milestone Sep 16, 2024
@szaimen
Copy link
Collaborator Author

szaimen commented Sep 18, 2024

This is now released with v9.6.0 Beta. Testing and feedback is welcome! See https://github.com/nextcloud/all-in-one#how-to-switch-the-channel

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 4, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
2. developing Work in progress enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants