chore: end of the year maintenance
This commit is contained in:
parent
766ed90f26
commit
9ea4b33577
143
.drone.jsonnet
143
.drone.jsonnet
@ -1,143 +1,143 @@
|
|||||||
local PythonVersion(pyversion="3.5") = {
|
local PythonVersion(pyversion='3.5') = {
|
||||||
name: "python" + std.strReplace(pyversion, '.', '') + "-pytest",
|
name: 'python' + std.strReplace(pyversion, '.', '') + '-pytest',
|
||||||
image: "python:" + pyversion,
|
image: 'python:' + pyversion,
|
||||||
pull: "always",
|
pull: 'always',
|
||||||
environment: {
|
environment: {
|
||||||
PY_COLORS: 1
|
PY_COLORS: 1,
|
||||||
},
|
},
|
||||||
commands: [
|
commands: [
|
||||||
"pip install -r test-requirements.txt -qq",
|
'pip install -r test-requirements.txt -qq',
|
||||||
"pip install -qq .",
|
'pip install -qq .',
|
||||||
"drone-cleanup-agents --help",
|
'drone-cleanup-agents --help',
|
||||||
],
|
],
|
||||||
depends_on: [
|
depends_on: [
|
||||||
"clone",
|
'clone',
|
||||||
],
|
],
|
||||||
};
|
};
|
||||||
|
|
||||||
local PipelineLint = {
|
local PipelineLint = {
|
||||||
kind: "pipeline",
|
kind: 'pipeline',
|
||||||
name: "lint",
|
name: 'lint',
|
||||||
platform: {
|
platform: {
|
||||||
os: "linux",
|
os: 'linux',
|
||||||
arch: "amd64",
|
arch: 'amd64',
|
||||||
},
|
},
|
||||||
steps: [
|
steps: [
|
||||||
{
|
{
|
||||||
name: "flake8",
|
name: 'flake8',
|
||||||
image: "python:3.7",
|
image: 'python:3.7',
|
||||||
pull: "always",
|
pull: 'always',
|
||||||
environment: {
|
environment: {
|
||||||
PY_COLORS: 1
|
PY_COLORS: 1,
|
||||||
},
|
},
|
||||||
commands: [
|
commands: [
|
||||||
"pip install -r test-requirements.txt -qq",
|
'pip install -r test-requirements.txt -qq',
|
||||||
"pip install -qq .",
|
'pip install -qq .',
|
||||||
"flake8 ./cleanupagents",
|
'flake8 ./cleanupagents',
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
trigger: {
|
trigger: {
|
||||||
ref: ["refs/heads/master", "refs/tags/**", "refs/pull/**"],
|
ref: ['refs/heads/master', 'refs/tags/**', 'refs/pull/**'],
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
local PipelineTest = {
|
local PipelineTest = {
|
||||||
kind: "pipeline",
|
kind: 'pipeline',
|
||||||
name: "test",
|
name: 'test',
|
||||||
platform: {
|
platform: {
|
||||||
os: "linux",
|
os: 'linux',
|
||||||
arch: "amd64",
|
arch: 'amd64',
|
||||||
},
|
},
|
||||||
steps: [
|
steps: [
|
||||||
PythonVersion(pyversion="3.5"),
|
PythonVersion(pyversion='3.5'),
|
||||||
PythonVersion(pyversion="3.6"),
|
PythonVersion(pyversion='3.6'),
|
||||||
PythonVersion(pyversion="3.7"),
|
PythonVersion(pyversion='3.7'),
|
||||||
PythonVersion(pyversion="3.8"),
|
PythonVersion(pyversion='3.8'),
|
||||||
],
|
],
|
||||||
trigger: {
|
trigger: {
|
||||||
ref: ["refs/heads/master", "refs/tags/**", "refs/pull/**"],
|
ref: ['refs/heads/master', 'refs/tags/**', 'refs/pull/**'],
|
||||||
},
|
},
|
||||||
depends_on: [
|
depends_on: [
|
||||||
"lint",
|
'lint',
|
||||||
],
|
],
|
||||||
};
|
};
|
||||||
|
|
||||||
local PipelineSecurity = {
|
local PipelineSecurity = {
|
||||||
kind: "pipeline",
|
kind: 'pipeline',
|
||||||
name: "security",
|
name: 'security',
|
||||||
platform: {
|
platform: {
|
||||||
os: "linux",
|
os: 'linux',
|
||||||
arch: "amd64",
|
arch: 'amd64',
|
||||||
},
|
},
|
||||||
steps: [
|
steps: [
|
||||||
{
|
{
|
||||||
name: "bandit",
|
name: 'bandit',
|
||||||
image: "python:3.7",
|
image: 'python:3.7',
|
||||||
pull: "always",
|
pull: 'always',
|
||||||
environment: {
|
environment: {
|
||||||
PY_COLORS: 1
|
PY_COLORS: 1,
|
||||||
},
|
},
|
||||||
commands: [
|
commands: [
|
||||||
"pip install -r test-requirements.txt -qq",
|
'pip install -r test-requirements.txt -qq',
|
||||||
"pip install -qq .",
|
'pip install -qq .',
|
||||||
"bandit -r ./cleanupagents -x ./cleanupagents/tests",
|
'bandit -r ./cleanupagents -x ./cleanupagents/tests',
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
depends_on: [
|
depends_on: [
|
||||||
"test",
|
'test',
|
||||||
],
|
],
|
||||||
trigger: {
|
trigger: {
|
||||||
ref: ["refs/heads/master", "refs/tags/**", "refs/pull/**"],
|
ref: ['refs/heads/master', 'refs/tags/**', 'refs/pull/**'],
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
local PipelineBuild = {
|
local PipelineBuild = {
|
||||||
kind: "pipeline",
|
kind: 'pipeline',
|
||||||
name: "build",
|
name: 'build',
|
||||||
platform: {
|
platform: {
|
||||||
os: "linux",
|
os: 'linux',
|
||||||
arch: "amd64",
|
arch: 'amd64',
|
||||||
},
|
},
|
||||||
steps: [
|
steps: [
|
||||||
{
|
{
|
||||||
name: "build",
|
name: 'build',
|
||||||
image: "python:3.7",
|
image: 'python:3.7',
|
||||||
pull: "always",
|
pull: 'always',
|
||||||
commands: [
|
commands: [
|
||||||
"python setup.py sdist bdist_wheel",
|
'python setup.py sdist bdist_wheel',
|
||||||
]
|
|
||||||
},
|
|
||||||
{
|
|
||||||
name: "checksum",
|
|
||||||
image: "alpine",
|
|
||||||
pull: "always",
|
|
||||||
commands: [
|
|
||||||
"cd dist/ && sha256sum * > sha256sum.txt"
|
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: "publish-gitea",
|
name: 'checksum',
|
||||||
image: "plugins/gitea-release",
|
image: 'alpine',
|
||||||
pull: "always",
|
pull: 'always',
|
||||||
|
commands: [
|
||||||
|
'cd dist/ && sha256sum * > sha256sum.txt',
|
||||||
|
],
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: 'publish-gitea',
|
||||||
|
image: 'plugins/gitea-release',
|
||||||
|
pull: 'always',
|
||||||
settings: {
|
settings: {
|
||||||
base_url: "https://gitea.owncloud.services",
|
base_url: 'https://gitea.owncloud.services',
|
||||||
api_key: { "from_secret": "gitea_token"},
|
api_key: { from_secret: 'gitea_token' },
|
||||||
files: ["dist/*", "sha256sum.txt"],
|
files: ['dist/*', 'sha256sum.txt'],
|
||||||
title: "${DRONE_TAG}",
|
title: '${DRONE_TAG}',
|
||||||
note: "CHANGELOG.md",
|
note: 'CHANGELOG.md',
|
||||||
},
|
},
|
||||||
when: {
|
when: {
|
||||||
ref: [ "refs/tags/**" ],
|
ref: ['refs/tags/**'],
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
depends_on: [
|
depends_on: [
|
||||||
"security",
|
'security',
|
||||||
],
|
],
|
||||||
trigger: {
|
trigger: {
|
||||||
ref: ["refs/heads/master", "refs/tags/**", "refs/pull/**"],
|
ref: ['refs/heads/master', 'refs/tags/**', 'refs/pull/**'],
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
@ -147,4 +147,3 @@ local PipelineBuild = {
|
|||||||
PipelineSecurity,
|
PipelineSecurity,
|
||||||
PipelineBuild,
|
PipelineBuild,
|
||||||
]
|
]
|
||||||
|
|
||||||
|
3
.prettierignore
Normal file
3
.prettierignore
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
.drone.yml
|
||||||
|
*.tpl.md
|
||||||
|
LICENSE
|
20
LICENSE
20
LICENSE
@ -1,9 +1,21 @@
|
|||||||
MIT License
|
MIT License
|
||||||
|
|
||||||
Copyright (c) 2019 Robert Kaussow
|
Copyright (c) 2022 Robert Kaussow <mail@thegeeklab.de>
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||||
|
of this software and associated documentation files (the "Software"), to deal
|
||||||
|
in the Software without restriction, including without limitation the rights
|
||||||
|
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||||
|
copies of the Software, and to permit persons to whom the Software is furnished
|
||||||
|
to do so, subject to the following conditions:
|
||||||
|
|
||||||
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
|
The above copyright notice and this permission notice (including the next
|
||||||
|
paragraph) shall be included in all copies or substantial portions of the
|
||||||
|
Software.
|
||||||
|
|
||||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||||
|
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
||||||
|
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS
|
||||||
|
OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
|
||||||
|
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF
|
||||||
|
OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||||
|
Reference in New Issue
Block a user