From 2cb7243b10798cb890255b1430508ef5f2b6fe23 Mon Sep 17 00:00:00 2001 From: Kwoth Date: Tue, 24 Aug 2021 23:57:44 +0200 Subject: [PATCH] Updated publish stage to be called build, updated README.md with some instructions on how to install a release version for linux --- .gitlab-ci.yml | 6 +++--- Dockerfile | 2 +- README.md | 25 ++++++++++++++++++++++++- 3 files changed, 28 insertions(+), 5 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 5a610bc60..c3b5d1051 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,7 +1,7 @@ image: mcr.microsoft.com/dotnet/sdk:5.0 stages: - - publish + - build - test - upload - release @@ -15,8 +15,8 @@ variables: WIN_X64_RELEASE: "$CI_COMMIT_TAG-windows-x64-build.zip" PACKAGE_REGISTRY_URL: "${CI_API_V4_URL}/projects/${CI_PROJECT_ID}/packages/generic/NadekoBot-build/${CI_COMMIT_TAG}" -publish: - stage: publish +build: + stage: build script: - "dotnet publish -c Release -r linux-x64 -o $LINUX_X64_OUTPUT_DIR src/NadekoBot/NadekoBot.csproj" - "dotnet publish -c Release -r win7-x64 -o $WIN_X64_OUTPUT_DIR src/NadekoBot/NadekoBot.csproj" diff --git a/Dockerfile b/Dockerfile index 518cf090f..63217e263 100644 --- a/Dockerfile +++ b/Dockerfile @@ -18,5 +18,5 @@ ENV shard_id=0 ENV total_shards=1 WORKDIR /app COPY --from=build /app ./ -VOLUME [ "/data" ] +VOLUME [ "app/data", "app/creds.yml", "app/creds_example.yml" ] ENTRYPOINT dotnet NadekoBot.dll "$shard_id" "$total_shards" \ No newline at end of file diff --git a/README.md b/README.md index 0a35a5ccb..5be6f98b4 100644 --- a/README.md +++ b/README.md @@ -56,9 +56,9 @@ ## Fresh Installation - [Windows - Release](#windows-release) -- [Linux - Release](#linux-release) - [Windows - From Source](#windows-from-source) - [Linux - From Source](#linux-from-source) +- [Linux - Release](#linux-release) - [Docker] ### Windows From Source @@ -115,6 +115,10 @@ Open Terminal (if you're on a linux with window manager) and navigate to the loc 6. Open `nadekobot/output/creds.yml` with your favorite text editor. We will use nano here 7. `nano nadekobot/output/creds.yml` 8. [Enter your bot's token](#creds-guide) + - You can close nano (and save the file) by typing + - CTRL+X + - Type `y` + - Press Enter 9. Run the bot (type `3` and press enter) ###### Update Instructions @@ -125,6 +129,25 @@ Open Terminal (if you're on a linux with window manager) and navigate to the loc 4. Run the bot (type `3` and press enter) 5. 🎉 +### Linux Release + +1. Download the latest release from + - Look for the file called "X.XX.X-linux-x64-build.tar" and download it +2. Untar it `tar xf 2.99.8-linux-x64-build.tar` + - Rename the `output-linux-x64` to `nadekobot` (`mv output-linux-x64 nadekobot`) +3. Move into nadekobot directory and make NadekoBot executable `cd nadekobot && chmod +x NadekoBot` +5. Copy the creds.yml template `cp creds_example.yml creds.yml` +6. Open `creds.yml` with your favorite text editor. We will use nano here +7. `nano nadekobot/output/creds.yml` +8. [Enter your bot's token](#creds-guide) + - You can close nano (and save the file) by typing + - CTRL+X + - Type `y` + - Press Enter +9. Run the bot `./NadekoBot` + +TODO: Updating release linux version + ## Creds Guide This document aims to guide you through the process of creating a Discord account for your bot