• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

jreleaser / jreleaser / #473

30 Mar 2025 10:37AM UTC coverage: 49.208% (-0.01%) from 49.222%
#473

push

github

aalmiray
feat(packagers): Support podman command for building container images

Closes #1816

17 of 46 new or added lines in 7 files covered. (36.96%)

8 existing lines in 3 files now uncovered.

24814 of 50427 relevant lines covered (49.21%)

0.49 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

66.67
/api/jreleaser-model-api/src/main/java/org/jreleaser/model/api/packagers/DockerConfiguration.java
1
/*
2
 * SPDX-License-Identifier: Apache-2.0
3
 *
4
 * Copyright 2020-2025 The JReleaser authors.
5
 *
6
 * Licensed under the Apache License, Version 2.0 (the "License");
7
 * you may not use this file except in compliance with the License.
8
 * You may obtain a copy of the License at
9
 *
10
 *     https://www.apache.org/licenses/LICENSE-2.0
11
 *
12
 * Unless required by applicable law or agreed to in writing, software
13
 * distributed under the License is distributed on an "AS IS" BASIS,
14
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15
 * See the License for the specific language governing permissions and
16
 * limitations under the License.
17
 */
18
package org.jreleaser.model.api.packagers;
19

20
import org.jreleaser.model.api.common.Activatable;
21
import org.jreleaser.model.api.common.Domain;
22
import org.jreleaser.model.api.common.ExtraProperties;
23

24
import java.util.List;
25
import java.util.Locale;
26
import java.util.Map;
27
import java.util.Set;
28

29
import static org.jreleaser.util.StringUtils.isBlank;
30

31
/**
32
 * @author Andres Almiray
33
 * @since 0.4.0
34
 */
35
public interface DockerConfiguration extends Domain, ExtraProperties, Activatable {
36
    String TYPE = "docker";
37

38
    String getTemplateDirectory();
39

40
    List<String> getSkipTemplates();
41

42
    String getBaseImage();
43

44
    Map<String, String> getLabels();
45

46
    Set<String> getImageNames();
47

48
    List<String> getBuildArgs();
49

50
    List<String> getPreCommands();
51

52
    List<String> getPostCommands();
53

54
    Set<? extends Registry> getRegistries();
55

56
    boolean isUseLocalArtifact();
57

58
    DockerCommand getCommand();
59

60
    Buildx getBuildx();
61

62
    enum DockerCommand {
1✔
63
        DOCKER,
1✔
64
        PODMAN;
1✔
65

66
        public static DockerCommand of(String str) {
NEW
67
            if (isBlank(str)) return null;
×
NEW
68
            return DockerCommand.valueOf(str.toUpperCase(Locale.ENGLISH).trim());
×
69
        }
70

71
        public String formatted() {
72
            return name().toLowerCase(Locale.ENGLISH);
1✔
73
        }
74
    }
75

76
    interface Registry extends Domain, Comparable<Registry> {
77
        String getServer();
78

79
        String getServerName();
80

81
        String getRepositoryName();
82

83
        String getUsername();
84

85
        String getPassword();
86

87
        boolean isExternalLogin();
88
    }
89

90
    interface Buildx extends Domain {
91
        boolean isEnabled();
92

93
        boolean isCreateBuilder();
94

95
        List<String> getCreateBuilderFlags();
96

97
        List<String> getPlatforms();
98
    }
99
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc