Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
bobgo-magento-extension
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Bob Public Utils
bobgo-magento-extension
Commits
6562dc4d
Commit
6562dc4d
authored
1 month ago
by
Pieter van Staden
Browse files
Options
Downloads
Patches
Plain Diff
INFRASTRUCTURE :: Update the check to make sure the tag is created from the prod branch
parent
b5b3f5e4
No related branches found
No related tags found
1 merge request
!26
INFRASTRUCTURE :: Update the check to make sure the tag is created from the prod branch
Pipeline
#75164
failed
1 month ago
Stage: tag_deploy
Changes
4
Pipelines
2
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
.gitlab-ci.yml
+10
-7
10 additions, 7 deletions
.gitlab-ci.yml
composer.json
+1
-1
1 addition, 1 deletion
composer.json
etc/module.xml
+1
-1
1 addition, 1 deletion
etc/module.xml
package.json
+1
-1
1 addition, 1 deletion
package.json
with
13 additions
and
10 deletions
.gitlab-ci.yml
+
10
−
7
View file @
6562dc4d
...
...
@@ -33,15 +33,18 @@ tag_deploy:
-
AWS_SECRET_ACCESS_KEY=$(eval echo -e "\$$AWS_SECRET_ACCESS_KEY_KEY")
-
export AWS_ACCESS_KEY_ID
-
export AWS_SECRET_ACCESS_KEY
-
git fetch origin prod
-
TAG_BRANCH=$(git for-each-ref --format='%(refname:short)' --contains $CI_COMMIT_SHA refs/heads/ | grep "^prod$" || echo "")
-
echo "Current branches containing this commit
:
$(git for-each-ref --format='%(refname:short)' --contains $CI_COMMIT_SHA refs/heads/)"
# Ensure all branches and tags are fetched
-
echo "Fetching all branches and tags..."
-
git fetch --all
-
git fetch --tags
# Verify the branch of origin for the tag
-
|
if [ -z "$TAG_BRANCH" ]; then
echo "Tag ${CI_COMMIT_TAG} was not created on the prod branch."
e
xit 1
branch=$(git branch -r --contains "${CI_COMMIT_SHA}" | grep -v 'tags/' | awk '{print $1}' | sed 's/origin\///' | head -n 1)
if [ "$branch" = "prod" ]; then
e
cho "Tag ${CI_COMMIT_TAG} is from the prod branch.";
else
echo "Tag ${CI_COMMIT_TAG} was created on the prod branch."
echo "Tag ${CI_COMMIT_TAG} is not from the prod branch. It was created from the '${branch}' branch.";
exit 1;
fi
script
:
-
"
TAG_ARCHIVE_URL=https://gitlab.bob.co.za/bob-public-utils/bobgo-magento-extension/-/archive/${CI_COMMIT_TAG}/bobgo-magento-extension-${CI_COMMIT_TAG}.zip"
...
...
This diff is collapsed.
Click to expand it.
composer.json
+
1
−
1
View file @
6562dc4d
...
...
@@ -2,7 +2,7 @@
"name"
:
"bobgo/bobgo-magento-extension"
,
"description"
:
"Smart shipping and order management solution in South Africa"
,
"type"
:
"magento2-module"
,
"version"
:
"1.0.5
5
"
,
"version"
:
"1.0.5
6
"
,
"authors"
:
[
{
"name"
:
"Bob Go"
,
...
...
This diff is collapsed.
Click to expand it.
etc/module.xml
+
1
−
1
View file @
6562dc4d
...
...
@@ -7,7 +7,7 @@
*/
-->
<config
xmlns:xsi=
"http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation=
"urn:magento:framework:Module/etc/module.xsd"
>
<module
name=
"BobGroup_BobGo"
setup_version=
"1.0.5
5
"
>
<module
name=
"BobGroup_BobGo"
setup_version=
"1.0.5
6
"
>
<sequence>
<module
name=
"Magento_Webapi"
/>
<module
name=
"Magento_Catalog"
/>
...
...
This diff is collapsed.
Click to expand it.
package.json
+
1
−
1
View file @
6562dc4d
{
"name"
:
"bobgo-magento-plugin"
,
"description"
:
"Bob Go magento plugin"
,
"version"
:
"1.0.5
5
"
,
"version"
:
"1.0.5
6
"
,
"license"
:
"GPL-2.0-or-later"
,
"scripts"
:
{
"prepare"
:
"husky install"
,
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment