rpmmd: drop the Name attribute from RepoConfig
This was never actually used anywhere, as passing it to dnf-json was a noop. We may want to reconsider the concept of a source/repo name and how it differs from an ID, but for now drop the name. Signed-off-by: Tom Gundersen <teg@jklm.no>
This commit is contained in:
parent
7ea74cd131
commit
5d179428be
12 changed files with 3 additions and 23 deletions
|
|
@ -33,7 +33,6 @@ func (d *FedoraTestDistro) Repositories(arch string) []rpmmd.RepoConfig {
|
|||
return []rpmmd.RepoConfig{
|
||||
{
|
||||
Id: "test-id",
|
||||
Name: "Test Name",
|
||||
BaseURL: "http://example.com/test/os/" + arch,
|
||||
},
|
||||
}
|
||||
|
|
|
|||
|
|
@ -29,7 +29,6 @@ func (d *TestDistro) Repositories(arch string) []rpmmd.RepoConfig {
|
|||
return []rpmmd.RepoConfig{
|
||||
{
|
||||
Id: "test-id",
|
||||
Name: "Test Name",
|
||||
BaseURL: "http://example.com/test/os/" + arch,
|
||||
},
|
||||
}
|
||||
|
|
|
|||
|
|
@ -5,13 +5,14 @@ package rcm
|
|||
import (
|
||||
"encoding/json"
|
||||
"fmt"
|
||||
"github.com/osbuild/osbuild-composer/internal/common"
|
||||
"github.com/osbuild/osbuild-composer/internal/rpmmd"
|
||||
"log"
|
||||
"net"
|
||||
"net/http"
|
||||
"strings"
|
||||
|
||||
"github.com/osbuild/osbuild-composer/internal/common"
|
||||
"github.com/osbuild/osbuild-composer/internal/rpmmd"
|
||||
|
||||
"github.com/google/uuid"
|
||||
"github.com/julienschmidt/httprouter"
|
||||
"github.com/osbuild/osbuild-composer/internal/blueprint"
|
||||
|
|
@ -139,7 +140,6 @@ func (api *API) submit(writer http.ResponseWriter, request *http.Request, _ http
|
|||
for n, repo := range composeRequest.Repositories {
|
||||
repoConfigs = append(repoConfigs, rpmmd.RepoConfig{
|
||||
Id: fmt.Sprintf("repo-%d", n),
|
||||
Name: fmt.Sprintf("repo-%d", n),
|
||||
BaseURL: repo.URL,
|
||||
IgnoreSSL: false,
|
||||
})
|
||||
|
|
|
|||
|
|
@ -14,7 +14,6 @@ import (
|
|||
|
||||
type RepoConfig struct {
|
||||
Id string `json:"id"`
|
||||
Name string `json:"name"`
|
||||
BaseURL string `json:"baseurl,omitempty"`
|
||||
Metalink string `json:"metalink,omitempty"`
|
||||
MirrorList string `json:"mirrorlist,omitempty"`
|
||||
|
|
|
|||
|
|
@ -969,7 +969,6 @@ func NewSourceConfig(repo rpmmd.RepoConfig, system bool) SourceConfig {
|
|||
func (s *SourceConfig) RepoConfig() rpmmd.RepoConfig {
|
||||
var repo rpmmd.RepoConfig
|
||||
|
||||
repo.Name = s.Name
|
||||
repo.Id = s.Name
|
||||
repo.IgnoreSSL = !s.CheckSSL
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue