mirror of
https://github.com/renovatebot/github-action.git
synced 2025-12-18 09:52:35 +00:00
Compare commits
100 commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
eed36ceef6 | ||
|
|
7359cca382 | ||
|
|
b4fc770ace | ||
|
|
54ccfe8c99 | ||
|
|
3fb872de61 | ||
|
|
7f353c27aa | ||
|
|
548f050250 | ||
|
|
a05a7732a1 | ||
|
|
d21ed0efec | ||
|
|
efc82a710f | ||
|
|
e571d85ac0 | ||
|
|
635cf78cf0 | ||
|
|
95fbfab63b | ||
|
|
07847d1ce3 | ||
|
|
395475ba39 | ||
|
|
35e2653320 | ||
|
|
094e9c6953 | ||
|
|
dabc2a05a3 | ||
|
|
9b96e25a5a | ||
|
|
c778357a67 | ||
|
|
4728f99879 | ||
|
|
5fde7be597 | ||
|
|
f5951c521b | ||
|
|
2fb813ee7f | ||
|
|
fde0305037 | ||
|
|
47283fac74 | ||
|
|
ccbe4e599c | ||
|
|
5601672bb1 | ||
|
|
5ccdc9c834 | ||
|
|
877f1edb5a | ||
|
|
a7d997abb9 | ||
|
|
a163433138 | ||
|
|
80916137e7 | ||
|
|
27c17575a9 | ||
|
|
c3a7384543 | ||
|
|
c31dec6b59 | ||
|
|
61dcbbd7bc | ||
|
|
92e7f7b274 | ||
|
|
9c94e7fd2b | ||
|
|
f90da8d8bc | ||
|
|
1adf39f4f8 | ||
|
|
7f974c0f8a | ||
|
|
6856febbe5 | ||
|
|
8342c937a8 | ||
|
|
8380aa8941 | ||
|
|
a272caf98b | ||
|
|
80e45c233d | ||
|
|
c9c06da449 | ||
|
|
7aecb0a372 | ||
|
|
9e1daf1110 | ||
|
|
5b820c1cd9 | ||
|
|
de82540087 | ||
|
|
700b8952df | ||
|
|
817bae1f42 | ||
|
|
dc3589581a | ||
|
|
4f9787fc9d | ||
|
|
b1b6377177 | ||
|
|
e9008ac40d | ||
|
|
6378a85217 | ||
|
|
c55898597d | ||
|
|
e6368fdaca | ||
|
|
b8053ce4b8 | ||
|
|
13dbfa2450 | ||
|
|
c4a4a8e9d4 | ||
|
|
f2a3a2ab0c | ||
|
|
5528b56de9 | ||
|
|
56ac2fc403 | ||
|
|
afa2fa89b9 | ||
|
|
eff79185c2 | ||
|
|
df0b720320 | ||
|
|
ddf131ed0c | ||
|
|
82ec2836b7 | ||
|
|
e022113a52 | ||
|
|
d65800d5d4 | ||
|
|
82475db394 | ||
|
|
f7337fdf53 | ||
|
|
280b58e85e | ||
|
|
cb999b8888 | ||
|
|
a2e6f2c844 | ||
|
|
79de2597ec | ||
|
|
b6077f89cf | ||
|
|
c023f569b1 | ||
|
|
d7b2cb950e | ||
|
|
8109939667 | ||
|
|
a27b37e61c | ||
|
|
7dacb799b6 | ||
|
|
f8f972df2b | ||
|
|
c654f3ca90 | ||
|
|
39fbfa40c9 | ||
|
|
6eab2b7ef6 | ||
|
|
ad718be8b5 | ||
|
|
9a03ec1eb4 | ||
|
|
0a7b3c6d79 | ||
|
|
a014389a0a | ||
|
|
bbde94e6b6 | ||
|
|
07abe3d743 | ||
|
|
fb6e56fcfa | ||
|
|
6bbb0487e8 | ||
|
|
8d95600783 | ||
|
|
cb626814b5 |
9 changed files with 509 additions and 483 deletions
6
.github/actions/setup-node/action.yml
vendored
6
.github/actions/setup-node/action.yml
vendored
|
|
@ -18,7 +18,7 @@ runs:
|
|||
}}' >> "$GITHUB_ENV"
|
||||
|
||||
- name: ♻️ Restore `node_modules`
|
||||
uses: actions/cache/restore@0057852bfaa89a56745cba8c7296529d2fc39830 # v4.3.0
|
||||
uses: actions/cache/restore@9255dc7a253b0ccc959486e2bca901246202afeb # v5.0.1
|
||||
id: node-modules-restore
|
||||
with:
|
||||
path: node_modules
|
||||
|
|
@ -38,7 +38,7 @@ runs:
|
|||
standalone: true
|
||||
|
||||
- name: ⚙️ Setup Node.js ${{ inputs.node-version }}
|
||||
uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v6.0.0
|
||||
uses: actions/setup-node@395ad3262231945c25e8478fd5baf05154b1d79f # v6.1.0
|
||||
with:
|
||||
node-version-file: .node-version
|
||||
cache: ${{ env.CACHE_HIT != 'true' && 'pnpm' || '' }}
|
||||
|
|
@ -53,7 +53,7 @@ runs:
|
|||
|
||||
- name: ♻️ Write `node_modules` cache
|
||||
if: inputs.save-cache == 'true' && env.CACHE_HIT != 'true'
|
||||
uses: actions/cache/save@0057852bfaa89a56745cba8c7296529d2fc39830 # v4.3.0
|
||||
uses: actions/cache/save@9255dc7a253b0ccc959486e2bca901246202afeb # v5.0.1
|
||||
with:
|
||||
path: node_modules
|
||||
key: ${{ env.CACHE_KEY }}
|
||||
|
|
|
|||
31
.github/workflows/build.yml
vendored
31
.github/workflows/build.yml
vendored
|
|
@ -10,7 +10,7 @@ concurrency:
|
|||
cancel-in-progress: true
|
||||
|
||||
env:
|
||||
RENOVATE_VERSION: 42.27.1 # renovate: datasource=docker depName=renovate packageName=ghcr.io/renovatebot/renovate
|
||||
RENOVATE_VERSION: 42.59.1 # renovate: datasource=docker depName=renovate packageName=ghcr.io/renovatebot/renovate
|
||||
|
||||
jobs:
|
||||
prepare:
|
||||
|
|
@ -18,7 +18,7 @@ jobs:
|
|||
timeout-minutes: 10
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
|
||||
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
|
||||
with:
|
||||
show-progress: false
|
||||
|
||||
|
|
@ -33,7 +33,7 @@ jobs:
|
|||
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
|
||||
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
|
||||
with:
|
||||
fetch-depth: 0
|
||||
show-progress: false
|
||||
|
|
@ -51,7 +51,7 @@ jobs:
|
|||
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
|
||||
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
|
||||
with:
|
||||
show-progress: false
|
||||
|
||||
|
|
@ -75,7 +75,7 @@ jobs:
|
|||
- example/renovate-config.json
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
|
||||
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
|
||||
with:
|
||||
show-progress: false
|
||||
|
||||
|
|
@ -113,11 +113,30 @@ jobs:
|
|||
docker-cmd-file: example/entrypoint.sh
|
||||
docker-user: root
|
||||
|
||||
renovate-config-validator:
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 10
|
||||
container:
|
||||
image: ghcr.io/renovatebot/renovate:42.60.0@sha256:9be8030a7f922f075d8e2daa1930ce5e472e313cb77818f4f7c3a4188056b032
|
||||
# github hosted runners are running as `1001:127` (ubuntu:docker)
|
||||
options: -u 1001:0 --group-add 1000 --group-add 12021 --group-add 127
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
|
||||
with:
|
||||
show-progress: false
|
||||
|
||||
- name: Validate Renovate configuration
|
||||
working-directory: example
|
||||
run: |
|
||||
renovate-config-validator renovate-config.js renovate-config.json
|
||||
|
||||
release:
|
||||
needs:
|
||||
- lint
|
||||
- commitlint
|
||||
- e2e
|
||||
- renovate-config-validator
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Setup Git user
|
||||
|
|
@ -129,7 +148,7 @@ jobs:
|
|||
git config --global user.email "41898282+github-actions[bot]@users.noreply.github.com"
|
||||
|
||||
- name: Checkout
|
||||
uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4.3.1
|
||||
uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 # v6.0.1
|
||||
with:
|
||||
fetch-depth: 0 # required for semantic release
|
||||
ref: 'release'
|
||||
|
|
|
|||
|
|
@ -1 +1 @@
|
|||
20.19.6
|
||||
24.12.0
|
||||
|
|
|
|||
54
README.md
54
README.md
|
|
@ -98,9 +98,9 @@ jobs:
|
|||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v5.0.1
|
||||
uses: actions/checkout@v6.0.1
|
||||
- name: Self-hosted Renovate
|
||||
uses: renovatebot/github-action@v44.0.4
|
||||
uses: renovatebot/github-action@v44.1.0
|
||||
with:
|
||||
docker-cmd-file: .github/renovate-entrypoint.sh
|
||||
docker-user: root
|
||||
|
|
@ -141,9 +141,9 @@ jobs:
|
|||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v5.0.1
|
||||
uses: actions/checkout@v6.0.1
|
||||
- name: Self-hosted Renovate
|
||||
uses: renovatebot/github-action@v44.0.4
|
||||
uses: renovatebot/github-action@v44.1.0
|
||||
with:
|
||||
token: ${{ secrets.RENOVATE_TOKEN }}
|
||||
docker-volumes: |
|
||||
|
|
@ -192,9 +192,9 @@ jobs:
|
|||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v5.0.1
|
||||
uses: actions/checkout@v6.0.1
|
||||
- name: Self-hosted Renovate
|
||||
uses: renovatebot/github-action@v44.0.4
|
||||
uses: renovatebot/github-action@v44.1.0
|
||||
with:
|
||||
renovate-image: myproxyhub.domain.com/renovate/renovate
|
||||
token: ${{ secrets.RENOVATE_TOKEN }}
|
||||
|
|
@ -209,9 +209,9 @@ jobs:
|
|||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v5.0.1
|
||||
uses: actions/checkout@v6.0.1
|
||||
- name: Self-hosted Renovate
|
||||
uses: renovatebot/github-action@v44.0.4
|
||||
uses: renovatebot/github-action@v44.1.0
|
||||
with:
|
||||
token: ${{ secrets.RENOVATE_TOKEN }}
|
||||
```
|
||||
|
|
@ -222,7 +222,7 @@ The Renovate version to use.
|
|||
If omitted the action will use the [`default version`](./action.yml#L28) Docker tag.
|
||||
Check [the available tags on Docker Hub](https://hub.docker.com/r/renovate/renovate/tags).
|
||||
|
||||
This sample will use `ghcr.io/renovatebot/renovate:42.27.1` image.
|
||||
This sample will use `ghcr.io/renovatebot/renovate:42.52.8` image.
|
||||
|
||||
```yml
|
||||
....
|
||||
|
|
@ -231,11 +231,11 @@ jobs:
|
|||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v5.0.1
|
||||
uses: actions/checkout@v6.0.1
|
||||
- name: Self-hosted Renovate
|
||||
uses: renovatebot/github-action@v44.0.4
|
||||
uses: renovatebot/github-action@v44.1.0
|
||||
with:
|
||||
renovate-version: 42.27.1
|
||||
renovate-version: 42.52.8
|
||||
token: ${{ secrets.RENOVATE_TOKEN }}
|
||||
```
|
||||
|
||||
|
|
@ -248,9 +248,9 @@ jobs:
|
|||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v5.0.1
|
||||
uses: actions/checkout@v6.0.1
|
||||
- name: Self-hosted Renovate
|
||||
uses: renovatebot/github-action@v44.0.4
|
||||
uses: renovatebot/github-action@v44.1.0
|
||||
with:
|
||||
renovate-version: full
|
||||
token: ${{ secrets.RENOVATE_TOKEN }}
|
||||
|
|
@ -283,9 +283,9 @@ jobs:
|
|||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v5.0.1
|
||||
uses: actions/checkout@v6.0.1
|
||||
- name: Self-hosted Renovate
|
||||
uses: renovatebot/github-action@v44.0.4
|
||||
uses: renovatebot/github-action@v44.1.0
|
||||
with:
|
||||
configurationFile: example/renovate-config.js
|
||||
token: ${{ secrets.RENOVATE_TOKEN }}
|
||||
|
|
@ -298,7 +298,7 @@ If you want to use the Renovate Action on a GitHub Enterprise instance you have
|
|||
```yml
|
||||
....
|
||||
- name: Self-hosted Renovate
|
||||
uses: renovatebot/github-action@v44.0.4
|
||||
uses: renovatebot/github-action@v44.1.0
|
||||
with:
|
||||
configurationFile: example/renovate-config.js
|
||||
token: ${{ secrets.RENOVATE_TOKEN }}
|
||||
|
|
@ -342,10 +342,10 @@ jobs:
|
|||
repositories: 'repo1,repo2'
|
||||
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v5.0.1
|
||||
uses: actions/checkout@v6.0.1
|
||||
|
||||
- name: Self-hosted Renovate
|
||||
uses: renovatebot/github-action@v44.0.4
|
||||
uses: renovatebot/github-action@v44.1.0
|
||||
with:
|
||||
configurationFile: example/renovate-config.js
|
||||
token: '${{ steps.get_token.outputs.token }}'
|
||||
|
|
@ -360,7 +360,7 @@ For example:
|
|||
|
||||
```yaml
|
||||
- name: Self-hosted Renovate
|
||||
uses: renovatebot/github-action@v44.0.4
|
||||
uses: renovatebot/github-action@v44.1.0
|
||||
with:
|
||||
token: '${{ steps.get_token.outputs.token }}'
|
||||
env:
|
||||
|
|
@ -382,9 +382,9 @@ For example if you wish to pass through some credentials for a [host rule](https
|
|||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v5.0.1
|
||||
uses: actions/checkout@v6.0.1
|
||||
- name: Self-hosted Renovate
|
||||
uses: renovatebot/github-action@v44.0.4
|
||||
uses: renovatebot/github-action@v44.1.0
|
||||
with:
|
||||
configurationFile: example/renovate-config.js
|
||||
token: ${{ secrets.RENOVATE_TOKEN }}
|
||||
|
|
@ -419,9 +419,9 @@ jobs:
|
|||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v5.0.1
|
||||
uses: actions/checkout@v6.0.1
|
||||
- name: Self-hosted Renovate
|
||||
uses: renovatebot/github-action@v44.0.4
|
||||
uses: renovatebot/github-action@v44.1.0
|
||||
with:
|
||||
configurationFile: example/renovate-config.js
|
||||
token: ${{ secrets.RENOVATE_TOKEN }}
|
||||
|
|
@ -512,11 +512,11 @@ jobs:
|
|||
sudo chown -R 12021:0 /tmp/renovate/
|
||||
ls -R $cache_dir
|
||||
|
||||
- uses: renovatebot/github-action@v44.0.4
|
||||
- uses: renovatebot/github-action@v44.1.0
|
||||
with:
|
||||
configurationFile: renovate.json5
|
||||
token: ${{ secrets.RENOVATE_TOKEN }}
|
||||
renovate-version: 42.27.1
|
||||
renovate-version: 42.52.8
|
||||
env:
|
||||
# This enables the cache -- if this is set, it's not necessary to add it to renovate.json.
|
||||
RENOVATE_REPOSITORY_CACHE: ${{ github.event.inputs.repoCache || 'enabled' }}
|
||||
|
|
@ -550,7 +550,7 @@ To enable debug logging, add the environment variable `LOG_LEVEL: 'debug'` to th
|
|||
|
||||
```yml
|
||||
- name: Self-hosted Renovate
|
||||
uses: renovatebot/github-action@v44.0.4
|
||||
uses: renovatebot/github-action@v44.1.0
|
||||
with:
|
||||
configurationFile: example/renovate-config.js
|
||||
token: ${{ secrets.RENOVATE_TOKEN }}
|
||||
|
|
|
|||
3
example/package.json
Normal file
3
example/package.json
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
{
|
||||
"type": "commonjs"
|
||||
}
|
||||
24
package.json
24
package.json
|
|
@ -37,18 +37,18 @@
|
|||
"@actions/exec": "1.1.1"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@commitlint/cli": "19.8.1",
|
||||
"@commitlint/config-conventional": "19.8.1",
|
||||
"@commitlint/cli": "20.2.0",
|
||||
"@commitlint/config-conventional": "20.2.0",
|
||||
"@eslint/js": "9.39.1",
|
||||
"@semantic-release/git": "10.0.1",
|
||||
"@semantic-release/github": "11.0.6",
|
||||
"@semantic-release/npm": "12.0.2",
|
||||
"@semantic-release/github": "12.0.2",
|
||||
"@semantic-release/npm": "13.1.2",
|
||||
"@tsconfig/node20": "20.1.8",
|
||||
"@tsconfig/strictest": "2.0.6",
|
||||
"@types/eslint-config-prettier": "6.11.3",
|
||||
"@types/node": "20.19.25",
|
||||
"@types/node": "20.19.26",
|
||||
"conventional-changelog-conventionalcommits": "9.1.0",
|
||||
"esbuild": "0.27.0",
|
||||
"esbuild": "0.27.1",
|
||||
"eslint": "9.39.1",
|
||||
"eslint-config-prettier": "10.1.8",
|
||||
"eslint-plugin-json": "4.0.1",
|
||||
|
|
@ -56,16 +56,16 @@
|
|||
"husky": "9.1.7",
|
||||
"lint-staged": "16.2.7",
|
||||
"npm-run-all2": "8.0.4",
|
||||
"prettier": "3.6.2",
|
||||
"prettier-plugin-packagejson": "2.5.19",
|
||||
"prettier": "3.7.4",
|
||||
"prettier-plugin-packagejson": "2.5.20",
|
||||
"rimraf": "6.1.2",
|
||||
"semantic-release": "24.2.9",
|
||||
"semantic-release": "25.0.2",
|
||||
"typescript": "5.9.3",
|
||||
"typescript-eslint": "8.47.0"
|
||||
"typescript-eslint": "8.49.0"
|
||||
},
|
||||
"packageManager": "pnpm@10.23.0",
|
||||
"packageManager": "pnpm@10.25.0",
|
||||
"engines": {
|
||||
"node": "^20.9.0 || ^22.11.0",
|
||||
"node": "^20.9.0 || ^22.11.0 || ^24.11.0",
|
||||
"pnpm": "^10.0.0"
|
||||
},
|
||||
"pnpm": {
|
||||
|
|
|
|||
850
pnpm-lock.yaml
generated
850
pnpm-lock.yaml
generated
File diff suppressed because it is too large
Load diff
|
|
@ -1,12 +1,17 @@
|
|||
import { group, notice, setFailed } from '@actions/core';
|
||||
import { Input } from './input';
|
||||
import { Renovate } from './renovate';
|
||||
import { setFailed } from '@actions/core';
|
||||
|
||||
async function run(): Promise<void> {
|
||||
try {
|
||||
const input = new Input();
|
||||
const renovate = new Renovate(input);
|
||||
|
||||
await group('Check Renovate version', async () => {
|
||||
const version = await renovate.runDockerContainerForVersion();
|
||||
notice(version, { title: 'Renovate CLI version' });
|
||||
});
|
||||
|
||||
await renovate.runDockerContainer();
|
||||
} catch (error) {
|
||||
console.error(error);
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
import { exec, getExecOutput } from '@actions/exec';
|
||||
import { Docker } from './docker';
|
||||
import { Input } from './input';
|
||||
import { exec } from '@actions/exec';
|
||||
import fs from 'node:fs/promises';
|
||||
import path from 'node:path';
|
||||
|
||||
|
|
@ -14,6 +14,17 @@ export class Renovate {
|
|||
this.docker = new Docker(input);
|
||||
}
|
||||
|
||||
async runDockerContainerForVersion(): Promise<string> {
|
||||
const command = `docker run -t --rm ${this.docker.image()} --version`;
|
||||
|
||||
const { exitCode, stdout } = await getExecOutput(command);
|
||||
if (exitCode !== 0) {
|
||||
new Error(`'docker run' failed with exit code ${exitCode}.`);
|
||||
}
|
||||
|
||||
return stdout.trim();
|
||||
}
|
||||
|
||||
async runDockerContainer(): Promise<void> {
|
||||
await this.validateArguments();
|
||||
|
||||
|
|
@ -76,7 +87,7 @@ export class Renovate {
|
|||
dockerArguments.push(dockerCmd);
|
||||
}
|
||||
|
||||
const command = `docker run ${dockerArguments.join(' ')}`;
|
||||
const command = `docker run -t ${dockerArguments.join(' ')}`;
|
||||
|
||||
const code = await exec(command);
|
||||
if (code !== 0) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue