-
Notifications
You must be signed in to change notification settings - Fork 322
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'release' into 'master'
Merge release into master See merge request passbolt/passbolt-ce-api!113
- Loading branch information
Showing
232 changed files
with
22,233 additions
and
1,061 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
packaging-trigger: | ||
stage: packaging-trigger | ||
variables: | ||
PACKAGING_TRIGGER_BRANCH: "main" | ||
DOWNSTREAM_PROJECT_ID: "$PACKAGING_PROJECT_ID" | ||
image: registry.gitlab.com/passbolt/passbolt-ci-docker-images/debian-bullseye-11-slim:latest | ||
script: | ||
- apt update && apt install -y curl | ||
- bash .gitlab-ci/scripts/packaging-trigger.sh "$CI_COMMIT_TAG" "$PACKAGING_TRIGGER_BRANCH" | ||
rules: | ||
- if: $CI_COMMIT_TAG | ||
when: on_success |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
#!/bin/bash | ||
|
||
# This script receives an passbolt tag and returns the passbolt version semver compliant (without 'v') | ||
# It can handle stable versions eg. v3.11.0 -> 3.11.0 | ||
# and release candiate versions eg. v3.11.0-rc.1 -> 3.11.0-rc.1 | ||
|
||
tag="$1" | ||
branch="$2" | ||
|
||
function is_release_candidate () { | ||
local version=$1 | ||
if [[ ! $version =~ [0-9]+\.[0-9]+\.[0-9]+-rc\.[0-9]+ ]];then | ||
return 1 | ||
fi | ||
return 0 | ||
} | ||
|
||
function parse_tag() { | ||
local tag=$1 | ||
|
||
if is_release_candidate "$tag"; then | ||
echo "$tag" | awk -F '-' '{print $1"-"$2}' | tr -d 'v' | ||
else | ||
echo "$tag" | awk -F '-' '{print $1}' | tr -d 'v' | ||
fi | ||
} | ||
|
||
if [[ $tag == "" ]]; then | ||
echo "Error: tag is empty!" | ||
exit 1 | ||
else | ||
version="$(parse_tag "$tag")" | ||
fi | ||
|
||
echo "Creating the following variables" | ||
echo "=================================" | ||
echo "PASSBOLT_VERSION=${version}" | ||
|
||
passbolt_version="${version}" | ||
|
||
curl -X POST \ | ||
-F token="$PACKAGING_TOKEN" \ | ||
-F "ref=$branch" \ | ||
-F "variables[PASSBOLT_FLAVOUR]=$PASSBOLT_FLAVOUR" \ | ||
-F "variables[PASSBOLT_VERSION]=$passbolt_version" \ | ||
-F "variables[PASSBOLT_BRANCH]=$tag" \ | ||
"https://gitlab.com/api/v4/projects/$DOWNSTREAM_PROJECT_ID/trigger/pipeline" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,70 @@ | ||
<?php | ||
/** | ||
* Passbolt ~ Open source password manager for teams | ||
* Copyright (c) Passbolt SA (https://www.passbolt.com) | ||
* | ||
* Licensed under GNU Affero General Public License version 3 of the or any later version. | ||
* For full copyright and license information, please see the LICENSE.txt | ||
* Redistributions of files must retain the above copyright notice. | ||
* | ||
* @copyright Copyright (c) Passbolt SA (https://www.passbolt.com) | ||
* @license https://opensource.org/licenses/AGPL-3.0 AGPL License | ||
* @link https://www.passbolt.com Passbolt(tm) | ||
* @since 2.13.0 | ||
*/ | ||
|
||
use Migrations\AbstractMigration; | ||
|
||
class V2130AddFoldersTable extends AbstractMigration | ||
{ | ||
/** | ||
* Change Method. | ||
* | ||
* More information on this method is available here: | ||
* http://docs.phinx.org/en/latest/migrations.html#the-change-method | ||
* @return void | ||
*/ | ||
public function change() | ||
{ | ||
$this->table('folders', ['id' => false, 'primary_key' => ['id'], 'collation' => 'utf8mb4_unicode_ci']) | ||
->addColumn('id', 'char', [ | ||
'default' => null, | ||
'limit' => 36, | ||
'null' => false, | ||
'encoding' => 'utf8mb4', | ||
'collation' => 'utf8mb4_unicode_ci' | ||
]) | ||
->addColumn('name', 'string', [ | ||
'default' => null, | ||
'limit' => 64, | ||
'null' => false, | ||
'encoding' => 'utf8mb4', | ||
'collation' => 'utf8mb4_unicode_ci' | ||
]) | ||
->addColumn('created', 'datetime', [ | ||
'default' => null, | ||
'limit' => null, | ||
'null' => false, | ||
]) | ||
->addColumn('modified', 'datetime', [ | ||
'default' => null, | ||
'limit' => null, | ||
'null' => false, | ||
]) | ||
->addColumn('created_by', 'char', [ | ||
'default' => null, | ||
'limit' => 36, | ||
'null' => false, | ||
'encoding' => 'utf8mb4', | ||
'collation' => 'utf8mb4_unicode_ci' | ||
]) | ||
->addColumn('modified_by', 'char', [ | ||
'default' => null, | ||
'limit' => 36, | ||
'null' => false, | ||
'encoding' => 'utf8mb4', | ||
'collation' => 'utf8mb4_unicode_ci' | ||
]) | ||
->create(); | ||
} | ||
} |
53 changes: 53 additions & 0 deletions
53
config/Migrations/20191119092945_V2130AddFoldersHistoryTable.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
<?php | ||
/** | ||
* Passbolt ~ Open source password manager for teams | ||
* Copyright (c) Passbolt SA (https://www.passbolt.com) | ||
* | ||
* Licensed under GNU Affero General Public License version 3 of the or any later version. | ||
* For full copyright and license information, please see the LICENSE.txt | ||
* Redistributions of files must retain the above copyright notice. | ||
* | ||
* @copyright Copyright (c) Passbolt SA (https://www.passbolt.com) | ||
* @license https://opensource.org/licenses/AGPL-3.0 AGPL License | ||
* @link https://www.passbolt.com Passbolt(tm) | ||
* @since 2.13.0 | ||
*/ | ||
|
||
use Migrations\AbstractMigration; | ||
|
||
class V2130AddFoldersHistoryTable extends AbstractMigration | ||
{ | ||
/** | ||
* Change Method. | ||
* | ||
* More information on this method is available here: | ||
* http://docs.phinx.org/en/latest/migrations.html#the-change-method | ||
* @return void | ||
*/ | ||
public function change() | ||
{ | ||
$this->table('folders_history', ['id' => false, 'primary_key' => ['id'], 'collation' => 'utf8mb4_unicode_ci']) | ||
->addColumn('id', 'char', [ | ||
'default' => null, | ||
'limit' => 36, | ||
'null' => false, | ||
'encoding' => 'utf8mb4', | ||
'collation' => 'utf8mb4_unicode_ci' | ||
]) | ||
->addColumn('folder_id', 'char', [ | ||
'default' => null, | ||
'limit' => 36, | ||
'null' => false, | ||
'encoding' => 'utf8mb4', | ||
'collation' => 'utf8mb4_unicode_ci' | ||
]) | ||
->addColumn('name', 'string', [ | ||
'default' => null, | ||
'limit' => 64, | ||
'null' => false, | ||
'encoding' => 'utf8mb4', | ||
'collation' => 'utf8mb4_unicode_ci' | ||
]) | ||
->create(); | ||
} | ||
} |
Oops, something went wrong.