Skip to content

Commit 425a570

Browse files
techknowlogicklunny
andcommitted
use new docker image URLs (#661)
Co-authored-by: Lunny Xiao <[email protected]> Reviewed-on: https://gitea.com/gitea/act_runner/pulls/661 Reviewed-by: Lunny Xiao <[email protected]> Co-authored-by: techknowlogick <[email protected]> Co-committed-by: techknowlogick <[email protected]>
1 parent 4c8179e commit 425a570

File tree

5 files changed

+14
-14
lines changed

5 files changed

+14
-14
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,9 +58,9 @@ INFO Enter the runner token:
5858
fe884e8027dc292970d4e0303fe82b14xxxxxxxx
5959
INFO Enter the runner name (if set empty, use hostname: Test.local):
6060
61-
INFO Enter the runner labels, leave blank to use the default labels (comma-separated, for example, ubuntu-latest:docker://gitea/runner-images:ubuntu-latest):
61+
INFO Enter the runner labels, leave blank to use the default labels (comma-separated, for example, ubuntu-latest:docker://docker.gitea.com/runner-images:ubuntu-latest):
6262
63-
INFO Registering runner, name=Test.local, instance=http://192.168.8.8:3000/, labels=[ubuntu-latest:docker://gitea/runner-images:ubuntu-latest ubuntu-22.04:docker://gitea/runner-images:ubuntu-22.04 ubuntu-20.04:docker://gitea/runner-images:ubuntu-20.04].
63+
INFO Registering runner, name=Test.local, instance=http://192.168.8.8:3000/, labels=[ubuntu-latest:docker://docker.gitea.com/runner-images:ubuntu-latest ubuntu-22.04:docker://docker.gitea.com/runner-images:ubuntu-22.04 ubuntu-20.04:docker://docker.gitea.com/runner-images:ubuntu-20.04].
6464
DEBU Successfully pinged the Gitea instance server
6565
INFO Runner registered successfully.
6666
```

internal/app/cmd/exec.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -484,7 +484,7 @@ func loadExecCmd(ctx context.Context) *cobra.Command {
484484
execCmd.PersistentFlags().BoolVarP(&execArg.noSkipCheckout, "no-skip-checkout", "", false, "Do not skip actions/checkout")
485485
execCmd.PersistentFlags().BoolVarP(&execArg.debug, "debug", "d", false, "enable debug log")
486486
execCmd.PersistentFlags().BoolVarP(&execArg.dryrun, "dryrun", "n", false, "dryrun mode")
487-
execCmd.PersistentFlags().StringVarP(&execArg.image, "image", "i", "gitea/runner-images:ubuntu-latest", "Docker image to use. Use \"-self-hosted\" to run directly on the host.")
487+
execCmd.PersistentFlags().StringVarP(&execArg.image, "image", "i", "docker.gitea.com/runner-images:ubuntu-latest", "Docker image to use. Use \"-self-hosted\" to run directly on the host.")
488488
execCmd.PersistentFlags().StringVarP(&execArg.network, "network", "", "", "Specify the network to which the container will connect")
489489
execCmd.PersistentFlags().StringVarP(&execArg.githubInstance, "gitea-instance", "", "", "Gitea instance to use.")
490490

internal/app/cmd/register.go

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -91,9 +91,9 @@ const (
9191
)
9292

9393
var defaultLabels = []string{
94-
"ubuntu-latest:docker://gitea/runner-images:ubuntu-latest",
95-
"ubuntu-22.04:docker://gitea/runner-images:ubuntu-22.04",
96-
"ubuntu-20.04:docker://gitea/runner-images:ubuntu-20.04",
94+
"ubuntu-latest:docker://docker.gitea.com/runner-images:ubuntu-latest",
95+
"ubuntu-22.04:docker://docker.gitea.com/runner-images:ubuntu-22.04",
96+
"ubuntu-20.04:docker://docker.gitea.com/runner-images:ubuntu-20.04",
9797
}
9898

9999
type registerInputs struct {
@@ -178,7 +178,7 @@ func (r *registerInputs) assignToNext(stage registerStage, value string, cfg *co
178178
}
179179

180180
if validateLabels(r.Labels) != nil {
181-
log.Infoln("Invalid labels, please input again, leave blank to use the default labels (for example, ubuntu-latest:docker://gitea/runner-images:ubuntu-latest)")
181+
log.Infoln("Invalid labels, please input again, leave blank to use the default labels (for example, ubuntu-latest:docker://docker.gitea.com/runner-images:ubuntu-latest)")
182182
return StageInputLabels
183183
}
184184
return StageWaitingForRegistration
@@ -242,7 +242,7 @@ func printStageHelp(stage registerStage) {
242242
hostname, _ := os.Hostname()
243243
log.Infof("Enter the runner name (if set empty, use hostname: %s):\n", hostname)
244244
case StageInputLabels:
245-
log.Infoln("Enter the runner labels, leave blank to use the default labels (comma-separated, for example, ubuntu-latest:docker://gitea/runner-images:ubuntu-latest):")
245+
log.Infoln("Enter the runner labels, leave blank to use the default labels (comma-separated, for example, ubuntu-latest:docker://docker.gitea.com/runner-images:ubuntu-latest):")
246246
case StageWaitingForRegistration:
247247
log.Infoln("Waiting for registration...")
248248
}

internal/pkg/config/config.example.yaml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -33,14 +33,14 @@ runner:
3333
# The interval for fetching the job from the Gitea instance.
3434
fetch_interval: 2s
3535
# The labels of a runner are used to determine which jobs the runner can run, and how to run them.
36-
# Like: "macos-arm64:host" or "ubuntu-latest:docker://gitea/runner-images:ubuntu-latest"
37-
# Find more images provided by Gitea at https://gitea.com/gitea/runner-images .
36+
# Like: "macos-arm64:host" or "ubuntu-latest:docker://docker.gitea.com/runner-images:ubuntu-latest"
37+
# Find more images provided by Gitea at https://gitea.com/docker.gitea.com/runner-images .
3838
# If it's empty when registering, it will ask for inputting labels.
3939
# If it's empty when execute `daemon`, will use labels in `.runner` file.
4040
labels:
41-
- "ubuntu-latest:docker://gitea/runner-images:ubuntu-latest"
42-
- "ubuntu-22.04:docker://gitea/runner-images:ubuntu-22.04"
43-
- "ubuntu-20.04:docker://gitea/runner-images:ubuntu-20.04"
41+
- "ubuntu-latest:docker://docker.gitea.com/runner-images:ubuntu-latest"
42+
- "ubuntu-22.04:docker://docker.gitea.com/runner-images:ubuntu-22.04"
43+
- "ubuntu-20.04:docker://docker.gitea.com/runner-images:ubuntu-20.04"
4444

4545
cache:
4646
# Enable cache server to use actions/cache.

internal/pkg/labels/labels.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ func (l Labels) PickPlatform(runsOn []string) string {
7979
// So the runner receives a task with a label that the runner doesn't have,
8080
// it happens when the user have edited the label of the runner in the web UI.
8181
// TODO: it may be not correct, what if the runner is used as host mode only?
82-
return "gitea/runner-images:ubuntu-latest"
82+
return "docker.gitea.com/runner-images:ubuntu-latest"
8383
}
8484

8585
func (l Labels) Names() []string {

0 commit comments

Comments
 (0)