mirror of
https://github.com/portainer/portainer.git
synced 2025-07-24 07:49:41 +02:00
* feat(kubernetes): fix duplicate published mode * feat(kubernetes): group port mappings by applications * feat(kubernetes): updated UX * feat(kubernetes): updated UX * feat(kubernetes): new applications list view * fix(kubernetes): applications - expand ports on row click * refactor(kubernetes): applications - replace old view with new * fix(kubernetes): disable access management for default resource pool * feat(kubernetes): app creation - limit stacks suggestion to selected resource pool * feat(kubernetes): do not allow access management on system resource pools * refactor(kubernetes): refactor services * create view node detail * compute node status * compute resource reservations * resource reservation progress bar * create applications node datatable * fix(kubernetes): fix invalid method name * feat(kubernetes): minor UI changes * feat(kubernetes): update application inspect UI * feat(kubernetes): add the ability to copy load balancer IP * fix(kubernetes): minor fixes on applications view * feat(kubernetes): set usage level info on progress bars * fix(kubernetes): fix an issue with duplicate pagination controls * fix(kubernetes): fix an issue with unexpandable items * refacto(kubernetes): clean status and resource computation * fix(kubernetes): remove a bad line * feat(kubernetes): update application detail view * feat(kubernetes): change few things on view * refacto(kubernetes): Corrections relative to PR #13 * refacto(kubernetes): remove old functions * feat(kubernetes): add application pod logs * fix(kubernetes): PR #13 * feat(kubernetes): Enable quotas by default * feat(kubernetes): allow non admin to have access to ressource pool list/detail view * feat(kubernetes): UI changes * fix(kubernetes): fix resource reservation computation in node view * fix(kubernetes): pods are correctly filter by app name * fix(kubernetes): nodeapplicationsdatatable is correctly reorder by cpu and memory * fix(kubernetes): nodeapplications datatable is correctly reorder on reload * feat(kubernetes): update podService * refacto(kubernetes): rename nodeInspect as node * refaceto(kubernetes): use colspan 6 instead of colspan 3 * refacto(kubernetes): use genericdatatablecontroller and make isadmin a binding * refacto(kubernetes): remove not needed lines * refacto(kubernetes) extract usageLevelInfo as html filter * refacto(kubernetes): no line break for params * refacto(kubernetes): change on node converter and filters * refacto(kubernetes): remove bad indentations * feat(kubernetes): add plain text informations about resources limits for non admibn user * refacto(kubernetes): ES6 format * refacto(kubernetes): format * refacto(kubernetes): format * refacto(kubernetes): add refresh callback for nodeapplicationsdatatable * refacto(kubernetes): change if else structure * refactor(kubernetes): files naming and format * fix(kubernetes): remove checkbox and actions on resourcespools view for non admin * feat(kubernetes): minor UI update * fix(kubernetes): bind this on getPodsApplications to allow it to access $async * fix(kubernetes): bind this on getEvents to allow it to access $async * fix(kubernetes): format * feat(kubernetes): minor UI update * feat(kubernetes): add support for container console * fix(kubernetes): fix a merge issue * feat(kubernetes): update container console UI * fix(api): fix typo * feat(api): proxy pod websocket to agent * fix(api): fix websocket pod proxy * refactor(kubernetes): uniformize k8s merge comments * refactor(kubernetes): update consoleController * feat(kubernetes): prevent the removal of the default resource pool (#38) * feat(kubernetes): show all applications running inside the resource pool (#35) * add new datatable * feat(kubernetes): add resource pool applications datatable to resource pool detail view * refacto(kubernetes): factorise computeResourceReservation * fix(kubernetes): colspan 6 to colspan 5 * fix(kubernetes): rename resourceReservationHelper into kubernetesResourceReservationHelper * fix(kubernetes): add await to avoid double diggest cycles * feat(kubernetes): add link to application name * fix(kubernetes): change kubernetes-resource-pool-applications-datatable table key * fix(kubernetes): change wording * feat(kubernetes): add proper support for persisted folders (#36) * feat(kubernetes): persistent volume mockups * feat(kubernetes): persistent volume mockups * feat(kubernetes): update persisted folders mockups * feat(kubernetes): endpoint configure storage access policies * fix(kubernetes): restrict advanced deployment to admin * refactor(kubernetes): storageclass service / rest / model * refactor(kubernetes): params/payload/converter pattern for deployments and daemonsets * feat(kubernetes): statefulset management for applications * fix(kubernets): associate application and pods * feat(kubernetes): statefulset support for applications * refactor(kubernetes): rebase on pportainer/k8s * fix(kubernetes): app create - invalid targetPort on loadbalancer * fix(kubernetes): internal services showed as loadbalancer * fix(kubernetes): service ports creation / parsing * fix(kubernetes): remove ports on headless services + ensure nodePort is used only for Cluster publishing * fix(kubernetes): delete headless service on statefulset delete * fix(kubernetes): statefulset replicas count display * refactor(kubernetes): rebase on pportainer/k8s * refactor(kubernetes): cleanup Co-authored-by: Anthony Lapenna <lapenna.anthony@gmail.com> * fix(kubernetes): remove mockup routes * feat(kubernetes): only display applications running on node/in resource pool when there are any * feat(kubernetes): review resource reservations and leverage requests instead of limits (#40) * fix(kubernetes): filter resource reservation by app in node view (#48) * refactor(kubernetes): remove review comment * chore(version): bump version number * refactor(kubernetes): remove unused stacks view and components * feat(kubernetes): update CPU slider step to 0.1 for resource pools (#60) * feat(kubernetes): round up application CPU values (#61) * feat(kubernetes): add information about application resource reservat… (#62) * feat(kubernetes): add information about application resource reservations * feat(kubernetes): apply kubernetesApplicationCPUValue to application CPU reservation * refactor(kubernetes): services layer with models/converter/payloads (#64) * refactor(kubernetes): services layer with models/converter/payloads * refactor(kubernetes): file rename and comment update * style(kubernetes): replace strings double quotes with simple quotes Co-authored-by: Anthony Lapenna <lapenna.anthony@gmail.com> * fix(kubernetes): filter application by node in node detail view (#69) * fix(kubernetes): filter applications by node * fix(kubernetes): remove js error * refactor(kubernetes): delete resource quota deletion process when deleting a resource pool (#68) * feat(kubernetes): enforce valid resource reservations and clarify its… (#70) * feat(kubernetes): enforce valid resource reservations and clarify its usage * feat(kubernetes): update instance count input behavior * feat(kubernetes): resource pools labels (#71) * feat(kubernetes): resource pools labels * fix(kubernetes): RP/RQ/LR owner label * feat(kubernetes): confirmation popup on RP delete (#76) * feat(kubernetes): application labels (#72) * feat(kubernetes): application labels * feat(kubernetes): display application owner in details when available * style(kubernetes): revert StackName column labels * fix(kubernetes): default displayed StackName * feat(kubernetes): remove RQ query across cluster (#73) * refactor(kubernetes): routes as components (#75) * refactor(kubernetes): routes as components * refactor(kubernetes): use component lifecycle hook * refactor(kubernetes): files naming consistency * fix(kubernetes): fix invalid component name for cluster view Co-authored-by: Anthony Lapenna <lapenna.anthony@gmail.com> * feat(kubernetes): update portaineruser cluster role policy rules (#78) * refactor(kubernetes): remove unused helper * fix(kubernetes): fix invalid reload link in cluster view * feat(kubernetes): add cluster resource reservation (#77) * feat(kubernetes): add cluster resource reservation * fix(kubernetes): filter resource reservation with applications * fix(kubernetes): fix indent * refacto(kubernetes): extract megabytes value calc as resourceReservationHelper method * fix(kubernetes): remove unused import * refacto(kubernetes): add resourcereservation model * fix(kubernetes): add parenthesis on arrow functions parameters * refacto(kubernetes): getpods in applicationService getAll * fix(kubernetes): let to const * fix(kubernetes): remove unused podservice * fix(kubernetes): fix computeResourceReservation * fix(kubernetes): app.pods to app.Pods everywhere and camelcase of this.ResourceReservation * feat(kubernetes): configurations list view (#74) * feat(kubernetes): add configuration list view * feat(kubernetes): add configurations datatable * feat(kubernetes): add item selection * feat(kubernetes): allow to remove configuration * feat(kubernetes): allow non admin user to see configurations * fix(kubernetes): configurations view as component * feat(kubernetes): remove stack property for secret and configurations * fix(kubernetes): update import * fix(kubernetes): remove secret delete payload * fix(kubernetes): rename configuration model * fix(kubernetes): remove configmap delete payload * fix(Kubernetes): fix configuration getAsync * fix(kubernetes): extract params as variables * refacto(kubernetes): extract configurations used lines as helper * fix(kubernetes): add verification of _.find return value * fix(kubernetes): fix kubernetes configurations datatable callback * refacto(Kubernetes): extract find before if * fix(kubernetes): replace this by KubernetesConfigurationHelper in static method * fix(Kubernetes): fix getASync Co-authored-by: Anthony Lapenna <lapenna.anthony@gmail.com> * review(kubernetes): todo comments (#80) * feat(kubernetes): minor UI update * feat(kubernetes): round max cpu value in application creation * feat(kubernetes): minor UI update * fix(kubernetes): no-wrap resource reservation bar text (#89) * docs(kubernetes): add review for formValues to resource conversion (#91) * feat(kubernetes): configuration creation view (#82) * feat(kubernetes): create configuration view * feat(kubernetes): add advanced mode and create entry from file * fix(kubernetes): fix validation issues * fix(kubernetes): fix wording * fix(kubernetes): replace data by stringdata in secret payloads * fix(kubernetes): rename KubernetesConfigurationEntry to KubernetesConfigurationFormValuesDataEntry * refacto(kubernetes): add isSimple to formValues and change configuration creation pattern * fix(kubernetes): fix some bugs * refacto(kubernetes): renaming * fix(kubernetes): fix few bugs * fix(kubernetes): fix few bugs * review(kubernetes): refactor notices Co-authored-by: xAt0mZ <baron_l@epitech.eu> * feat(kubernetes): rename codeclimate file * feat(kubernetes): re-enable codeclimate * feat(project): update codeclimate configuration * feat(project): update codeclimate configuration * feat(project): update codeclimate configuration * feat(kubernetes): minor UI update * feat(project): update codeclimate * feat(project): update codeclimate configuration * feat(project): update codeclimate configuration * feat(kubernetes): configuration details view (#93) * feat(kubernetes): configuration details view * fix(kubernetes): fix wording * fix(kubernetes): fix update button * fix(kubernetes): line indent * refacto(kubernetes): remove conversion * refacto(kubernetes): remove useless line * refacto(kubernetes): remove useless lines * fix(kubernetes): revert error handling * fix(kubernetes): fix wording * fix(kubernetes): revert line deletion * refacto(kubernetes): change data mapping * fix(kubernetes): create before delete * fix(kubernetes): fix duplicate bug * feat(kubernetes): configurations in application creation (#92) * feat(kubernetes): application configuration mockups * feat(kubernetes): update mockup * feat(kubernetes): app create - dynamic view for configurations * feat(kubernetes): app create - configuration support * refactor(kubernetes): more generic configuration conversion function Co-authored-by: Anthony Lapenna <lapenna.anthony@gmail.com> * feat(kubernetes): automatically display first entry in configuration creation * feat(kubernetes): minor UI update regarding applications and configurations * feat(kubernetes): update Cluster icon in sidebar * feat(kubernetes): volumes list view (#112) * feat(kubernetes): add a feedback panel on main views (#111) * feat(kubernetes): add a feedback panel on main views * feat(kubernetes): add feedback panel to volumes view * fix(kubernetes): isolated volumes showed as unused even when used (#116) * feat(kubernetes): remove limit range from Portainer (#119) * limits instead of requests (#121) * feat(kubernetes): volume details (#117) * feat(kubernetes): volume details * fix(kubernetes): yaml not showed * feat(kubernetes): expandable stacks list (#122) * feat(kubernetes): expandable stacks list * feat(kubernetes): minor UI update to stacks datatable Co-authored-by: Anthony Lapenna <lapenna.anthony@gmail.com> * feat(kubernetes): uibprogress font color (#129) * feat(kubernetes): minor UI update to resource reservation component * feat(kubernetes): automatically select a configuration * refactor(kubernetes): remove comment * feat(kubernetes): minor UI update * feat(kubernetes): add resource links and uniformize view headers (#133) * feat(kubernetes): prevent removal of system configurations (#128) * feat(kubernetes): prevent removal of system configurations * fix(kubernetes): KubernetesNamespaceHelper is not a function * refacto(kubernetes): change prevent removal pattern * fix(kubernetes): remove unused dependencies * fix(kubernetes): fix configuration used label (#123) * fix(kubernetes): fix used configurations * fix(kubernetes): remove console log * feat(kubernetes): rename configuration types (#127) * refacto(kubernetes): fix wording and use configMap instead of Basic in the code * feat(kubernetes): prevent the removal of system configuration * fix(kubernetes): remove feat on bad branch * fix(kubernetes): rename configuration types * refacto(kubernetes): use a numeric enum and add a filter to display the text type * refacto(kubernetes): fix wording and use configMap instead of Basic in the code * feat(kubernetes): prevent the removal of system configuration * fix(kubernetes): remove feat on bad branch * fix(kubernetes): rename configuration types * refacto(kubernetes): use a numeric enum and add a filter to display the text type * fix(kubernetes): rename file and not use default in switch case * feat(kubernetes): update advanced deployment UI/UX (#130) * feat(kubernetes): update advanced deployment UI/UX * feat(kubernetes): review HTML tags indentation * feat(kubernetes): applications stacks delete (#135) * fix(kubernetes): multinode resources reservations (#118) * fix(kubernetes): filter pods by node * fix(kubernetes): fix applications by node filter * fix(kubernetes): filter pods by node * Update app/kubernetes/views/cluster/node/nodeController.js Co-authored-by: Anthony Lapenna <anthony.lapenna@portainer.io> * feat(kubernetes): limit usage of pod console view (#136) * feat(kubernetes): add yaml and events to configuration details (#126) * feat(kubernetes): add yaml and events to configuration details * fix(kubernetes): fix errors on secret details view * fix(kubernetes): display only events related to configuration * fix(kubernetes): fix applications by node filter * fix(kubernetes): revert commit on bad branch * refacto(kubernetes): refacto configmap get yaml function * refacto(kubernetes): add yaml into converter * feat(kubernetes): improve application details (#141) * refactor(kubernetes): remove applications retrieval from volume service * feat(kubernetes): improve application details view * feat(kubernetes): update kompose binary version (#143) * feat(kubernetes): update kubectl version (#144) * refactor(kubernetes): rename portainer system namespace (#145) * feat(kubernetes): add a loading view indicator (#140) * feat(kubernetes): add an example of view loading indicator * refactor(css): remove comment * feat(kubernetes): updated loading pattern * feat(kubernetes): add loading indicator for resource pool views * feat(kubernetes): add loading indicator for deploy view * feat(kubernetes): add loading view indicator to dashboard * feat(kubernetes): add loading view indicator to configure view * feat(kubernetes): add loading indicator to configuration views * feat(kubernetes): add loading indicator to cluster views * feat(kubernetes): rebase on k8s branch * feat(kubernetes): update icon size * refactor(kubernetes): update indentation and tag format * feat(kubernetes): backend role validation for stack deployment (#147) * feat(kubernetes): show applications when volume is used * feat(kubernetes): set empty value when node is not set * feat(kubernetes): update configuration UI/UX * feat(kubernetes): update configuration UX * fix(kubernetes): Invalid value for a configuration (#139) * fix(kubernetes): Invalid value for a configuration * fix(kubernetes): remove auto JSON convertion for configMap ; apply it for RPool Accesses only * refactor(kubernetes): remove unneeded line * fix(kubernetes): remove default JSON parsing on configMap API retrieval Co-authored-by: xAt0mZ <baron_l@epitech.eu> * feat(kubernetes): applications table in configuration details (#154) * feat(kubernetes): Add the ability to filter system resources (#142) * feat(kubernetes): hide system configurations * feat(kubernetes): Add the ability to filter system resources * feat(kubernetes): add the ability to hide system resources on volumes * fix(kubernetes): fix few issue in volumesDatatableController * fix(kubernetes): fix applications / ports / stacks labels * feat(kubernetes): add volumes and configurations to dashboard (#152) * feat(kubernetes): event warning indicator (#150) * feat(kubernetes): event warning indicator for applications * refactor(kubernetes): refactor events indicator logic * feat(kubernetes): add event warning indicator to all resources * feat(kubernetes): fix missing YAML panel for node (#157) * feat(kubernetes): revised application details view (#159) * feat(kubernetes): revised application details view * refactor(kubernetes): remove comment * feat(kubernetes): rebase on k8s * refactor(kubernetes): remove extra line * feat(kubernetes): update kubernetes beta feedback panel locations (#161) * feat(kubernetes): stack logs (#160) * feat(kubernetes): stack logs * fix(kubernetes): ignore starting pods * fix(kubernetes): colspan on expandable stack applications table * feat(kubernetes): add an information message about system resources (#163) * fix(kubernetes): fix empty panel being display in cluster view (#165) * fix(kubernetes): Invalid CPU unit for node (#156) * fix(kubernetes): Invalid CPU unit for node * fix(kubernetes): Invalid CPU unit for node * refacto(kubernetes): extract parseCPU function in helper * refacto(kubernetes): rewrite parseCPU function * feat(kubernetes): add the kube-node-lease namespace to system namespaces (#177) * feat(kubernetes): tag system applications on node details view (#175) * feat(kubernetes): tag system applications on node details view * fix(kubernetes): remove system resources filter * feat(kubernetes): review UI/UX around volume size unit (#178) * feat(kubernetes): updates after review (#174) * feat(kubernetes): update access user message * feat(kubernetes): relocate resource pool to a specific form section * feat(kubernetes): review responsiveness of port mappings * feat(kubernetes): clarify table settings * feat(kubernetes): add resource reservation summary message * feat(kubernetes): review wording (#182) * feat(kubernetes): application stack edit (#179) * feat(kubernetes): update UI -- update action missing * feat(kubernetes): application stack update * feat(kubernetes): change services stacks * feat(kubernetes): hide default-tokens + prevent remove (#183) * feat(kubernetes): hide default-tokens + prevent remove * feat(kubernetes): do not display unused label for system configurations * fix(kubernetes): minor fix around showing system configurations Co-authored-by: Anthony Lapenna <lapenna.anthony@gmail.com> * feat(kubernetes): rebase on k8s branch (#180) * fix(kubernetes): prevent the display of system resources in dashboard (#186) * fix(kubernetes): prevent the display of system resources in dashboard * fix(kubernetes): prevent the display of frontend filtered resource pools * feat(kubernetes): support downward API for env vars in application details (#181) * feat(kubernetes): support downward API for env vars in application details * refactor(kubernetes): remove comment * feat(kubernetes): minor UI update * feat(kubernetes): remove Docker features (#189) * chore(version): bump version number (#187) * chore(version): bump version number * feat(kubernetes): disable update notice * feat(kubernetes): minor UI update * feat(kubernetes): minor UI update * feat(kubernetes): form validation (#170) * feat(kubernetes): add published node port value check * feat(kubernetes): add a dns compliant validation * fix(kubernetes): fix port range validation * feat(kubernetes): lot of form validation * feat(kubernetes): add lot of form validation * feat(kubernetes): persisted folders size validation * feat(kubernetes): persisted folder path should be unique * fix(kubernetes): fix createResourcePool button * fix(kubernetes): change few things * fix(kubernetes): fix slider memory * fix(kubernetes): fix duplicates on dynamic field list * fix(kubernetes): remove bad validation on keys * feat(kubernetes): minor UI enhancements and validation updates * feat(kubernetes): minor UI update * fix(kubernetes): revert on slider fix * review(kubernetes): add future changes to do * fix(kubernetes): add form validation on create application memory slider Co-authored-by: Anthony Lapenna <lapenna.anthony@gmail.com> Co-authored-by: xAt0mZ <baron_l@epitech.eu> * feat(kubernetes): remove Docker related content * feat(kubernetes): update build system to remove docker binary install * fix(kubernetes): fix an issue with missing user settings * feat(kubernetes): created column for apps and resource pools (#184) * feat(kubernetes): created column for apps and resource pools * feat(kubernetes): configurations and volumes owner * feat(kubernetes): rename datatables columns * fix(kubernetes): auto detect statefulset headless service name (#196) * fix(applications): display used configurations (#198) * feat(kubernetes): app details - display data access policy (#199) * feat(kubernetes): app details - display data access policy * feat(kubernetes): tooltip on data access info * feat(kubernetes): move DAP tooltip to end of line * feat(kubernetes): minor UI update Co-authored-by: Anthony Lapenna <lapenna.anthony@gmail.com> * fix(kubernetes): fix an issue when updating the local endpoint (#204) * fix(kubernetes): add unique key to configuration overriden key path field (#207) * feat(kubernetes): tag applications as external (#221) * feat(kubernetes): tag applications as external first approach * feat(kubernetes): tag applications as external * feat(kubernetes): Use ibytes as the default volume size unit sent to the Kubernetes API (#222) * feat(kubernetes): Use ibytes as the default volume size unit sent to the Kubernetes API * fix(kubernetes): only display b units in list and details views * feat(kubernetes): add note to application details (#212) * feat(kubernetes): add note to application details * fix(kubernetes): remove eslintcache * feat(kubernetes): update application note UI * feat(kubernetes): add an update button to the note form when a note is already associated to an app * feat(kubernetes): fix with UI changes * fix(kubernetes): change few things * fix(kubernetes): remove duplicate button * fix(kubernetes): just use a ternary Co-authored-by: Anthony Lapenna <lapenna.anthony@gmail.com> * feat(kubernetes): fix data persistence display for isolated DAP (#223) * feat(kubernetes): add a quick action to copy application name to clipboard (#225) * feat(kubernetes): revert useless converter changes (#228) * feat(kubernetes): edit application view (#200) * feat(kubernetes): application to formValues conversion * feat(kubernetes): extract applicationFormValues conversion as converter function * feat(kubernetes): draft app patch * feat(kubernetes): patch on all apps services + service service + pvc service * feat(kubernetes): move name to labels and use UUID as kubernetes Name + patch recreate if necessary * feat(kubernetes): move user app name to label and use UUID for Kubernetes Name field * feat(kubernetes): kubernetes service patch mechanism * feat(kubernetes): application edit * feat(kubernetes): remove stack edit on app details * feat(kubernetes): revert app name saving in label - now reuse kubernetes Name field * feat(kubernetes): remove the ability to edit the DAP * feat(kubernetes): cancel button on edit view * feat(kubernetes): remove ability to add/remove persisted folders for SFS edition * feat(kubernetes): minor UI update and action changes * feat(kubernetes): minor UI update * feat(kubernetes): remove ability to edit app volumes sizes + disable update button if no changes are made + codeclimate * fix(kubernetes): resource reservation sliders in app edit * fix(kubernetes): patch returned with 422 when trying to create nested objects * fix(kubernetes): changing app deployment type wasn't working (delete failure) * style(kubernetes): codeclimate * fix(kubernetes): app edit - limits sliders max value * feat(kubernetes): remove prefix on service name as we enforce DNS compliant app names * fix(kubernetes): edit app formvalues replica based on target replica count and not total pods count * fix(kubernetes): disable update for RWO on multi replica + delete service when changing app type * fix(kubernetes): app details running / target pods display * feat(kubernetes): add partial patch for app details view Co-authored-by: Anthony Lapenna <lapenna.anthony@gmail.com> * feat(kubernetes): disable edit capability for external and system apps (#233) * feat(kubernetes): minor UI update * fix(kubernetes): edit application issues (#235) * feat(kubernetes): disable edition of load balancer if it's in pending state * fix(kubernetes): now able to change from LB to other publishing types * feat(kuberntes): modal on edit click to inform on potential service interruption * feat(kubernetes): hide note when empty + add capability to collapse it * fix(kubernetes): UI/API desync + app update button enabled in some cases where it shouldn't be * fix(kubernetes): all apps are now using rolling updates with specific conditions * style(kubernetes): code indent * fix(kubernetes): disable sync process on endpoint init as current endpoint is not saved in client state * fix(kubernetes): sliders refresh on app create + app details bad display for sfs running pods * feat(kubernetes): minor UI update Co-authored-by: Anthony Lapenna <lapenna.anthony@gmail.com> * feat(kubernetes): bump up kubectl version to v1.18.0 * feat(kubernetes): when refreshing a view, remember currently opened tabs (#226) * feat(kubernetes): When refreshing a view, remember currently opened tabs * fix(kubernetes): only persist the current tab inside the actual view * fix(kubernetes): not working with refresh in view header * fix(kubernetes): skip error on 404 headless service retrieval if missconfigured in sfs (#242) * refactor(kubernetes): use KubernetesResourcePoolService instead of KubernetesNamespaceService (#243) * fix(kubernetes): create service before app to enforce port availability (#239) * fix(kubernetes): external flag on application ports mappings datatable (#245) * refactor(kubernetes): remove unused KubernetesResourcePoolHelper (#246) * refactor(kubernetes): make all *service.getAllAsync functions consistent (#249) * feat(kubernetes): Tag external applications in the application table of the resource pool details view (#251) * feat(kubernetes): add ability to redeploy application (#240) * feat(kubernetes): add ability to redeploy application * feat(kubernetes): allow redeploy for external apps * Revert "feat(kubernetes): allow redeploy for external apps" This reverts commit 093375a7e93c1a07b845ebca1618da034a97fbcd. * refactor(kubernetes): use KubernetesPodService instead of REST KubernetesPods (#247) * feat(kubernetes): prevent configuration properties edition (#248) * feat(kubernetes): prevent configuration properties edition * feat(kubernetes): Relocate the Data/Actions to a separate panel * feat(kubernetes): remove unused functions * feat(kubernetes): minor UI update Co-authored-by: Anthony Lapenna <lapenna.anthony@gmail.com> * refactor(kubernetes): Simplify the FileReader usage (#254) * refactor(kubernetes): simplify FileReader usage * refactor(kubernetes): Simplify FileReader usage * refactor(kubernetes): rename e as event for readability * feat(kubernetes): Tag system Configs in the Config details view (#257) * refactor(kubernetes): Refactor the isFormValid function of multiple controllers (#253) * refactor(kubernetes): refactor isFormValid functions in configurations * refactor(kubernetes): refactor isformValid functions in create application * refactor(kubernetes): remove duplicate lines * refactor(kubernetes): remove commented line * feat(kubernetes): Tag external volumes and configs (#250) * feat(kubernetes): Tag external volumes and configs * feat(kubernetes): remove .eslintcache * feat(kubernetes): change few things * feat(kubernetes): don't tag system configuration as external * feat(kubernetes): minor UI update * feat(kubernetes): extract inline css and clean all tags Co-authored-by: Anthony Lapenna <lapenna.anthony@gmail.com> * fix(kubernetes): daemon set edit (#258) * fix(kubernetes): persistent folder unit parsing * fix(kubernetes): edit daemonset on RWO storage * fix(kubernetes): external SFS had unlinked volumes (#264) * feat(kubernetes): prevent to override two different configs on the same filesystem path (#259) * feat(kubernetes): prevent to override two different configs on the same filesystem path * feat(kubernetes): The validation should only be triggered across Configurations. * feat(kubernetes): fix validations issues * feat(kubernetes): fix form validation * feat(kubernetes): fix few things * refactor(kubernetes): Review the code mirror component update for configurations (#260) * refactor(kubernetes): extract duplicate configuration code into a component * refactor(kubernetes): fix form validation issues * refactor(kubernetes): fix missing value * refactor(kubernetes): remove useless await * feat(kubernetes): Update the shared access policy configuration for Storage (#263) * feat(kubernetes): Update the shared access policy configuration for Storage * Update app/kubernetes/models/storage-class/models.js * feat(kubernetes): remove ROX references and checks Co-authored-by: Anthony Lapenna <anthony.lapenna@portainer.io> Co-authored-by: xAt0mZ <baron_l@epitech.eu> * feat(kubernetes): provide the remove/restore UX for environment variables when editing an application (#261) * feat(kubernetes): Provide the remove/restore UX for environment variables when editing an application * feat(kubernetes): fix ui issue * feat(kubernetes): change few things * fix(kubernetes): Invalid display for exposed ports in accessing the application section (#267) * feat(kubernetes): application rollback (#269) * feat(kubernetes): retrieve all versions of a deployment * feat(kubernetes): application history for all types * feat(kubernetes): deployment rollback * feat(kubernetes): daemonset / statefulset rollback * feat(kubernetes): remove the revision selector and rollback on previous version everytime * feat(kubernetes): minor UI changes Co-authored-by: Anthony Lapenna <lapenna.anthony@gmail.com> * feat(kubernetes): reservations should be computed based on requests instead of limits (#268) * feat(kubernetes): Reservations should be computed based on requests instead of limits * feat(kubernetes): use requests instead of limits in application details * feat(kubernetes): removes unused limits * feat(kubernetes): Not so useless * feat(kubernetes): use service selectors to bind apps and services (#270) * feat(kubernetes): use service selectors to bind apps and services * Update app/kubernetes/services/statefulSetService.js * style(kubernetes): remove comment block Co-authored-by: Anthony Lapenna <anthony.lapenna@portainer.io> * chore(version): bump version number * feat(kubernetes): update feedback panel text * chore(app): add prettier to k8s * style(app): apply prettier to k8s codebase * fix(kubernetes): Cannot read property 'port' of undefined (#272) * fix(kubernetes): Cannot read property 'port' of undefined * fix(kubernetes): concat app ports outside publishedports loop * fix(application): fix broken display of the persistence layer (#274) * chore(kubernetes): fix conflicts * chore(kubernetes): fix issues related to conflict resolution * refactor(kubernetes): refactor code related to conflict resolution * fix(kubernetes): fix a minor issue with assets import * chore(app): update yarn.lock * fix(application): ports mapping are now correctly detected (#300) * fix(build-system): fix missing docker binary download step * feat(kubernetes): application auto scaling details (#301) * feat(kubernetes): application auto scaling details * feat(kubernetes): minor UI update Co-authored-by: Anthony Lapenna <lapenna.anthony@gmail.com> * feat(kubernetes): Introduce a "used by" column in the volume list view (#303) Co-authored-by: xAt0mZ <baron_l@epitech.eu> Co-authored-by: Maxime Bajeux <max.bajeux@gmail.com> Co-authored-by: xAt0mZ <xAt0mZ@users.noreply.github.com>
1510 lines
65 KiB
Go
1510 lines
65 KiB
Go
package portainer
|
|
|
|
import (
|
|
"io"
|
|
"time"
|
|
)
|
|
|
|
type (
|
|
// AccessPolicy represent a policy that can be associated to a user or team
|
|
AccessPolicy struct {
|
|
RoleID RoleID `json:"RoleId"`
|
|
}
|
|
|
|
// APIOperationAuthorizationRequest represent an request for the authorization to execute an API operation
|
|
APIOperationAuthorizationRequest struct {
|
|
Path string
|
|
Method string
|
|
Authorizations Authorizations
|
|
}
|
|
|
|
// AuthenticationMethod represents the authentication method used to authenticate a user
|
|
AuthenticationMethod int
|
|
|
|
// Authorization represents an authorization associated to an operation
|
|
Authorization string
|
|
|
|
// Authorizations represents a set of authorizations associated to a role
|
|
Authorizations map[Authorization]bool
|
|
|
|
// AzureCredentials represents the credentials used to connect to an Azure
|
|
// environment.
|
|
AzureCredentials struct {
|
|
ApplicationID string `json:"ApplicationID"`
|
|
TenantID string `json:"TenantID"`
|
|
AuthenticationKey string `json:"AuthenticationKey"`
|
|
}
|
|
|
|
// CLIFlags represents the available flags on the CLI
|
|
CLIFlags struct {
|
|
Addr *string
|
|
TunnelAddr *string
|
|
TunnelPort *string
|
|
AdminPassword *string
|
|
AdminPasswordFile *string
|
|
Assets *string
|
|
Data *string
|
|
EnableEdgeComputeFeatures *bool
|
|
EndpointURL *string
|
|
Labels *[]Pair
|
|
Logo *string
|
|
NoAnalytics *bool
|
|
Templates *string
|
|
TLS *bool
|
|
TLSSkipVerify *bool
|
|
TLSCacert *string
|
|
TLSCert *string
|
|
TLSKey *string
|
|
SSL *bool
|
|
SSLCert *string
|
|
SSLKey *string
|
|
SnapshotInterval *string
|
|
}
|
|
|
|
// DockerHub represents all the required information to connect and use the
|
|
// Docker Hub
|
|
DockerHub struct {
|
|
Authentication bool `json:"Authentication"`
|
|
Username string `json:"Username"`
|
|
Password string `json:"Password,omitempty"`
|
|
}
|
|
|
|
// DockerSnapshot represents a snapshot of a specific Docker endpoint at a specific time
|
|
DockerSnapshot struct {
|
|
Time int64 `json:"Time"`
|
|
DockerVersion string `json:"DockerVersion"`
|
|
Swarm bool `json:"Swarm"`
|
|
TotalCPU int `json:"TotalCPU"`
|
|
TotalMemory int64 `json:"TotalMemory"`
|
|
RunningContainerCount int `json:"RunningContainerCount"`
|
|
StoppedContainerCount int `json:"StoppedContainerCount"`
|
|
HealthyContainerCount int `json:"HealthyContainerCount"`
|
|
UnhealthyContainerCount int `json:"UnhealthyContainerCount"`
|
|
VolumeCount int `json:"VolumeCount"`
|
|
ImageCount int `json:"ImageCount"`
|
|
ServiceCount int `json:"ServiceCount"`
|
|
StackCount int `json:"StackCount"`
|
|
SnapshotRaw DockerSnapshotRaw `json:"DockerSnapshotRaw"`
|
|
}
|
|
|
|
// DockerSnapshotRaw represents all the information related to a snapshot as returned by the Docker API
|
|
DockerSnapshotRaw struct {
|
|
Containers interface{} `json:"Containers"`
|
|
Volumes interface{} `json:"Volumes"`
|
|
Networks interface{} `json:"Networks"`
|
|
Images interface{} `json:"Images"`
|
|
Info interface{} `json:"Info"`
|
|
Version interface{} `json:"Version"`
|
|
}
|
|
|
|
// EdgeGroup represents an Edge group
|
|
EdgeGroup struct {
|
|
ID EdgeGroupID `json:"Id"`
|
|
Name string `json:"Name"`
|
|
Dynamic bool `json:"Dynamic"`
|
|
TagIDs []TagID `json:"TagIds"`
|
|
Endpoints []EndpointID `json:"Endpoints"`
|
|
PartialMatch bool `json:"PartialMatch"`
|
|
}
|
|
|
|
// EdgeGroupID represents an Edge group identifier
|
|
EdgeGroupID int
|
|
|
|
// EdgeJob represents a job that can run on Edge environments.
|
|
EdgeJob struct {
|
|
ID EdgeJobID `json:"Id"`
|
|
Created int64 `json:"Created"`
|
|
CronExpression string `json:"CronExpression"`
|
|
Endpoints map[EndpointID]EdgeJobEndpointMeta `json:"Endpoints"`
|
|
Name string `json:"Name"`
|
|
ScriptPath string `json:"ScriptPath"`
|
|
Recurring bool `json:"Recurring"`
|
|
Version int `json:"Version"`
|
|
}
|
|
|
|
// EdgeJobEndpointMeta represents a meta data object for an Edge job and Endpoint relation
|
|
EdgeJobEndpointMeta struct {
|
|
LogsStatus EdgeJobLogsStatus
|
|
CollectLogs bool
|
|
}
|
|
|
|
// EdgeJobID represents an Edge job identifier
|
|
EdgeJobID int
|
|
|
|
// EdgeJobLogsStatus represent status of logs collection job
|
|
EdgeJobLogsStatus int
|
|
|
|
// EdgeSchedule represents a scheduled job that can run on Edge environments.
|
|
// Deprecated in favor of EdgeJob
|
|
EdgeSchedule struct {
|
|
ID ScheduleID `json:"Id"`
|
|
CronExpression string `json:"CronExpression"`
|
|
Script string `json:"Script"`
|
|
Version int `json:"Version"`
|
|
Endpoints []EndpointID `json:"Endpoints"`
|
|
}
|
|
|
|
//EdgeStack represents an edge stack
|
|
EdgeStack struct {
|
|
ID EdgeStackID `json:"Id"`
|
|
Name string `json:"Name"`
|
|
Status map[EndpointID]EdgeStackStatus `json:"Status"`
|
|
CreationDate int64 `json:"CreationDate"`
|
|
EdgeGroups []EdgeGroupID `json:"EdgeGroups"`
|
|
ProjectPath string `json:"ProjectPath"`
|
|
EntryPoint string `json:"EntryPoint"`
|
|
Version int `json:"Version"`
|
|
Prune bool `json:"Prune"`
|
|
}
|
|
|
|
//EdgeStackID represents an edge stack id
|
|
EdgeStackID int
|
|
|
|
//EdgeStackStatus represents an edge stack status
|
|
EdgeStackStatus struct {
|
|
Type EdgeStackStatusType `json:"Type"`
|
|
Error string `json:"Error"`
|
|
EndpointID EndpointID `json:"EndpointID"`
|
|
}
|
|
|
|
//EdgeStackStatusType represents an edge stack status type
|
|
EdgeStackStatusType int
|
|
|
|
// Endpoint represents a Docker endpoint with all the info required
|
|
// to connect to it
|
|
Endpoint struct {
|
|
ID EndpointID `json:"Id"`
|
|
Name string `json:"Name"`
|
|
Type EndpointType `json:"Type"`
|
|
URL string `json:"URL"`
|
|
GroupID EndpointGroupID `json:"GroupId"`
|
|
PublicURL string `json:"PublicURL"`
|
|
TLSConfig TLSConfiguration `json:"TLSConfig"`
|
|
Extensions []EndpointExtension `json:"Extensions"`
|
|
AzureCredentials AzureCredentials `json:"AzureCredentials,omitempty"`
|
|
TagIDs []TagID `json:"TagIds"`
|
|
Status EndpointStatus `json:"Status"`
|
|
Snapshots []DockerSnapshot `json:"Snapshots"`
|
|
UserAccessPolicies UserAccessPolicies `json:"UserAccessPolicies"`
|
|
TeamAccessPolicies TeamAccessPolicies `json:"TeamAccessPolicies"`
|
|
EdgeID string `json:"EdgeID,omitempty"`
|
|
EdgeKey string `json:"EdgeKey"`
|
|
EdgeCheckinInterval int `json:"EdgeCheckinInterval"`
|
|
Kubernetes KubernetesData `json:"Kubernetes"`
|
|
|
|
// Deprecated fields
|
|
// Deprecated in DBVersion == 4
|
|
TLS bool `json:"TLS,omitempty"`
|
|
TLSCACertPath string `json:"TLSCACert,omitempty"`
|
|
TLSCertPath string `json:"TLSCert,omitempty"`
|
|
TLSKeyPath string `json:"TLSKey,omitempty"`
|
|
|
|
// Deprecated in DBVersion == 18
|
|
AuthorizedUsers []UserID `json:"AuthorizedUsers"`
|
|
AuthorizedTeams []TeamID `json:"AuthorizedTeams"`
|
|
|
|
// Deprecated in DBVersion == 22
|
|
Tags []string `json:"Tags"`
|
|
}
|
|
|
|
// EndpointAuthorizations represents the authorizations associated to a set of endpoints
|
|
EndpointAuthorizations map[EndpointID]Authorizations
|
|
|
|
// EndpointExtension represents a deprecated form of Portainer extension
|
|
// TODO: legacy extension management
|
|
EndpointExtension struct {
|
|
Type EndpointExtensionType `json:"Type"`
|
|
URL string `json:"URL"`
|
|
}
|
|
|
|
// EndpointExtensionType represents the type of an endpoint extension. Only
|
|
// one extension of each type can be associated to an endpoint
|
|
EndpointExtensionType int
|
|
|
|
// EndpointGroup represents a group of endpoints
|
|
EndpointGroup struct {
|
|
ID EndpointGroupID `json:"Id"`
|
|
Name string `json:"Name"`
|
|
Description string `json:"Description"`
|
|
UserAccessPolicies UserAccessPolicies `json:"UserAccessPolicies"`
|
|
TeamAccessPolicies TeamAccessPolicies `json:"TeamAccessPolicies"`
|
|
TagIDs []TagID `json:"TagIds"`
|
|
|
|
// Deprecated fields
|
|
Labels []Pair `json:"Labels"`
|
|
|
|
// Deprecated in DBVersion == 18
|
|
AuthorizedUsers []UserID `json:"AuthorizedUsers"`
|
|
AuthorizedTeams []TeamID `json:"AuthorizedTeams"`
|
|
|
|
// Deprecated in DBVersion == 22
|
|
Tags []string `json:"Tags"`
|
|
}
|
|
|
|
// EndpointGroupID represents an endpoint group identifier
|
|
EndpointGroupID int
|
|
|
|
// EndpointID represents an endpoint identifier
|
|
EndpointID int
|
|
|
|
// EndpointStatus represents the status of an endpoint
|
|
EndpointStatus int
|
|
|
|
// EndpointSyncJob represents a scheduled job that synchronize endpoints based on an external file
|
|
// Deprecated
|
|
EndpointSyncJob struct{}
|
|
|
|
// EndpointType represents the type of an endpoint
|
|
EndpointType int
|
|
|
|
// EndpointRelation represnts a endpoint relation object
|
|
EndpointRelation struct {
|
|
EndpointID EndpointID
|
|
EdgeStacks map[EdgeStackID]bool
|
|
}
|
|
|
|
// Extension represents a Portainer extension
|
|
Extension struct {
|
|
ID ExtensionID `json:"Id"`
|
|
Enabled bool `json:"Enabled"`
|
|
Name string `json:"Name,omitempty"`
|
|
ShortDescription string `json:"ShortDescription,omitempty"`
|
|
Description string `json:"Description,omitempty"`
|
|
DescriptionURL string `json:"DescriptionURL,omitempty"`
|
|
Price string `json:"Price,omitempty"`
|
|
PriceDescription string `json:"PriceDescription,omitempty"`
|
|
Deal bool `json:"Deal,omitempty"`
|
|
Available bool `json:"Available,omitempty"`
|
|
License LicenseInformation `json:"License,omitempty"`
|
|
Version string `json:"Version"`
|
|
UpdateAvailable bool `json:"UpdateAvailable"`
|
|
ShopURL string `json:"ShopURL,omitempty"`
|
|
Images []string `json:"Images,omitempty"`
|
|
Logo string `json:"Logo,omitempty"`
|
|
}
|
|
|
|
// ExtensionID represents a extension identifier
|
|
ExtensionID int
|
|
|
|
// GitlabRegistryData represents data required for gitlab registry to work
|
|
GitlabRegistryData struct {
|
|
ProjectID int `json:"ProjectId"`
|
|
InstanceURL string `json:"InstanceURL"`
|
|
ProjectPath string `json:"ProjectPath"`
|
|
}
|
|
|
|
// JobType represents a job type
|
|
JobType int
|
|
|
|
// KubernetesData contains all the Kubernetes related endpoint information
|
|
KubernetesData struct {
|
|
Snapshots []KubernetesSnapshot `json:"Snapshots"`
|
|
Configuration KubernetesConfiguration `json:"Configuration"`
|
|
}
|
|
|
|
// KubernetesSnapshot represents a snapshot of a specific Kubernetes endpoint at a specific time
|
|
KubernetesSnapshot struct {
|
|
Time int64 `json:"Time"`
|
|
KubernetesVersion string `json:"KubernetesVersion"`
|
|
NodeCount int `json:"NodeCount"`
|
|
TotalCPU int64 `json:"TotalCPU"`
|
|
TotalMemory int64 `json:"TotalMemory"`
|
|
}
|
|
|
|
// KubernetesConfiguration represents the configuration of a Kubernetes endpoint
|
|
KubernetesConfiguration struct {
|
|
UseLoadBalancer bool `json:"UseLoadBalancer"`
|
|
StorageClasses []KubernetesStorageClassConfig `json:"StorageClasses"`
|
|
}
|
|
|
|
// KubernetesStorageClassConfig represents a Kubernetes Storage Class configuration
|
|
KubernetesStorageClassConfig struct {
|
|
Name string `json:"Name"`
|
|
AccessModes []string `json:"AccessModes"`
|
|
}
|
|
|
|
// LDAPGroupSearchSettings represents settings used to search for groups in a LDAP server
|
|
LDAPGroupSearchSettings struct {
|
|
GroupBaseDN string `json:"GroupBaseDN"`
|
|
GroupFilter string `json:"GroupFilter"`
|
|
GroupAttribute string `json:"GroupAttribute"`
|
|
}
|
|
|
|
// LDAPSearchSettings represents settings used to search for users in a LDAP server
|
|
LDAPSearchSettings struct {
|
|
BaseDN string `json:"BaseDN"`
|
|
Filter string `json:"Filter"`
|
|
UserNameAttribute string `json:"UserNameAttribute"`
|
|
}
|
|
|
|
// LDAPSettings represents the settings used to connect to a LDAP server
|
|
LDAPSettings struct {
|
|
AnonymousMode bool `json:"AnonymousMode"`
|
|
ReaderDN string `json:"ReaderDN"`
|
|
Password string `json:"Password,omitempty"`
|
|
URL string `json:"URL"`
|
|
TLSConfig TLSConfiguration `json:"TLSConfig"`
|
|
StartTLS bool `json:"StartTLS"`
|
|
SearchSettings []LDAPSearchSettings `json:"SearchSettings"`
|
|
GroupSearchSettings []LDAPGroupSearchSettings `json:"GroupSearchSettings"`
|
|
AutoCreateUsers bool `json:"AutoCreateUsers"`
|
|
}
|
|
|
|
// LicenseInformation represents information about an extension license
|
|
LicenseInformation struct {
|
|
LicenseKey string `json:"LicenseKey,omitempty"`
|
|
Company string `json:"Company,omitempty"`
|
|
Expiration string `json:"Expiration,omitempty"`
|
|
Valid bool `json:"Valid,omitempty"`
|
|
}
|
|
|
|
// MembershipRole represents the role of a user within a team
|
|
MembershipRole int
|
|
|
|
// OAuthSettings represents the settings used to authorize with an authorization server
|
|
OAuthSettings struct {
|
|
ClientID string `json:"ClientID"`
|
|
ClientSecret string `json:"ClientSecret,omitempty"`
|
|
AccessTokenURI string `json:"AccessTokenURI"`
|
|
AuthorizationURI string `json:"AuthorizationURI"`
|
|
ResourceURI string `json:"ResourceURI"`
|
|
RedirectURI string `json:"RedirectURI"`
|
|
UserIdentifier string `json:"UserIdentifier"`
|
|
Scopes string `json:"Scopes"`
|
|
OAuthAutoCreateUsers bool `json:"OAuthAutoCreateUsers"`
|
|
DefaultTeamID TeamID `json:"DefaultTeamID"`
|
|
}
|
|
|
|
// Pair defines a key/value string pair
|
|
Pair struct {
|
|
Name string `json:"name"`
|
|
Value string `json:"value"`
|
|
}
|
|
|
|
// Registry represents a Docker registry with all the info required
|
|
// to connect to it
|
|
Registry struct {
|
|
ID RegistryID `json:"Id"`
|
|
Type RegistryType `json:"Type"`
|
|
Name string `json:"Name"`
|
|
URL string `json:"URL"`
|
|
Authentication bool `json:"Authentication"`
|
|
Username string `json:"Username"`
|
|
Password string `json:"Password,omitempty"`
|
|
ManagementConfiguration *RegistryManagementConfiguration `json:"ManagementConfiguration"`
|
|
Gitlab GitlabRegistryData `json:"Gitlab"`
|
|
UserAccessPolicies UserAccessPolicies `json:"UserAccessPolicies"`
|
|
TeamAccessPolicies TeamAccessPolicies `json:"TeamAccessPolicies"`
|
|
|
|
// Deprecated fields
|
|
// Deprecated in DBVersion == 18
|
|
AuthorizedUsers []UserID `json:"AuthorizedUsers"`
|
|
AuthorizedTeams []TeamID `json:"AuthorizedTeams"`
|
|
}
|
|
|
|
// RegistryID represents a registry identifier
|
|
RegistryID int
|
|
|
|
// RegistryManagementConfiguration represents a configuration that can be used to query
|
|
// the registry API via the registry management extension.
|
|
RegistryManagementConfiguration struct {
|
|
Type RegistryType `json:"Type"`
|
|
Authentication bool `json:"Authentication"`
|
|
Username string `json:"Username"`
|
|
Password string `json:"Password"`
|
|
TLSConfig TLSConfiguration `json:"TLSConfig"`
|
|
}
|
|
|
|
// RegistryType represents a type of registry
|
|
RegistryType int
|
|
|
|
// ResourceAccessLevel represents the level of control associated to a resource
|
|
ResourceAccessLevel int
|
|
|
|
// ResourceControl represent a reference to a Docker resource with specific access controls
|
|
ResourceControl struct {
|
|
ID ResourceControlID `json:"Id"`
|
|
ResourceID string `json:"ResourceId"`
|
|
SubResourceIDs []string `json:"SubResourceIds"`
|
|
Type ResourceControlType `json:"Type"`
|
|
UserAccesses []UserResourceAccess `json:"UserAccesses"`
|
|
TeamAccesses []TeamResourceAccess `json:"TeamAccesses"`
|
|
Public bool `json:"Public"`
|
|
AdministratorsOnly bool `json:"AdministratorsOnly"`
|
|
System bool `json:"System"`
|
|
|
|
// Deprecated fields
|
|
// Deprecated in DBVersion == 2
|
|
OwnerID UserID `json:"OwnerId,omitempty"`
|
|
AccessLevel ResourceAccessLevel `json:"AccessLevel,omitempty"`
|
|
}
|
|
|
|
// ResourceControlID represents a resource control identifier
|
|
ResourceControlID int
|
|
|
|
// ResourceControlType represents the type of resource associated to the resource control (volume, container, service...)
|
|
ResourceControlType int
|
|
|
|
// Role represents a set of authorizations that can be associated to a user or
|
|
// to a team.
|
|
Role struct {
|
|
ID RoleID `json:"Id"`
|
|
Name string `json:"Name"`
|
|
Description string `json:"Description"`
|
|
Authorizations Authorizations `json:"Authorizations"`
|
|
Priority int `json:"Priority"`
|
|
}
|
|
|
|
// RoleID represents a role identifier
|
|
RoleID int
|
|
|
|
// Schedule represents a scheduled job.
|
|
// It only contains a pointer to one of the JobRunner implementations
|
|
// based on the JobType.
|
|
// NOTE: The Recurring option is only used by ScriptExecutionJob at the moment
|
|
// Deprecated in favor of EdgeJob
|
|
Schedule struct {
|
|
ID ScheduleID `json:"Id"`
|
|
Name string
|
|
CronExpression string
|
|
Recurring bool
|
|
Created int64
|
|
JobType JobType
|
|
EdgeSchedule *EdgeSchedule
|
|
}
|
|
|
|
// ScheduleID represents a schedule identifier.
|
|
// Deprecated in favor of EdgeJob
|
|
ScheduleID int
|
|
|
|
// ScriptExecutionJob represents a scheduled job that can execute a script via a privileged container
|
|
ScriptExecutionJob struct {
|
|
Endpoints []EndpointID
|
|
Image string
|
|
ScriptPath string
|
|
RetryCount int
|
|
RetryInterval int
|
|
}
|
|
|
|
// Settings represents the application settings
|
|
Settings struct {
|
|
LogoURL string `json:"LogoURL"`
|
|
BlackListedLabels []Pair `json:"BlackListedLabels"`
|
|
AuthenticationMethod AuthenticationMethod `json:"AuthenticationMethod"`
|
|
LDAPSettings LDAPSettings `json:"LDAPSettings"`
|
|
OAuthSettings OAuthSettings `json:"OAuthSettings"`
|
|
AllowBindMountsForRegularUsers bool `json:"AllowBindMountsForRegularUsers"`
|
|
AllowPrivilegedModeForRegularUsers bool `json:"AllowPrivilegedModeForRegularUsers"`
|
|
AllowVolumeBrowserForRegularUsers bool `json:"AllowVolumeBrowserForRegularUsers"`
|
|
SnapshotInterval string `json:"SnapshotInterval"`
|
|
TemplatesURL string `json:"TemplatesURL"`
|
|
EnableHostManagementFeatures bool `json:"EnableHostManagementFeatures"`
|
|
EdgeAgentCheckinInterval int `json:"EdgeAgentCheckinInterval"`
|
|
EnableEdgeComputeFeatures bool `json:"EnableEdgeComputeFeatures"`
|
|
UserSessionTimeout string `json:"UserSessionTimeout"`
|
|
|
|
// Deprecated fields
|
|
DisplayDonationHeader bool
|
|
DisplayExternalContributors bool
|
|
}
|
|
|
|
// SnapshotJob represents a scheduled job that can create endpoint snapshots
|
|
SnapshotJob struct{}
|
|
|
|
// Stack represents a Docker stack created via docker stack deploy
|
|
Stack struct {
|
|
ID StackID `json:"Id"`
|
|
Name string `json:"Name"`
|
|
Type StackType `json:"Type"`
|
|
EndpointID EndpointID `json:"EndpointId"`
|
|
SwarmID string `json:"SwarmId"`
|
|
EntryPoint string `json:"EntryPoint"`
|
|
Env []Pair `json:"Env"`
|
|
ResourceControl *ResourceControl `json:"ResourceControl"`
|
|
ProjectPath string
|
|
}
|
|
|
|
// StackID represents a stack identifier (it must be composed of Name + "_" + SwarmID to create a unique identifier)
|
|
StackID int
|
|
|
|
// StackType represents the type of the stack (compose v2, stack deploy v3)
|
|
StackType int
|
|
|
|
// Status represents the application status
|
|
Status struct {
|
|
Analytics bool `json:"Analytics"`
|
|
Version string `json:"Version"`
|
|
}
|
|
|
|
// Tag represents a tag that can be associated to a resource
|
|
Tag struct {
|
|
ID TagID
|
|
Name string `json:"Name"`
|
|
Endpoints map[EndpointID]bool `json:"Endpoints"`
|
|
EndpointGroups map[EndpointGroupID]bool `json:"EndpointGroups"`
|
|
}
|
|
|
|
// TagID represents a tag identifier
|
|
TagID int
|
|
|
|
// Team represents a list of user accounts
|
|
Team struct {
|
|
ID TeamID `json:"Id"`
|
|
Name string `json:"Name"`
|
|
}
|
|
|
|
// TeamAccessPolicies represent the association of an access policy and a team
|
|
TeamAccessPolicies map[TeamID]AccessPolicy
|
|
|
|
// TeamID represents a team identifier
|
|
TeamID int
|
|
|
|
// TeamMembership represents a membership association between a user and a team
|
|
TeamMembership struct {
|
|
ID TeamMembershipID `json:"Id"`
|
|
UserID UserID `json:"UserID"`
|
|
TeamID TeamID `json:"TeamID"`
|
|
Role MembershipRole `json:"Role"`
|
|
}
|
|
|
|
// TeamMembershipID represents a team membership identifier
|
|
TeamMembershipID int
|
|
|
|
// TeamResourceAccess represents the level of control on a resource for a specific team
|
|
TeamResourceAccess struct {
|
|
TeamID TeamID `json:"TeamId"`
|
|
AccessLevel ResourceAccessLevel `json:"AccessLevel"`
|
|
}
|
|
|
|
// Template represents an application template that can be used as an App Template
|
|
// or an Edge template
|
|
Template struct {
|
|
// Mandatory container/stack fields
|
|
ID TemplateID `json:"Id"`
|
|
Type TemplateType `json:"type"`
|
|
Title string `json:"title"`
|
|
Description string `json:"description"`
|
|
AdministratorOnly bool `json:"administrator_only"`
|
|
|
|
// Mandatory container fields
|
|
Image string `json:"image"`
|
|
|
|
// Mandatory stack fields
|
|
Repository TemplateRepository `json:"repository"`
|
|
|
|
// Mandatory Edge stack fields
|
|
StackFile string `json:"stackFile"`
|
|
|
|
// Optional stack/container fields
|
|
Name string `json:"name,omitempty"`
|
|
Logo string `json:"logo,omitempty"`
|
|
Env []TemplateEnv `json:"env,omitempty"`
|
|
Note string `json:"note,omitempty"`
|
|
Platform string `json:"platform,omitempty"`
|
|
Categories []string `json:"categories,omitempty"`
|
|
|
|
// Optional container fields
|
|
Registry string `json:"registry,omitempty"`
|
|
Command string `json:"command,omitempty"`
|
|
Network string `json:"network,omitempty"`
|
|
Volumes []TemplateVolume `json:"volumes,omitempty"`
|
|
Ports []string `json:"ports,omitempty"`
|
|
Labels []Pair `json:"labels,omitempty"`
|
|
Privileged bool `json:"privileged,omitempty"`
|
|
Interactive bool `json:"interactive,omitempty"`
|
|
RestartPolicy string `json:"restart_policy,omitempty"`
|
|
Hostname string `json:"hostname,omitempty"`
|
|
}
|
|
|
|
// TemplateEnv represents a template environment variable configuration
|
|
TemplateEnv struct {
|
|
Name string `json:"name"`
|
|
Label string `json:"label,omitempty"`
|
|
Description string `json:"description,omitempty"`
|
|
Default string `json:"default,omitempty"`
|
|
Preset bool `json:"preset,omitempty"`
|
|
Select []TemplateEnvSelect `json:"select,omitempty"`
|
|
}
|
|
|
|
// TemplateEnvSelect represents text/value pair that will be displayed as a choice for the
|
|
// template user
|
|
TemplateEnvSelect struct {
|
|
Text string `json:"text"`
|
|
Value string `json:"value"`
|
|
Default bool `json:"default"`
|
|
}
|
|
|
|
// TemplateID represents a template identifier
|
|
TemplateID int
|
|
|
|
// TemplateRepository represents the git repository configuration for a template
|
|
TemplateRepository struct {
|
|
URL string `json:"url"`
|
|
StackFile string `json:"stackfile"`
|
|
}
|
|
|
|
// TemplateType represents the type of a template
|
|
TemplateType int
|
|
|
|
// TemplateVolume represents a template volume configuration
|
|
TemplateVolume struct {
|
|
Container string `json:"container"`
|
|
Bind string `json:"bind,omitempty"`
|
|
ReadOnly bool `json:"readonly,omitempty"`
|
|
}
|
|
|
|
// TLSConfiguration represents a TLS configuration
|
|
TLSConfiguration struct {
|
|
TLS bool `json:"TLS"`
|
|
TLSSkipVerify bool `json:"TLSSkipVerify"`
|
|
TLSCACertPath string `json:"TLSCACert,omitempty"`
|
|
TLSCertPath string `json:"TLSCert,omitempty"`
|
|
TLSKeyPath string `json:"TLSKey,omitempty"`
|
|
}
|
|
|
|
// TLSFileType represents a type of TLS file required to connect to a Docker endpoint.
|
|
// It can be either a TLS CA file, a TLS certificate file or a TLS key file
|
|
TLSFileType int
|
|
|
|
// TokenData represents the data embedded in a JWT token
|
|
TokenData struct {
|
|
ID UserID
|
|
Username string
|
|
Role UserRole
|
|
}
|
|
|
|
// TunnelDetails represents information associated to a tunnel
|
|
TunnelDetails struct {
|
|
Status string
|
|
LastActivity time.Time
|
|
Port int
|
|
Jobs []EdgeJob
|
|
Credentials string
|
|
}
|
|
|
|
// TunnelServerInfo represents information associated to the tunnel server
|
|
TunnelServerInfo struct {
|
|
PrivateKeySeed string `json:"PrivateKeySeed"`
|
|
}
|
|
|
|
// User represents a user account
|
|
User struct {
|
|
ID UserID `json:"Id"`
|
|
Username string `json:"Username"`
|
|
Password string `json:"Password,omitempty"`
|
|
Role UserRole `json:"Role"`
|
|
PortainerAuthorizations Authorizations `json:"PortainerAuthorizations"`
|
|
EndpointAuthorizations EndpointAuthorizations `json:"EndpointAuthorizations"`
|
|
}
|
|
|
|
// UserAccessPolicies represent the association of an access policy and a user
|
|
UserAccessPolicies map[UserID]AccessPolicy
|
|
|
|
// UserID represents a user identifier
|
|
UserID int
|
|
|
|
// UserResourceAccess represents the level of control on a resource for a specific user
|
|
UserResourceAccess struct {
|
|
UserID UserID `json:"UserId"`
|
|
AccessLevel ResourceAccessLevel `json:"AccessLevel"`
|
|
}
|
|
|
|
// UserRole represents the role of a user. It can be either an administrator
|
|
// or a regular user
|
|
UserRole int
|
|
|
|
// Webhook represents a url webhook that can be used to update a service
|
|
Webhook struct {
|
|
ID WebhookID `json:"Id"`
|
|
Token string `json:"Token"`
|
|
ResourceID string `json:"ResourceId"`
|
|
EndpointID EndpointID `json:"EndpointId"`
|
|
WebhookType WebhookType `json:"Type"`
|
|
}
|
|
|
|
// WebhookID represents a webhook identifier.
|
|
WebhookID int
|
|
|
|
// WebhookType represents the type of resource a webhook is related to
|
|
WebhookType int
|
|
|
|
// CLIService represents a service for managing CLI
|
|
CLIService interface {
|
|
ParseFlags(version string) (*CLIFlags, error)
|
|
ValidateFlags(flags *CLIFlags) error
|
|
}
|
|
|
|
// ComposeStackManager represents a service to manage Compose stacks
|
|
ComposeStackManager interface {
|
|
Up(stack *Stack, endpoint *Endpoint) error
|
|
Down(stack *Stack, endpoint *Endpoint) error
|
|
}
|
|
|
|
// CryptoService represents a service for encrypting/hashing data
|
|
CryptoService interface {
|
|
Hash(data string) (string, error)
|
|
CompareHashAndData(hash string, data string) error
|
|
}
|
|
|
|
// DataStore defines the interface to manage the data
|
|
DataStore interface {
|
|
Open() error
|
|
Init() error
|
|
Close() error
|
|
IsNew() bool
|
|
MigrateData() error
|
|
|
|
DockerHub() DockerHubService
|
|
EdgeGroup() EdgeGroupService
|
|
EdgeJob() EdgeJobService
|
|
EdgeStack() EdgeStackService
|
|
Endpoint() EndpointService
|
|
EndpointGroup() EndpointGroupService
|
|
EndpointRelation() EndpointRelationService
|
|
Extension() ExtensionService
|
|
Registry() RegistryService
|
|
ResourceControl() ResourceControlService
|
|
Role() RoleService
|
|
Settings() SettingsService
|
|
Stack() StackService
|
|
Tag() TagService
|
|
TeamMembership() TeamMembershipService
|
|
Team() TeamService
|
|
TunnelServer() TunnelServerService
|
|
User() UserService
|
|
Version() VersionService
|
|
Webhook() WebhookService
|
|
}
|
|
|
|
// DigitalSignatureService represents a service to manage digital signatures
|
|
DigitalSignatureService interface {
|
|
ParseKeyPair(private, public []byte) error
|
|
GenerateKeyPair() ([]byte, []byte, error)
|
|
EncodedPublicKey() string
|
|
PEMHeaders() (string, string)
|
|
CreateSignature(message string) (string, error)
|
|
}
|
|
|
|
// DockerHubService represents a service for managing the DockerHub object
|
|
DockerHubService interface {
|
|
DockerHub() (*DockerHub, error)
|
|
UpdateDockerHub(registry *DockerHub) error
|
|
}
|
|
|
|
// DockerSnapshotter represents a service used to create Docker endpoint snapshots
|
|
DockerSnapshotter interface {
|
|
CreateSnapshot(endpoint *Endpoint) (*DockerSnapshot, error)
|
|
}
|
|
|
|
// EdgeGroupService represents a service to manage Edge groups
|
|
EdgeGroupService interface {
|
|
EdgeGroups() ([]EdgeGroup, error)
|
|
EdgeGroup(ID EdgeGroupID) (*EdgeGroup, error)
|
|
CreateEdgeGroup(group *EdgeGroup) error
|
|
UpdateEdgeGroup(ID EdgeGroupID, group *EdgeGroup) error
|
|
DeleteEdgeGroup(ID EdgeGroupID) error
|
|
}
|
|
|
|
// EdgeJobService represents a service to manage Edge jobs
|
|
EdgeJobService interface {
|
|
EdgeJobs() ([]EdgeJob, error)
|
|
EdgeJob(ID EdgeJobID) (*EdgeJob, error)
|
|
CreateEdgeJob(edgeJob *EdgeJob) error
|
|
UpdateEdgeJob(ID EdgeJobID, edgeJob *EdgeJob) error
|
|
DeleteEdgeJob(ID EdgeJobID) error
|
|
GetNextIdentifier() int
|
|
}
|
|
|
|
// EdgeStackService represents a service to manage Edge stacks
|
|
EdgeStackService interface {
|
|
EdgeStacks() ([]EdgeStack, error)
|
|
EdgeStack(ID EdgeStackID) (*EdgeStack, error)
|
|
CreateEdgeStack(edgeStack *EdgeStack) error
|
|
UpdateEdgeStack(ID EdgeStackID, edgeStack *EdgeStack) error
|
|
DeleteEdgeStack(ID EdgeStackID) error
|
|
GetNextIdentifier() int
|
|
}
|
|
|
|
// EndpointService represents a service for managing endpoint data
|
|
EndpointService interface {
|
|
Endpoint(ID EndpointID) (*Endpoint, error)
|
|
Endpoints() ([]Endpoint, error)
|
|
CreateEndpoint(endpoint *Endpoint) error
|
|
UpdateEndpoint(ID EndpointID, endpoint *Endpoint) error
|
|
DeleteEndpoint(ID EndpointID) error
|
|
Synchronize(toCreate, toUpdate, toDelete []*Endpoint) error
|
|
GetNextIdentifier() int
|
|
}
|
|
|
|
// EndpointGroupService represents a service for managing endpoint group data
|
|
EndpointGroupService interface {
|
|
EndpointGroup(ID EndpointGroupID) (*EndpointGroup, error)
|
|
EndpointGroups() ([]EndpointGroup, error)
|
|
CreateEndpointGroup(group *EndpointGroup) error
|
|
UpdateEndpointGroup(ID EndpointGroupID, group *EndpointGroup) error
|
|
DeleteEndpointGroup(ID EndpointGroupID) error
|
|
}
|
|
|
|
// EndpointRelationService represents a service for managing endpoint relations data
|
|
EndpointRelationService interface {
|
|
EndpointRelation(EndpointID EndpointID) (*EndpointRelation, error)
|
|
CreateEndpointRelation(endpointRelation *EndpointRelation) error
|
|
UpdateEndpointRelation(EndpointID EndpointID, endpointRelation *EndpointRelation) error
|
|
DeleteEndpointRelation(EndpointID EndpointID) error
|
|
}
|
|
|
|
// ExtensionManager represents a service used to manage extensions
|
|
ExtensionManager interface {
|
|
FetchExtensionDefinitions() ([]Extension, error)
|
|
InstallExtension(extension *Extension, licenseKey string, archiveFileName string, extensionArchive []byte) error
|
|
EnableExtension(extension *Extension, licenseKey string) error
|
|
DisableExtension(extension *Extension) error
|
|
UpdateExtension(extension *Extension, version string) error
|
|
StartExtensions() error
|
|
}
|
|
|
|
// ExtensionService represents a service for managing extension data
|
|
ExtensionService interface {
|
|
Extension(ID ExtensionID) (*Extension, error)
|
|
Extensions() ([]Extension, error)
|
|
Persist(extension *Extension) error
|
|
DeleteExtension(ID ExtensionID) error
|
|
}
|
|
|
|
// FileService represents a service for managing files
|
|
FileService interface {
|
|
GetFileContent(filePath string) ([]byte, error)
|
|
Rename(oldPath, newPath string) error
|
|
RemoveDirectory(directoryPath string) error
|
|
StoreTLSFileFromBytes(folder string, fileType TLSFileType, data []byte) (string, error)
|
|
GetPathForTLSFile(folder string, fileType TLSFileType) (string, error)
|
|
DeleteTLSFile(folder string, fileType TLSFileType) error
|
|
DeleteTLSFiles(folder string) error
|
|
GetStackProjectPath(stackIdentifier string) string
|
|
StoreStackFileFromBytes(stackIdentifier, fileName string, data []byte) (string, error)
|
|
GetEdgeStackProjectPath(edgeStackIdentifier string) string
|
|
StoreEdgeStackFileFromBytes(edgeStackIdentifier, fileName string, data []byte) (string, error)
|
|
StoreRegistryManagementFileFromBytes(folder, fileName string, data []byte) (string, error)
|
|
KeyPairFilesExist() (bool, error)
|
|
StoreKeyPair(private, public []byte, privatePEMHeader, publicPEMHeader string) error
|
|
LoadKeyPair() ([]byte, []byte, error)
|
|
WriteJSONToFile(path string, content interface{}) error
|
|
FileExists(path string) (bool, error)
|
|
StoreEdgeJobFileFromBytes(identifier string, data []byte) (string, error)
|
|
GetEdgeJobFolder(identifier string) string
|
|
ClearEdgeJobTaskLogs(edgeJobID, taskID string) error
|
|
GetEdgeJobTaskLogFileContent(edgeJobID, taskID string) (string, error)
|
|
StoreEdgeJobTaskLogFileFromBytes(edgeJobID, taskID string, data []byte) error
|
|
ExtractExtensionArchive(data []byte) error
|
|
GetBinaryFolder() string
|
|
}
|
|
|
|
// GitService represents a service for managing Git
|
|
GitService interface {
|
|
ClonePublicRepository(repositoryURL, referenceName string, destination string) error
|
|
ClonePrivateRepositoryWithBasicAuth(repositoryURL, referenceName string, destination, username, password string) error
|
|
}
|
|
|
|
// JWTService represents a service for managing JWT tokens
|
|
JWTService interface {
|
|
GenerateToken(data *TokenData) (string, error)
|
|
ParseAndVerifyToken(token string) (*TokenData, error)
|
|
SetUserSessionDuration(userSessionDuration time.Duration)
|
|
}
|
|
|
|
// KubeClient represents a service used to query a Kubernetes environment
|
|
KubeClient interface {
|
|
SetupUserServiceAccount(userID int, username string, teamIDs []int) error
|
|
GetServiceAccountBearerToken(userID int, username string) (string, error)
|
|
StartExecProcess(namespace, podName, containerName string, command []string, stdin io.Reader, stdout io.Writer) error
|
|
}
|
|
|
|
// KubernetesDeployer represents a service to deploy a manifest inside a Kubernetes endpoint
|
|
KubernetesDeployer interface {
|
|
Deploy(endpoint *Endpoint, data string, composeFormat bool, namespace string) ([]byte, error)
|
|
}
|
|
|
|
// KubernetesSnapshotter represents a service used to create Kubernetes endpoint snapshots
|
|
KubernetesSnapshotter interface {
|
|
CreateSnapshot(endpoint *Endpoint) (*KubernetesSnapshot, error)
|
|
}
|
|
|
|
// LDAPService represents a service used to authenticate users against a LDAP/AD
|
|
LDAPService interface {
|
|
AuthenticateUser(username, password string, settings *LDAPSettings) error
|
|
TestConnectivity(settings *LDAPSettings) error
|
|
GetUserGroups(username string, settings *LDAPSettings) ([]string, error)
|
|
}
|
|
|
|
// RegistryService represents a service for managing registry data
|
|
RegistryService interface {
|
|
Registry(ID RegistryID) (*Registry, error)
|
|
Registries() ([]Registry, error)
|
|
CreateRegistry(registry *Registry) error
|
|
UpdateRegistry(ID RegistryID, registry *Registry) error
|
|
DeleteRegistry(ID RegistryID) error
|
|
}
|
|
|
|
// ResourceControlService represents a service for managing resource control data
|
|
ResourceControlService interface {
|
|
ResourceControl(ID ResourceControlID) (*ResourceControl, error)
|
|
ResourceControlByResourceIDAndType(resourceID string, resourceType ResourceControlType) (*ResourceControl, error)
|
|
ResourceControls() ([]ResourceControl, error)
|
|
CreateResourceControl(rc *ResourceControl) error
|
|
UpdateResourceControl(ID ResourceControlID, resourceControl *ResourceControl) error
|
|
DeleteResourceControl(ID ResourceControlID) error
|
|
}
|
|
|
|
// ReverseTunnelService represensts a service used to manage reverse tunnel connections.
|
|
ReverseTunnelService interface {
|
|
StartTunnelServer(addr, port string, snapshotService SnapshotService) error
|
|
GenerateEdgeKey(url, host string, endpointIdentifier int) string
|
|
SetTunnelStatusToActive(endpointID EndpointID)
|
|
SetTunnelStatusToRequired(endpointID EndpointID) error
|
|
SetTunnelStatusToIdle(endpointID EndpointID)
|
|
GetTunnelDetails(endpointID EndpointID) *TunnelDetails
|
|
AddEdgeJob(endpointID EndpointID, edgeJob *EdgeJob)
|
|
RemoveEdgeJob(edgeJobID EdgeJobID)
|
|
}
|
|
|
|
// RoleService represents a service for managing user roles
|
|
RoleService interface {
|
|
Role(ID RoleID) (*Role, error)
|
|
Roles() ([]Role, error)
|
|
CreateRole(role *Role) error
|
|
UpdateRole(ID RoleID, role *Role) error
|
|
}
|
|
|
|
// SettingsService represents a service for managing application settings
|
|
SettingsService interface {
|
|
Settings() (*Settings, error)
|
|
UpdateSettings(settings *Settings) error
|
|
}
|
|
|
|
// Server defines the interface to serve the API
|
|
Server interface {
|
|
Start() error
|
|
}
|
|
|
|
// StackService represents a service for managing stack data
|
|
StackService interface {
|
|
Stack(ID StackID) (*Stack, error)
|
|
StackByName(name string) (*Stack, error)
|
|
Stacks() ([]Stack, error)
|
|
CreateStack(stack *Stack) error
|
|
UpdateStack(ID StackID, stack *Stack) error
|
|
DeleteStack(ID StackID) error
|
|
GetNextIdentifier() int
|
|
}
|
|
|
|
// StackService represents a service for managing endpoint snapshots
|
|
SnapshotService interface {
|
|
Start()
|
|
SetSnapshotInterval(snapshotInterval string) error
|
|
SnapshotEndpoint(endpoint *Endpoint) error
|
|
}
|
|
|
|
// SwarmStackManager represents a service to manage Swarm stacks
|
|
SwarmStackManager interface {
|
|
Login(dockerhub *DockerHub, registries []Registry, endpoint *Endpoint)
|
|
Logout(endpoint *Endpoint) error
|
|
Deploy(stack *Stack, prune bool, endpoint *Endpoint) error
|
|
Remove(stack *Stack, endpoint *Endpoint) error
|
|
}
|
|
|
|
// TagService represents a service for managing tag data
|
|
TagService interface {
|
|
Tags() ([]Tag, error)
|
|
Tag(ID TagID) (*Tag, error)
|
|
CreateTag(tag *Tag) error
|
|
UpdateTag(ID TagID, tag *Tag) error
|
|
DeleteTag(ID TagID) error
|
|
}
|
|
|
|
// TeamService represents a service for managing user data
|
|
TeamService interface {
|
|
Team(ID TeamID) (*Team, error)
|
|
TeamByName(name string) (*Team, error)
|
|
Teams() ([]Team, error)
|
|
CreateTeam(team *Team) error
|
|
UpdateTeam(ID TeamID, team *Team) error
|
|
DeleteTeam(ID TeamID) error
|
|
}
|
|
|
|
// TeamMembershipService represents a service for managing team membership data
|
|
TeamMembershipService interface {
|
|
TeamMembership(ID TeamMembershipID) (*TeamMembership, error)
|
|
TeamMemberships() ([]TeamMembership, error)
|
|
TeamMembershipsByUserID(userID UserID) ([]TeamMembership, error)
|
|
TeamMembershipsByTeamID(teamID TeamID) ([]TeamMembership, error)
|
|
CreateTeamMembership(membership *TeamMembership) error
|
|
UpdateTeamMembership(ID TeamMembershipID, membership *TeamMembership) error
|
|
DeleteTeamMembership(ID TeamMembershipID) error
|
|
DeleteTeamMembershipByUserID(userID UserID) error
|
|
DeleteTeamMembershipByTeamID(teamID TeamID) error
|
|
}
|
|
|
|
// TunnelServerService represents a service for managing data associated to the tunnel server
|
|
TunnelServerService interface {
|
|
Info() (*TunnelServerInfo, error)
|
|
UpdateInfo(info *TunnelServerInfo) error
|
|
}
|
|
|
|
// UserService represents a service for managing user data
|
|
UserService interface {
|
|
User(ID UserID) (*User, error)
|
|
UserByUsername(username string) (*User, error)
|
|
Users() ([]User, error)
|
|
UsersByRole(role UserRole) ([]User, error)
|
|
CreateUser(user *User) error
|
|
UpdateUser(ID UserID, user *User) error
|
|
DeleteUser(ID UserID) error
|
|
}
|
|
|
|
// VersionService represents a service for managing version data
|
|
VersionService interface {
|
|
DBVersion() (int, error)
|
|
StoreDBVersion(version int) error
|
|
}
|
|
|
|
// WebhookService represents a service for managing webhook data.
|
|
WebhookService interface {
|
|
Webhooks() ([]Webhook, error)
|
|
Webhook(ID WebhookID) (*Webhook, error)
|
|
CreateWebhook(portainer *Webhook) error
|
|
WebhookByResourceID(resourceID string) (*Webhook, error)
|
|
WebhookByToken(token string) (*Webhook, error)
|
|
DeleteWebhook(serviceID WebhookID) error
|
|
}
|
|
)
|
|
|
|
const (
|
|
// APIVersion is the version number of the Portainer API
|
|
APIVersion = "2.0.0-dev"
|
|
// DBVersion is the version number of the Portainer database
|
|
DBVersion = 24
|
|
// AssetsServerURL represents the URL of the Portainer asset server
|
|
AssetsServerURL = "https://portainer-io-assets.sfo2.digitaloceanspaces.com"
|
|
// MessageOfTheDayURL represents the URL where Portainer MOTD message can be retrieved
|
|
MessageOfTheDayURL = AssetsServerURL + "/motd.json"
|
|
// VersionCheckURL represents the URL used to retrieve the latest version of Portainer
|
|
VersionCheckURL = "https://api.github.com/repos/portainer/portainer/releases/latest"
|
|
// ExtensionDefinitionsURL represents the URL where Portainer extension definitions can be retrieved
|
|
ExtensionDefinitionsURL = AssetsServerURL + "/extensions-" + APIVersion + ".json"
|
|
// SupportProductsURL represents the URL where Portainer support products can be retrieved
|
|
SupportProductsURL = AssetsServerURL + "/support.json"
|
|
// PortainerAgentHeader represents the name of the header available in any agent response
|
|
PortainerAgentHeader = "Portainer-Agent"
|
|
// PortainerAgentEdgeIDHeader represent the name of the header containing the Edge ID associated to an agent/agent cluster
|
|
PortainerAgentEdgeIDHeader = "X-PortainerAgent-EdgeID"
|
|
// PortainerAgentTargetHeader represent the name of the header containing the target node name
|
|
PortainerAgentTargetHeader = "X-PortainerAgent-Target"
|
|
// PortainerAgentSignatureHeader represent the name of the header containing the digital signature
|
|
PortainerAgentSignatureHeader = "X-PortainerAgent-Signature"
|
|
// PortainerAgentPublicKeyHeader represent the name of the header containing the public key
|
|
PortainerAgentPublicKeyHeader = "X-PortainerAgent-PublicKey"
|
|
// PortainerAgentKubernetesSATokenHeader represent the name of the header containing a Kubernetes SA token
|
|
PortainerAgentKubernetesSATokenHeader = "X-PortainerAgent-SA-Token"
|
|
// PortainerAgentSignatureMessage represents the message used to create a digital signature
|
|
// to be used when communicating with an agent
|
|
PortainerAgentSignatureMessage = "Portainer-App"
|
|
// ExtensionServer represents the server used by Portainer to communicate with extensions
|
|
ExtensionServer = "127.0.0.1"
|
|
// DefaultEdgeAgentCheckinIntervalInSeconds represents the default interval (in seconds) used by Edge agents to checkin with the Portainer instance
|
|
DefaultEdgeAgentCheckinIntervalInSeconds = 5
|
|
// LocalExtensionManifestFile represents the name of the local manifest file for extensions
|
|
LocalExtensionManifestFile = "/extensions.json"
|
|
// DefaultTemplatesURL represents the URL to the official templates supported by Portainer
|
|
DefaultTemplatesURL = "https://raw.githubusercontent.com/portainer/templates/master/templates-2.0.json"
|
|
// DefaultUserSessionTimeout represents the default timeout after which the user session is cleared
|
|
DefaultUserSessionTimeout = "8h"
|
|
)
|
|
|
|
const (
|
|
_ AuthenticationMethod = iota
|
|
// AuthenticationInternal represents the internal authentication method (authentication against Portainer API)
|
|
AuthenticationInternal
|
|
// AuthenticationLDAP represents the LDAP authentication method (authentication against a LDAP server)
|
|
AuthenticationLDAP
|
|
//AuthenticationOAuth represents the OAuth authentication method (authentication against a authorization server)
|
|
AuthenticationOAuth
|
|
)
|
|
|
|
const (
|
|
_ EdgeJobLogsStatus = iota
|
|
// EdgeJobLogsStatusIdle represents an idle log collection job
|
|
EdgeJobLogsStatusIdle
|
|
// EdgeJobLogsStatusPending represents a pending log collection job
|
|
EdgeJobLogsStatusPending
|
|
// EdgeJobLogsStatusCollected represents a completed log collection job
|
|
EdgeJobLogsStatusCollected
|
|
)
|
|
|
|
const (
|
|
_ EdgeStackStatusType = iota
|
|
//StatusOk represents a successfully deployed edge stack
|
|
StatusOk
|
|
//StatusError represents an edge endpoint which failed to deploy its edge stack
|
|
StatusError
|
|
//StatusAcknowledged represents an acknowledged edge stack
|
|
StatusAcknowledged
|
|
)
|
|
|
|
const (
|
|
_ EndpointExtensionType = iota
|
|
// StoridgeEndpointExtension represents the Storidge extension
|
|
StoridgeEndpointExtension
|
|
)
|
|
|
|
const (
|
|
_ EndpointStatus = iota
|
|
// EndpointStatusUp is used to represent an available endpoint
|
|
EndpointStatusUp
|
|
// EndpointStatusDown is used to represent an unavailable endpoint
|
|
EndpointStatusDown
|
|
)
|
|
|
|
const (
|
|
_ EndpointType = iota
|
|
// DockerEnvironment represents an endpoint connected to a Docker environment
|
|
DockerEnvironment
|
|
// AgentOnDockerEnvironment represents an endpoint connected to a Portainer agent deployed on a Docker environment
|
|
AgentOnDockerEnvironment
|
|
// AzureEnvironment represents an endpoint connected to an Azure environment
|
|
AzureEnvironment
|
|
// EdgeAgentOnDockerEnvironment represents an endpoint connected to an Edge agent deployed on a Docker environment
|
|
EdgeAgentOnDockerEnvironment
|
|
// KubernetesLocalEnvironment represents an endpoint connected to a local Kubernetes environment
|
|
KubernetesLocalEnvironment
|
|
// AgentOnKubernetesEnvironment represents an endpoint connected to a Portainer agent deployed on a Kubernetes environment
|
|
AgentOnKubernetesEnvironment
|
|
// EdgeAgentOnKubernetesEnvironment represents an endpoint connected to an Edge agent deployed on a Kubernetes environment
|
|
EdgeAgentOnKubernetesEnvironment
|
|
)
|
|
|
|
const (
|
|
_ ExtensionID = iota
|
|
// RegistryManagementExtension represents the registry management extension
|
|
RegistryManagementExtension
|
|
// OAuthAuthenticationExtension represents the OAuth authentication extension
|
|
OAuthAuthenticationExtension
|
|
// RBACExtension represents the RBAC extension
|
|
RBACExtension
|
|
)
|
|
|
|
const (
|
|
_ JobType = iota
|
|
// SnapshotJobType is a system job used to create endpoint snapshots
|
|
SnapshotJobType = 2
|
|
)
|
|
|
|
const (
|
|
_ MembershipRole = iota
|
|
// TeamLeader represents a leader role inside a team
|
|
TeamLeader
|
|
// TeamMember represents a member role inside a team
|
|
TeamMember
|
|
)
|
|
|
|
const (
|
|
_ RegistryType = iota
|
|
// QuayRegistry represents a Quay.io registry
|
|
QuayRegistry
|
|
// AzureRegistry represents an ACR registry
|
|
AzureRegistry
|
|
// CustomRegistry represents a custom registry
|
|
CustomRegistry
|
|
// GitlabRegistry represents a gitlab registry
|
|
GitlabRegistry
|
|
)
|
|
|
|
const (
|
|
_ ResourceAccessLevel = iota
|
|
// ReadWriteAccessLevel represents an access level with read-write permissions on a resource
|
|
ReadWriteAccessLevel
|
|
)
|
|
|
|
const (
|
|
_ ResourceControlType = iota
|
|
// ContainerResourceControl represents a resource control associated to a Docker container
|
|
ContainerResourceControl
|
|
// ServiceResourceControl represents a resource control associated to a Docker service
|
|
ServiceResourceControl
|
|
// VolumeResourceControl represents a resource control associated to a Docker volume
|
|
VolumeResourceControl
|
|
// NetworkResourceControl represents a resource control associated to a Docker network
|
|
NetworkResourceControl
|
|
// SecretResourceControl represents a resource control associated to a Docker secret
|
|
SecretResourceControl
|
|
// StackResourceControl represents a resource control associated to a stack composed of Docker services
|
|
StackResourceControl
|
|
// ConfigResourceControl represents a resource control associated to a Docker config
|
|
ConfigResourceControl
|
|
)
|
|
|
|
const (
|
|
_ StackType = iota
|
|
// DockerSwarmStack represents a stack managed via docker stack
|
|
DockerSwarmStack
|
|
// DockerComposeStack represents a stack managed via docker-compose
|
|
DockerComposeStack
|
|
// KubernetesStack represents a stack managed via kubectl
|
|
KubernetesStack
|
|
)
|
|
|
|
const (
|
|
_ TemplateType = iota
|
|
// ContainerTemplate represents a container template
|
|
ContainerTemplate
|
|
// SwarmStackTemplate represents a template used to deploy a Swarm stack
|
|
SwarmStackTemplate
|
|
// ComposeStackTemplate represents a template used to deploy a Compose stack
|
|
ComposeStackTemplate
|
|
// EdgeStackTemplate represents a template used to deploy an Edge stack
|
|
EdgeStackTemplate
|
|
)
|
|
|
|
const (
|
|
// TLSFileCA represents a TLS CA certificate file
|
|
TLSFileCA TLSFileType = iota
|
|
// TLSFileCert represents a TLS certificate file
|
|
TLSFileCert
|
|
// TLSFileKey represents a TLS key file
|
|
TLSFileKey
|
|
)
|
|
|
|
const (
|
|
_ UserRole = iota
|
|
// AdministratorRole represents an administrator user role
|
|
AdministratorRole
|
|
// StandardUserRole represents a regular user role
|
|
StandardUserRole
|
|
)
|
|
|
|
const (
|
|
_ WebhookType = iota
|
|
// ServiceWebhook is a webhook for restarting a docker service
|
|
ServiceWebhook
|
|
)
|
|
|
|
const (
|
|
// EdgeAgentIdle represents an idle state for a tunnel connected to an Edge endpoint.
|
|
EdgeAgentIdle string = "IDLE"
|
|
// EdgeAgentManagementRequired represents a required state for a tunnel connected to an Edge endpoint
|
|
EdgeAgentManagementRequired string = "REQUIRED"
|
|
// EdgeAgentActive represents an active state for a tunnel connected to an Edge endpoint
|
|
EdgeAgentActive string = "ACTIVE"
|
|
)
|
|
|
|
const (
|
|
OperationDockerContainerArchiveInfo Authorization = "DockerContainerArchiveInfo"
|
|
OperationDockerContainerList Authorization = "DockerContainerList"
|
|
OperationDockerContainerExport Authorization = "DockerContainerExport"
|
|
OperationDockerContainerChanges Authorization = "DockerContainerChanges"
|
|
OperationDockerContainerInspect Authorization = "DockerContainerInspect"
|
|
OperationDockerContainerTop Authorization = "DockerContainerTop"
|
|
OperationDockerContainerLogs Authorization = "DockerContainerLogs"
|
|
OperationDockerContainerStats Authorization = "DockerContainerStats"
|
|
OperationDockerContainerAttachWebsocket Authorization = "DockerContainerAttachWebsocket"
|
|
OperationDockerContainerArchive Authorization = "DockerContainerArchive"
|
|
OperationDockerContainerCreate Authorization = "DockerContainerCreate"
|
|
OperationDockerContainerPrune Authorization = "DockerContainerPrune"
|
|
OperationDockerContainerKill Authorization = "DockerContainerKill"
|
|
OperationDockerContainerPause Authorization = "DockerContainerPause"
|
|
OperationDockerContainerUnpause Authorization = "DockerContainerUnpause"
|
|
OperationDockerContainerRestart Authorization = "DockerContainerRestart"
|
|
OperationDockerContainerStart Authorization = "DockerContainerStart"
|
|
OperationDockerContainerStop Authorization = "DockerContainerStop"
|
|
OperationDockerContainerWait Authorization = "DockerContainerWait"
|
|
OperationDockerContainerResize Authorization = "DockerContainerResize"
|
|
OperationDockerContainerAttach Authorization = "DockerContainerAttach"
|
|
OperationDockerContainerExec Authorization = "DockerContainerExec"
|
|
OperationDockerContainerRename Authorization = "DockerContainerRename"
|
|
OperationDockerContainerUpdate Authorization = "DockerContainerUpdate"
|
|
OperationDockerContainerPutContainerArchive Authorization = "DockerContainerPutContainerArchive"
|
|
OperationDockerContainerDelete Authorization = "DockerContainerDelete"
|
|
OperationDockerImageList Authorization = "DockerImageList"
|
|
OperationDockerImageSearch Authorization = "DockerImageSearch"
|
|
OperationDockerImageGetAll Authorization = "DockerImageGetAll"
|
|
OperationDockerImageGet Authorization = "DockerImageGet"
|
|
OperationDockerImageHistory Authorization = "DockerImageHistory"
|
|
OperationDockerImageInspect Authorization = "DockerImageInspect"
|
|
OperationDockerImageLoad Authorization = "DockerImageLoad"
|
|
OperationDockerImageCreate Authorization = "DockerImageCreate"
|
|
OperationDockerImagePrune Authorization = "DockerImagePrune"
|
|
OperationDockerImagePush Authorization = "DockerImagePush"
|
|
OperationDockerImageTag Authorization = "DockerImageTag"
|
|
OperationDockerImageDelete Authorization = "DockerImageDelete"
|
|
OperationDockerImageCommit Authorization = "DockerImageCommit"
|
|
OperationDockerImageBuild Authorization = "DockerImageBuild"
|
|
OperationDockerNetworkList Authorization = "DockerNetworkList"
|
|
OperationDockerNetworkInspect Authorization = "DockerNetworkInspect"
|
|
OperationDockerNetworkCreate Authorization = "DockerNetworkCreate"
|
|
OperationDockerNetworkConnect Authorization = "DockerNetworkConnect"
|
|
OperationDockerNetworkDisconnect Authorization = "DockerNetworkDisconnect"
|
|
OperationDockerNetworkPrune Authorization = "DockerNetworkPrune"
|
|
OperationDockerNetworkDelete Authorization = "DockerNetworkDelete"
|
|
OperationDockerVolumeList Authorization = "DockerVolumeList"
|
|
OperationDockerVolumeInspect Authorization = "DockerVolumeInspect"
|
|
OperationDockerVolumeCreate Authorization = "DockerVolumeCreate"
|
|
OperationDockerVolumePrune Authorization = "DockerVolumePrune"
|
|
OperationDockerVolumeDelete Authorization = "DockerVolumeDelete"
|
|
OperationDockerExecInspect Authorization = "DockerExecInspect"
|
|
OperationDockerExecStart Authorization = "DockerExecStart"
|
|
OperationDockerExecResize Authorization = "DockerExecResize"
|
|
OperationDockerSwarmInspect Authorization = "DockerSwarmInspect"
|
|
OperationDockerSwarmUnlockKey Authorization = "DockerSwarmUnlockKey"
|
|
OperationDockerSwarmInit Authorization = "DockerSwarmInit"
|
|
OperationDockerSwarmJoin Authorization = "DockerSwarmJoin"
|
|
OperationDockerSwarmLeave Authorization = "DockerSwarmLeave"
|
|
OperationDockerSwarmUpdate Authorization = "DockerSwarmUpdate"
|
|
OperationDockerSwarmUnlock Authorization = "DockerSwarmUnlock"
|
|
OperationDockerNodeList Authorization = "DockerNodeList"
|
|
OperationDockerNodeInspect Authorization = "DockerNodeInspect"
|
|
OperationDockerNodeUpdate Authorization = "DockerNodeUpdate"
|
|
OperationDockerNodeDelete Authorization = "DockerNodeDelete"
|
|
OperationDockerServiceList Authorization = "DockerServiceList"
|
|
OperationDockerServiceInspect Authorization = "DockerServiceInspect"
|
|
OperationDockerServiceLogs Authorization = "DockerServiceLogs"
|
|
OperationDockerServiceCreate Authorization = "DockerServiceCreate"
|
|
OperationDockerServiceUpdate Authorization = "DockerServiceUpdate"
|
|
OperationDockerServiceDelete Authorization = "DockerServiceDelete"
|
|
OperationDockerSecretList Authorization = "DockerSecretList"
|
|
OperationDockerSecretInspect Authorization = "DockerSecretInspect"
|
|
OperationDockerSecretCreate Authorization = "DockerSecretCreate"
|
|
OperationDockerSecretUpdate Authorization = "DockerSecretUpdate"
|
|
OperationDockerSecretDelete Authorization = "DockerSecretDelete"
|
|
OperationDockerConfigList Authorization = "DockerConfigList"
|
|
OperationDockerConfigInspect Authorization = "DockerConfigInspect"
|
|
OperationDockerConfigCreate Authorization = "DockerConfigCreate"
|
|
OperationDockerConfigUpdate Authorization = "DockerConfigUpdate"
|
|
OperationDockerConfigDelete Authorization = "DockerConfigDelete"
|
|
OperationDockerTaskList Authorization = "DockerTaskList"
|
|
OperationDockerTaskInspect Authorization = "DockerTaskInspect"
|
|
OperationDockerTaskLogs Authorization = "DockerTaskLogs"
|
|
OperationDockerPluginList Authorization = "DockerPluginList"
|
|
OperationDockerPluginPrivileges Authorization = "DockerPluginPrivileges"
|
|
OperationDockerPluginInspect Authorization = "DockerPluginInspect"
|
|
OperationDockerPluginPull Authorization = "DockerPluginPull"
|
|
OperationDockerPluginCreate Authorization = "DockerPluginCreate"
|
|
OperationDockerPluginEnable Authorization = "DockerPluginEnable"
|
|
OperationDockerPluginDisable Authorization = "DockerPluginDisable"
|
|
OperationDockerPluginPush Authorization = "DockerPluginPush"
|
|
OperationDockerPluginUpgrade Authorization = "DockerPluginUpgrade"
|
|
OperationDockerPluginSet Authorization = "DockerPluginSet"
|
|
OperationDockerPluginDelete Authorization = "DockerPluginDelete"
|
|
OperationDockerSessionStart Authorization = "DockerSessionStart"
|
|
OperationDockerDistributionInspect Authorization = "DockerDistributionInspect"
|
|
OperationDockerBuildPrune Authorization = "DockerBuildPrune"
|
|
OperationDockerBuildCancel Authorization = "DockerBuildCancel"
|
|
OperationDockerPing Authorization = "DockerPing"
|
|
OperationDockerInfo Authorization = "DockerInfo"
|
|
OperationDockerEvents Authorization = "DockerEvents"
|
|
OperationDockerSystem Authorization = "DockerSystem"
|
|
OperationDockerVersion Authorization = "DockerVersion"
|
|
|
|
OperationDockerAgentPing Authorization = "DockerAgentPing"
|
|
OperationDockerAgentList Authorization = "DockerAgentList"
|
|
OperationDockerAgentHostInfo Authorization = "DockerAgentHostInfo"
|
|
OperationDockerAgentBrowseDelete Authorization = "DockerAgentBrowseDelete"
|
|
OperationDockerAgentBrowseGet Authorization = "DockerAgentBrowseGet"
|
|
OperationDockerAgentBrowseList Authorization = "DockerAgentBrowseList"
|
|
OperationDockerAgentBrowsePut Authorization = "DockerAgentBrowsePut"
|
|
OperationDockerAgentBrowseRename Authorization = "DockerAgentBrowseRename"
|
|
|
|
OperationPortainerDockerHubInspect Authorization = "PortainerDockerHubInspect"
|
|
OperationPortainerDockerHubUpdate Authorization = "PortainerDockerHubUpdate"
|
|
OperationPortainerEndpointGroupCreate Authorization = "PortainerEndpointGroupCreate"
|
|
OperationPortainerEndpointGroupList Authorization = "PortainerEndpointGroupList"
|
|
OperationPortainerEndpointGroupDelete Authorization = "PortainerEndpointGroupDelete"
|
|
OperationPortainerEndpointGroupInspect Authorization = "PortainerEndpointGroupInspect"
|
|
OperationPortainerEndpointGroupUpdate Authorization = "PortainerEndpointGroupEdit"
|
|
OperationPortainerEndpointGroupAccess Authorization = "PortainerEndpointGroupAccess "
|
|
OperationPortainerEndpointList Authorization = "PortainerEndpointList"
|
|
OperationPortainerEndpointInspect Authorization = "PortainerEndpointInspect"
|
|
OperationPortainerEndpointCreate Authorization = "PortainerEndpointCreate"
|
|
OperationPortainerEndpointExtensionAdd Authorization = "PortainerEndpointExtensionAdd"
|
|
OperationPortainerEndpointJob Authorization = "PortainerEndpointJob"
|
|
OperationPortainerEndpointSnapshots Authorization = "PortainerEndpointSnapshots"
|
|
OperationPortainerEndpointSnapshot Authorization = "PortainerEndpointSnapshot"
|
|
OperationPortainerEndpointUpdate Authorization = "PortainerEndpointUpdate"
|
|
OperationPortainerEndpointUpdateAccess Authorization = "PortainerEndpointUpdateAccess"
|
|
OperationPortainerEndpointDelete Authorization = "PortainerEndpointDelete"
|
|
OperationPortainerEndpointExtensionRemove Authorization = "PortainerEndpointExtensionRemove"
|
|
OperationPortainerExtensionList Authorization = "PortainerExtensionList"
|
|
OperationPortainerExtensionInspect Authorization = "PortainerExtensionInspect"
|
|
OperationPortainerExtensionCreate Authorization = "PortainerExtensionCreate"
|
|
OperationPortainerExtensionUpdate Authorization = "PortainerExtensionUpdate"
|
|
OperationPortainerExtensionDelete Authorization = "PortainerExtensionDelete"
|
|
OperationPortainerMOTD Authorization = "PortainerMOTD"
|
|
OperationPortainerRegistryList Authorization = "PortainerRegistryList"
|
|
OperationPortainerRegistryInspect Authorization = "PortainerRegistryInspect"
|
|
OperationPortainerRegistryCreate Authorization = "PortainerRegistryCreate"
|
|
OperationPortainerRegistryConfigure Authorization = "PortainerRegistryConfigure"
|
|
OperationPortainerRegistryUpdate Authorization = "PortainerRegistryUpdate"
|
|
OperationPortainerRegistryUpdateAccess Authorization = "PortainerRegistryUpdateAccess"
|
|
OperationPortainerRegistryDelete Authorization = "PortainerRegistryDelete"
|
|
OperationPortainerResourceControlCreate Authorization = "PortainerResourceControlCreate"
|
|
OperationPortainerResourceControlUpdate Authorization = "PortainerResourceControlUpdate"
|
|
OperationPortainerResourceControlDelete Authorization = "PortainerResourceControlDelete"
|
|
OperationPortainerRoleList Authorization = "PortainerRoleList"
|
|
OperationPortainerRoleInspect Authorization = "PortainerRoleInspect"
|
|
OperationPortainerRoleCreate Authorization = "PortainerRoleCreate"
|
|
OperationPortainerRoleUpdate Authorization = "PortainerRoleUpdate"
|
|
OperationPortainerRoleDelete Authorization = "PortainerRoleDelete"
|
|
OperationPortainerScheduleList Authorization = "PortainerScheduleList"
|
|
OperationPortainerScheduleInspect Authorization = "PortainerScheduleInspect"
|
|
OperationPortainerScheduleFile Authorization = "PortainerScheduleFile"
|
|
OperationPortainerScheduleTasks Authorization = "PortainerScheduleTasks"
|
|
OperationPortainerScheduleCreate Authorization = "PortainerScheduleCreate"
|
|
OperationPortainerScheduleUpdate Authorization = "PortainerScheduleUpdate"
|
|
OperationPortainerScheduleDelete Authorization = "PortainerScheduleDelete"
|
|
OperationPortainerSettingsInspect Authorization = "PortainerSettingsInspect"
|
|
OperationPortainerSettingsUpdate Authorization = "PortainerSettingsUpdate"
|
|
OperationPortainerSettingsLDAPCheck Authorization = "PortainerSettingsLDAPCheck"
|
|
OperationPortainerStackList Authorization = "PortainerStackList"
|
|
OperationPortainerStackInspect Authorization = "PortainerStackInspect"
|
|
OperationPortainerStackFile Authorization = "PortainerStackFile"
|
|
OperationPortainerStackCreate Authorization = "PortainerStackCreate"
|
|
OperationPortainerStackMigrate Authorization = "PortainerStackMigrate"
|
|
OperationPortainerStackUpdate Authorization = "PortainerStackUpdate"
|
|
OperationPortainerStackDelete Authorization = "PortainerStackDelete"
|
|
OperationPortainerTagList Authorization = "PortainerTagList"
|
|
OperationPortainerTagCreate Authorization = "PortainerTagCreate"
|
|
OperationPortainerTagDelete Authorization = "PortainerTagDelete"
|
|
OperationPortainerTeamMembershipList Authorization = "PortainerTeamMembershipList"
|
|
OperationPortainerTeamMembershipCreate Authorization = "PortainerTeamMembershipCreate"
|
|
OperationPortainerTeamMembershipUpdate Authorization = "PortainerTeamMembershipUpdate"
|
|
OperationPortainerTeamMembershipDelete Authorization = "PortainerTeamMembershipDelete"
|
|
OperationPortainerTeamList Authorization = "PortainerTeamList"
|
|
OperationPortainerTeamInspect Authorization = "PortainerTeamInspect"
|
|
OperationPortainerTeamMemberships Authorization = "PortainerTeamMemberships"
|
|
OperationPortainerTeamCreate Authorization = "PortainerTeamCreate"
|
|
OperationPortainerTeamUpdate Authorization = "PortainerTeamUpdate"
|
|
OperationPortainerTeamDelete Authorization = "PortainerTeamDelete"
|
|
OperationPortainerTemplateList Authorization = "PortainerTemplateList"
|
|
OperationPortainerTemplateInspect Authorization = "PortainerTemplateInspect"
|
|
OperationPortainerTemplateCreate Authorization = "PortainerTemplateCreate"
|
|
OperationPortainerTemplateUpdate Authorization = "PortainerTemplateUpdate"
|
|
OperationPortainerTemplateDelete Authorization = "PortainerTemplateDelete"
|
|
OperationPortainerUploadTLS Authorization = "PortainerUploadTLS"
|
|
OperationPortainerUserList Authorization = "PortainerUserList"
|
|
OperationPortainerUserInspect Authorization = "PortainerUserInspect"
|
|
OperationPortainerUserMemberships Authorization = "PortainerUserMemberships"
|
|
OperationPortainerUserCreate Authorization = "PortainerUserCreate"
|
|
OperationPortainerUserUpdate Authorization = "PortainerUserUpdate"
|
|
OperationPortainerUserUpdatePassword Authorization = "PortainerUserUpdatePassword"
|
|
OperationPortainerUserDelete Authorization = "PortainerUserDelete"
|
|
OperationPortainerWebsocketExec Authorization = "PortainerWebsocketExec"
|
|
OperationPortainerWebhookList Authorization = "PortainerWebhookList"
|
|
OperationPortainerWebhookCreate Authorization = "PortainerWebhookCreate"
|
|
OperationPortainerWebhookDelete Authorization = "PortainerWebhookDelete"
|
|
|
|
OperationIntegrationStoridgeAdmin Authorization = "IntegrationStoridgeAdmin"
|
|
|
|
OperationDockerUndefined Authorization = "DockerUndefined"
|
|
OperationDockerAgentUndefined Authorization = "DockerAgentUndefined"
|
|
OperationPortainerUndefined Authorization = "PortainerUndefined"
|
|
|
|
EndpointResourcesAccess Authorization = "EndpointResourcesAccess"
|
|
)
|