Skip to content

Commit

Permalink
ci: cleanup for images (#28)
Browse files Browse the repository at this point in the history
* ci: add a cleanup for the images

* ci: add it as a schedule

* docs: update for the current images
  • Loading branch information
barelyhuman authored Oct 2, 2024
1 parent 82089ed commit ee80fc5
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 6 deletions.
22 changes: 22 additions & 0 deletions .github/workflows/cleanup.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Cleaner

on:
workflow_dispatch:
schedule:
- cron: "0 0 12,25 * *"

jobs:
cleanup:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
attestations: write
id-token: write
steps:
- uses: actions/delete-package-versions@v5
with:
package-name: goblin
package-type: container
min-versions-to-keep: 10
ignore-versions: '(v?\d+\.\d+\.\d+|latest|(nightly[-]\w+))'
11 changes: 5 additions & 6 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -83,13 +83,12 @@ simpler fashion**

### Existing Image

The repository builds a nightly image that you can use directly if you don't
wish to tweak anything.
The repository builds and publishes a `latest` and a semver tagged version on each release. You can use that if you do not wish to tweak or change anything in the original source code and build structure

```sh
$ docker run -p "3000:3000" ghcr.io/barelyhuman/goblin:nightly
$ docker run -p "3000:3000" ghcr.io/barelyhuman/goblin:latest
# change the domain to whatever you are using for it
$ docker run -e "GOBLIN_ORIGIN_URL=example.com" -p "3000:3000" ghcr.io/barelyhuman/goblin:nightly
$ docker run -e "GOBLIN_ORIGIN_URL=example.com" -p "3000:3000" ghcr.io/barelyhuman/goblin:latest
```

#### Using Docker
Expand Down Expand Up @@ -155,8 +154,8 @@ ORIGIN_URL=
```sh
# www/.env

# the same url as ORIGIN_URL but added again because vite needs it in the repo
VITE_GOBLIN_ORIGIN_URL=
# the same url as ORIGIN_URL but added again because the static build needs it in the repo
GOBLIN_ORIGIN_URL=
```

running the `build.sh` should handle building with the needed env files and
Expand Down

0 comments on commit ee80fc5

Please sign in to comment.