Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ jobs:
SCROLL_REGISTRY_API_KEY: ${{ secrets.SCROLL_REGISTRY_API_KEY }}
SCROLL_REGISTRY_API_SECRET: ${{ secrets.SCROLL_REGISTRY_API_SECRET }}
SCROLL_REGISTRY_BUCKET: ${{ secrets.SCROLL_REGISTRY_BUCKET_STAGING }}
DRUID_CLI_VERSION: v0.1.227
DRUID_CLI_VERSION: v0.1.243
steps:
- uses: actions/checkout@v3
- uses: actions/setup-go@v3
Expand Down
52 changes: 30 additions & 22 deletions .github/workflows/prebuild-lsm.yml
Original file line number Diff line number Diff line change
@@ -1,41 +1,49 @@
name: Prebuild LGSM
name: Prebuild Steam Scrolls
on:
workflow_dispatch:
inputs:
image:
description: "Image"
targets:
description: "one scroll, comma-separated scrolls, or all-steam"
required: false
default: ""
default: "all-steam"
schedule:
- cron: "0 3 * * *"
jobs:
build-lgsm:
build-steam:
runs-on: [self-hosted, nauen]
strategy:
matrix:
image: ["ark", "cs2"]
env:
DRUID_CLI_VERSION: v0.1.243
DRUID_RUNTIME_IMAGE: artifacts.druid.gg/druid-team/druid:v0.1.243
DRUID_STEAM_RUNTIME_IMAGE: artifacts.druid.gg/druid-team/druid:v0.1.243-steamcmd
PREBUILD_DOCKER_PLATFORM: linux/amd64
steps:
- uses: actions/checkout@v3
- uses: actions/setup-go@v5
with:
go-version: ">=1.22.3"
- name: Build scroll tree
run: make build-tree
- name: Get druid binary
uses: robinraju/release-downloader@v1.7
with:
repository: "highcard-dev/druid-cli"
tag: ${{ env.DRUID_CLI_VERSION }}
fileName: "druid"
token: ${{ secrets.GO_REPO_TOKEN }}
- name: Install druid
run: |
chmod +x druid
mv druid /usr/local/bin/druid
- name: Validate all scrolls
run: ./scripts/validate_all_scrolls.sh
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
registry: artifacts.druid.gg
username: ${{ secrets.IMAGE_REGISTRY_USER }}
password: ${{ secrets.IMAGE_REGISTRY_PASSWORD }}
- uses: actions/setup-go@v5
with:
go-version: ">=1.22.3"

# - name: Setup tmate session
# uses: mxschmitt/action-tmate@v3
# env:
# PRESIGN_ACCESS_KEY: ${{ secrets.PRESIGN_ACCESS_KEY }}
# PRESIGN_BUCKET_NAME: ${{ secrets.PRESIGN_BUCKET_NAME }}
# PRESIGN_S3_ENDPOINT: ${{ secrets.PRESIGN_S3_ENDPOINT }}
# PRESIGN_SECRET_KEY: ${{ secrets.PRESIGN_SECRET_KEY }}
# BACKUP_ADDITIONAL_ARGS: "--insecure"
- name: Prebuild and upload Image ${{ matrix.image }}
run: ./scripts/prebuild/prebuild.sh ${{ matrix.image }}
- name: Prebuild and upload
run: ./scripts/prebuild/prebuild.sh "${{ inputs.targets || 'all-steam' }}"
env:
SCROLL_REGISTRY_HOST: ${{ secrets.SCROLL_REGISTRY_HOST }}
SCROLL_REGISTRY_USER: ${{ secrets.SCROLL_REGISTRY_USER }}
Expand Down
190 changes: 95 additions & 95 deletions .github/workflows/release.yml

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
.env
scrolls-registry/.builds
.builds
.prebuild-tmp
*.tar.gz

scroll-builder
scroll-builder
6 changes: 3 additions & 3 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,12 @@ Context for humans and coding agents working in this repository.
- When adding a new scroll family, you usually need both a **Push Categories** line (for that family’s `.meta`) and **Pushing new scrolls** lines for each version directory.
- All production scroll/artifact changes must go through CI/CD. Do not manually push production scrolls or mutate production registry state unless explicitly authorized for an emergency; follow up with a repo change so CI is source of truth again.

## `druid registry push category` — three positional arguments
## `druid push category` — three positional arguments

The command signature is:

```text
druid registry push category <repo> <category> [<scrollDir>]
druid push category <repo> <category> [<scrollDir>]
```

| Position | Meaning |
Expand All @@ -30,7 +30,7 @@ druid registry push category <repo> <category> [<scrollDir>]

**Common mistake:** passing only two arguments after `category`, where the second looks like a path (for example `./scrolls/minecraft/foo/.meta`). Then that string is treated as the category label, `scrollDir` stays `.`, and the CLI errors with no files matching the locale pattern.

**Convention here:** use the same short category string as `druid registry push ... --category <name>` for that product in the same workflow (for example `minecraft`, `rust`, `palworld`, `hytale`).
**Convention here:** use the same short category string as `druid push ... --category <name>` for that product in the same workflow (for example `minecraft`, `rust`, `palworld`, `hytale`).

## Validation

Expand Down
8 changes: 7 additions & 1 deletion generate-scrolls.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ type TemplateVars struct {
Version string
VersionEscaped string
ColdstarterImage string
SteamImage string
Artifacts map[string]string
ArtifactsUnescaped map[string]string
Vars map[string]string
Expand Down Expand Up @@ -94,7 +95,11 @@ func main() {
}
coldstarterImage := os.Getenv("DRUID_COLDSTARTER_IMAGE")
if coldstarterImage == "" {
coldstarterImage = "artifacts.druid.gg/druid-team/druid:stable"
coldstarterImage = "artifacts.druid.gg/druid-team/druid:v0.1.243"
}
steamImage := os.Getenv("DRUID_STEAM_RUNTIME_IMAGE")
if steamImage == "" {
steamImage = "artifacts.druid.gg/druid-team/druid:v0.1.243-steamcmd"
}

//iterate through artifacts and generate scroll.yaml files
Expand All @@ -105,6 +110,7 @@ func main() {
templateVars.Version = version
templateVars.VersionEscaped = strings.Replace(version, ".", "-", -1)
templateVars.ColdstarterImage = coldstarterImage
templateVars.SteamImage = steamImage
templateVars.Artifacts = GetArtifactsAbove(version, artifacts, true)
templateVars.ArtifactsUnescaped = GetArtifactsAbove(version, artifacts, false)
if varsBytes != nil && vars[version] == nil {
Expand Down
Loading
Loading