Skip to content

Commit afd8c6e

Browse files
committed
Added - artifact publish changes for releash_gh branch
1 parent 3505dbd commit afd8c6e

File tree

2 files changed

+73
-3
lines changed

2 files changed

+73
-3
lines changed

GNUmakefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,6 +111,7 @@ update-version:
111111
ifdef version
112112
sed -i -e 's/ReleaseDate = ".*"/ReleaseDate = "$(release_date)"/g' internal/globalvar/version.go
113113
sed -i -e 's/Version = ".*"/Version = "$(version)"/g' internal/globalvar/version.go && rm -f internal/globalvar/version.go-e
114+
sed -i -e 's/version: ".*"/version: "$(version)"/g' ocibuild.conf && rm -f ocibuild.conf-e
114115
else
115116
@echo Err! `make update-version` requires a version argument
116117
endif

ocibuild.conf

Lines changed: 72 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,12 @@ snapshotVersion: ${shortversion}-SNAPSHOT
1313
version: ${shortversion}${?BLD_BRANCH_SUFFIX}.${BLD_NUMBER}
1414
# A list of branch names, including special branch name 'pull-requests'. Determines which branches will trigger on
1515
# commit to bitbucket.
16-
triggerOnCommitBranches : ["master", "provider_preview", "dev_provider_*"]
16+
17+
triggerOnCommitBranches : ["master","release_gh","provider_preview", "dev_provider_*", "pull-requests"]
1718
# A list of branch names that should run all defined build steps including those which publish artifacts.
1819
# If a branch is not included in the list, it will be a 'dry-run' build and skips any steps that push dependencies,
1920
# runs scanners, or notifies other services, such as pipelines.
20-
releaseBranches: ["master"]
21+
releaseBranches: ["release_gh"]
2122

2223
## Build Service Slack Notification ##
2324
sendNotificationBranches: ["master", "provider_preview"]
@@ -95,4 +96,72 @@ steps:
9596
"**"
9697
]
9798
},
98-
]
99+
{
100+
name: build-terraform-providers-amd64
101+
dependsOn: [unit_test_with_code_coverage]
102+
type: golang
103+
goVersion: 1.21.5
104+
environment:
105+
{
106+
"GOFLAGS": "-mod=vendor",
107+
"GO111MODULE": "",
108+
"GOARCH"="amd64",
109+
"GOOS"="linux",
110+
"CGO_ENABLED"="0"
111+
}
112+
goCommands:
113+
[
114+
{
115+
command: "build",
116+
args: "-v" "-ldflags='-s'" "-o linux_amd64/terraform-provider-oci_v"${version}
117+
}
118+
]
119+
artifacts:
120+
[
121+
"linux_amd64/terraform-provider-oci_v"${version}
122+
]
123+
},
124+
125+
{
126+
name: build-terraform-providers-arm64
127+
dependsOn: [unit_test_with_code_coverage]
128+
type: golang
129+
goVersion: 1.21.5
130+
environment:
131+
{
132+
"GOFLAGS": "-mod=vendor",
133+
"GO111MODULE": "",
134+
"GOARCH"="arm64",
135+
"GOOS"="linux",
136+
"CGO_ENABLED"="0"
137+
}
138+
goCommands:
139+
[
140+
{
141+
command: "build",
142+
args: "-v" "-ldflags='-s '" "-o linux_arm64/terraform-provider-oci_v"${version}
143+
}
144+
]
145+
artifacts:
146+
[
147+
"linux_arm64/terraform-provider-oci_v"${version}
148+
]
149+
},
150+
{
151+
name: publish_shepherd_providers
152+
dependsOn: [build-terraform-providers-amd64, build-terraform-providers-arm64]
153+
type: publishGeneric
154+
repository: odo-artifacts-signed-generic-local
155+
filePathsToPublish:
156+
[
157+
{
158+
localFile: "linux_amd64/terraform-provider-oci_v"${version},
159+
targetDir: "shepherd/terraform-providers/linux_amd64"
160+
},
161+
{
162+
localFile: "linux_arm64/terraform-provider-oci_v"${version},
163+
targetDir: "shepherd/terraform-providers/linux_arm64"
164+
}
165+
]
166+
},
167+
]

0 commit comments

Comments
 (0)