diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index cced81a..32e0a25 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -133,25 +133,15 @@ jobs: - run: | cd release tar xzvf skynet-linux-x86_64.tar.gz - cd - - - name: Build and push x86_64 - uses: docker/build-push-action@v5 - with: - context: . - platforms: linux/amd64 - push: true - tags: ${{ steps.meta.outputs.tags }} - labels: ${{ steps.meta.outputs.labels }} - - run: | - cd release - rm -rf skynet + mv skynet amd64 tar xzvf skynet-linux-aarch64.tar.gz + mv skynet arm64 cd - - name: Build and push aarch64 uses: docker/build-push-action@v5 with: context: . - platforms: linux/arm64 + platforms: linux/amd64,linux/arm64 push: true tags: ${{ steps.meta.outputs.tags }} labels: ${{ steps.meta.outputs.labels }} diff --git a/Dockerfile b/Dockerfile index 8ede78a..047191e 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,7 +1,8 @@ FROM ubuntu:latest +ARG TARGETARCH RUN useradd -s /usr/sbin/nologin -r -c "Skynet User" skynet -COPY --chown=skynet:skynet release/skynet /app +COPY --chown=skynet:skynet release/$TARGETARCH /app WORKDIR /app USER skynet diff --git a/README.md b/README.md index a7fbfab..b42ba8f 100644 --- a/README.md +++ b/README.md @@ -10,6 +10,12 @@ Security is considered as **TOP** priority in Skynet, we will not consider featu ### Run in docker +1. Copy `docker-compose.yml` and `conf.yml` to your folder. +2. `mkdir plugin` and `mkdir -p assets/_plugin`, then add your plugins. +3. `touch data.db` or copy your existing database. +4. `docker-compose up` +5. Visit `localhost:8080`. + ### Run natively **We do not recommend this method, use at your own risk!** diff --git a/docker-compose.yml b/docker-compose.yml index 71c8c0d..7611a86 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,6 +1,6 @@ services: skynet: - build: . + image: imwxz/skynet restart: always depends_on: - redis