diff --git a/.github/workflows/build-main.yml b/.github/workflows/build-main.yml index 596fcfa..46afbb5 100644 --- a/.github/workflows/build-main.yml +++ b/.github/workflows/build-main.yml @@ -61,12 +61,12 @@ jobs: sha1: a4bcd861626195af80cc1f962d3a2f4528859ad2 - version: "0.9.3.0" tag: > - soupbowl/opensimulator:0.9.3-noscreen, - soupbowl/opensimulator:0.9.3.0-noscreen, - ghcr.io/${{ github.repository }}:0.9.3-noscreen, - ghcr.io/${{ github.repository }}:0.9.3.0-noscreen, + soupbowl/opensimulator:0.9.3-screen, + soupbowl/opensimulator:0.9.3.0-screen, + ghcr.io/${{ github.repository }}:0.9.3-screen, + ghcr.io/${{ github.repository }}:0.9.3.0-screen, folder: build/latest - file: Dockerfile.noscreen + file: Dockerfile.screen platforms: linux/amd64,linux/arm64 sha1: a4bcd861626195af80cc1f962d3a2f4528859ad2 - version: "0.9.3.0" diff --git a/README.md b/README.md index 202b51e..5eb0d21 100644 --- a/README.md +++ b/README.md @@ -22,7 +22,7 @@ This **unofficial** Docker configuration aims to assist in setting the server up - [`latest`, `0.9`, `0.9.3`, `0.9.3.0`](https://github.com/soup-bowl/opensimulator-docker/blob/main/build/latest/Dockerfile) -- [`0.9.3-noscreen`, `0.9.3.0-noscreen`](https://github.com/soup-bowl/opensimulator-docker/blob/main/build/latest/Dockerfile.noscreen) +- [`0.9.3-screen`, `0.9.3.0-screen`](https://github.com/soup-bowl/opensimulator-docker/blob/main/build/latest/Dockerfile.screen) - [`0.9.2`, `0.9.2.2`](https://github.com/soup-bowl/opensimulator-docker/blob/main/build/latest/Dockerfile.mono) @@ -34,7 +34,8 @@ This **unofficial** Docker configuration aims to assist in setting the server up # Usage -Versions 0.9.3.0 and above use .NET, and due to a bug under investigation ([see #9][I9]) the image uses `screen` to prevent the session from ending unexpectedly. Versions 0.9.2.2 and below use Mono. Please see Limitations for more information. +> [!IMPORTANT] +> The dependency on `screen` for this image has been resolved (see [#9][I9]), so any further updates to the versioned images of 0.9.3.0 and above will no longer use screen. If you wish to continue with this version, switch your tag to `0.9.3.0-screen`, however ongoing support for this is **not guaranteed**. ```bash docker run -it -d --name opensim -p 9000:9000 -p 9000:9000/udp soupbowl/opensimulator:latest @@ -58,6 +59,8 @@ Once the server is running, you should be able to connect to it on `localhost:90 If you don't define otherwise in the environments or a custom configuration, the login username is **Foo bar** and the password is **password**. +You can access the server administration command panel by running `docker attach `. You may need to run a command (e.g. `help`) to get the input to show up. + ## Custom Configurations The environment list is not inclusive to the incredible range of options that OpenSimulator can be configured, and just covers a subset of the most popular settings. If you specify your own custom configuration file, it will be used instead of the image-generated configuration (you can define it as readonly (`:ro`) for assurance). @@ -78,27 +81,6 @@ docker run -d --name opensim -p 9000:9000 -p 9000:9000/udp -v /path/on/your/syst # Limitations -## Running Server Admin Commands - -At current, there doesn't appear to be an implemented and/or documented approach to managing the server from _outside_ the active TTY, and running `docker attach opensim` seems to produce a blank prompt. You can `exec` into the container or edit the bound configuration script and restart the server to make changes, but in some server instances you might need to intercept the prompt. - -This Docker image comes with `screen` built in, to allow you to access the administration prompt. This also seems to help prevent against Docker from accidentally destroying the image (currently investigating). As a result this leaves the Docker log unfortunately blank, but you can access the logfile at `/opt/opensim/bin/OpenSim.log`. - -You can access a controllable OpenSimulator administration prompt by running: - -``` -docker exec -it screen -r -d OpenSim -``` - -You can leave the screen session by pressing `ctrl + a` then `d`. - -If you wish to run **without**, you can modify the Dockerfile like so: - -```dockerfile -FROM soupbowl/opensimulator:latest -CMD [ "dotnet", "OpenSim.dll" ] -``` - ## Physics in ARM Each image has an ARM64 architecture build. Your mileage may vary with these as the server environment was not designed for use outside x86_64. @@ -128,9 +110,19 @@ The latest OpenSimulator image build using [official .NET 8 image](https://mcr.m If you pull from **0.9.2.2** or below, you will instead be using the [Mono Framework](https://hub.docker.com/_/mono/). -## `soupbowl/opensimulator:-noscreen` +## `soupbowl/opensimulator:-screen` -Starting from **0.9.3.0**, until [#9 is resolved](https://github.com/soup-bowl/opensimulator-docker/issues/9), there is a build of the Dotnet editions without screen. This is **temporary** and will be removed once a solution is found, so there is no latest tag to avoid dependency. All feedback on experience is welcome on [issue #9][I9]. +Reported in [issue #9][I9] and starting with OpenSimulator version **0.9.3.0**, there was a bug that would cause the OpenSimulator server to unexpectedly shut down, seemingly from a phantom kill input. `screen` was used (and used previously to access the server) to send inputs to the server. + +The mainline images are now using `-console=basic`, which strips away some of the fancy features in exchange for compatibility with the Docker session. `screen` is no longer required, and session management can be achieved via `docker attach`. + +To aid a transition to this approach, this version is provided that continues to use screen. In this mode, regular server mode is retained, and you access server controls via: + +``` +docker exec -it screen -r -d OpenSim +``` + +You can leave the screen session by pressing `ctrl + a` then `d`. Please note that in this variant, no logs are output as they are captured in the screen session. ## `soupbowl/opensimulator:alpine-beta` diff --git a/build/latest/Dockerfile b/build/latest/Dockerfile index 9d21fdc..2650b5b 100644 --- a/build/latest/Dockerfile +++ b/build/latest/Dockerfile @@ -13,7 +13,7 @@ ARG OPENSIM_SHA1="a4bcd861626195af80cc1f962d3a2f4528859ad2" # hadolint ignore=DL3008 RUN apt-get update \ - && apt-get install --no-install-recommends -y apt-utils curl libc6-dev libgdiplus libsqlite3-dev screen uuid-runtime \ + && apt-get install --no-install-recommends -y apt-utils curl libc6-dev libgdiplus libsqlite3-dev uuid-runtime \ && apt-get clean \ && rm -rf /var/lib/apt/lists/* \ && mkdir /opt/opensim-tmp \ @@ -35,4 +35,4 @@ WORKDIR /opt/opensim/bin COPY docker-entrypoint.sh /usr/local/bin/ ENTRYPOINT ["docker-entrypoint.sh"] -CMD [ "screen", "-S", "OpenSim", "-D", "-m", "dotnet", "OpenSim.dll" ] +CMD [ "dotnet", "OpenSim.dll", "-console=basic" ] diff --git a/build/latest/Dockerfile.alpine b/build/latest/Dockerfile.alpine index ed1254c..487d2df 100644 --- a/build/latest/Dockerfile.alpine +++ b/build/latest/Dockerfile.alpine @@ -10,7 +10,7 @@ LABEL \ ENV OPENSIM_VERSION=0.9.3.0 -RUN apk add --no-cache curl dotnet8-runtime libgdiplus screen sqlite sqlite-libs uuidgen \ +RUN apk add --no-cache curl dotnet8-runtime libgdiplus sqlite sqlite-libs uuidgen \ && mkdir /opt/opensim-tmp \ && curl "http://opensimulator.org/dist/opensim-${OPENSIM_VERSION}.tar.gz" | tar xzf - -C /opt/opensim-tmp \ && rm /opt/opensim-tmp/opensim*/bin/OpenSim.ini \ @@ -28,4 +28,4 @@ WORKDIR /opt/opensim/bin COPY docker-entrypoint.sh /usr/local/bin/ ENTRYPOINT ["docker-entrypoint.sh"] -CMD [ "screen", "-S", "OpenSim", "-D", "-m", "dotnet", "OpenSim.dll" ] +CMD [ "dotnet", "OpenSim.dll", "-console=basic" ] diff --git a/build/latest/Dockerfile.noscreen b/build/latest/Dockerfile.screen similarity index 95% rename from build/latest/Dockerfile.noscreen rename to build/latest/Dockerfile.screen index 668c21d..e5d331f 100644 --- a/build/latest/Dockerfile.noscreen +++ b/build/latest/Dockerfile.screen @@ -35,4 +35,4 @@ WORKDIR /opt/opensim/bin COPY docker-entrypoint.sh /usr/local/bin/ ENTRYPOINT ["docker-entrypoint.sh"] -CMD [ "dotnet", "OpenSim.dll" ] +CMD [ "screen", "-S", "OpenSim", "-D", "-m", "dotnet", "OpenSim.dll" ] diff --git a/build/latest/Dockerfile.source b/build/latest/Dockerfile.source index c993cc5..6a4fdb4 100644 --- a/build/latest/Dockerfile.source +++ b/build/latest/Dockerfile.source @@ -23,7 +23,7 @@ LABEL \ # hadolint ignore=DL3008 RUN apt-get update && \ - apt-get install --no-install-recommends -y apt-utils libc6-dev libgdiplus libsqlite3-dev screen uuid-runtime && \ + apt-get install --no-install-recommends -y apt-utils libc6-dev libgdiplus libsqlite3-dev uuid-runtime && \ apt-get clean && \ rm -rf /var/lib/apt/lists/* @@ -36,4 +36,4 @@ WORKDIR /opt/opensim/bin COPY docker-entrypoint.sh /usr/local/bin/ ENTRYPOINT ["docker-entrypoint.sh"] -CMD [ "screen", "-S", "OpenSim", "-D", "-m", "sh", "./opensim.sh" ] +CMD [ "dotnet", "OpenSim.dll", "-console=basic" ]