v1.41.yaml 387 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103310431053106310731083109311031113112311331143115311631173118311931203121312231233124312531263127312831293130313131323133313431353136313731383139314031413142314331443145314631473148314931503151315231533154315531563157315831593160316131623163316431653166316731683169317031713172317331743175317631773178317931803181318231833184318531863187318831893190319131923193319431953196319731983199320032013202320332043205320632073208320932103211321232133214321532163217321832193220322132223223322432253226322732283229323032313232323332343235323632373238323932403241324232433244324532463247324832493250325132523253325432553256325732583259326032613262326332643265326632673268326932703271327232733274327532763277327832793280328132823283328432853286328732883289329032913292329332943295329632973298329933003301330233033304330533063307330833093310331133123313331433153316331733183319332033213322332333243325332633273328332933303331333233333334333533363337333833393340334133423343334433453346334733483349335033513352335333543355335633573358335933603361336233633364336533663367336833693370337133723373337433753376337733783379338033813382338333843385338633873388338933903391339233933394339533963397339833993400340134023403340434053406340734083409341034113412341334143415341634173418341934203421342234233424342534263427342834293430343134323433343434353436343734383439344034413442344334443445344634473448344934503451345234533454345534563457345834593460346134623463346434653466346734683469347034713472347334743475347634773478347934803481348234833484348534863487348834893490349134923493349434953496349734983499350035013502350335043505350635073508350935103511351235133514351535163517351835193520352135223523352435253526352735283529353035313532353335343535353635373538353935403541354235433544354535463547354835493550355135523553355435553556355735583559356035613562356335643565356635673568356935703571357235733574357535763577357835793580358135823583358435853586358735883589359035913592359335943595359635973598359936003601360236033604360536063607360836093610361136123613361436153616361736183619362036213622362336243625362636273628362936303631363236333634363536363637363836393640364136423643364436453646364736483649365036513652365336543655365636573658365936603661366236633664366536663667366836693670367136723673367436753676367736783679368036813682368336843685368636873688368936903691369236933694369536963697369836993700370137023703370437053706370737083709371037113712371337143715371637173718371937203721372237233724372537263727372837293730373137323733373437353736373737383739374037413742374337443745374637473748374937503751375237533754375537563757375837593760376137623763376437653766376737683769377037713772377337743775377637773778377937803781378237833784378537863787378837893790379137923793379437953796379737983799380038013802380338043805380638073808380938103811381238133814381538163817381838193820382138223823382438253826382738283829383038313832383338343835383638373838383938403841384238433844384538463847384838493850385138523853385438553856385738583859386038613862386338643865386638673868386938703871387238733874387538763877387838793880388138823883388438853886388738883889389038913892389338943895389638973898389939003901390239033904390539063907390839093910391139123913391439153916391739183919392039213922392339243925392639273928392939303931393239333934393539363937393839393940394139423943394439453946394739483949395039513952395339543955395639573958395939603961396239633964396539663967396839693970397139723973397439753976397739783979398039813982398339843985398639873988398939903991399239933994399539963997399839994000400140024003400440054006400740084009401040114012401340144015401640174018401940204021402240234024402540264027402840294030403140324033403440354036403740384039404040414042404340444045404640474048404940504051405240534054405540564057405840594060406140624063406440654066406740684069407040714072407340744075407640774078407940804081408240834084408540864087408840894090409140924093409440954096409740984099410041014102410341044105410641074108410941104111411241134114411541164117411841194120412141224123412441254126412741284129413041314132413341344135413641374138413941404141414241434144414541464147414841494150415141524153415441554156415741584159416041614162416341644165416641674168416941704171417241734174417541764177417841794180418141824183418441854186418741884189419041914192419341944195419641974198419942004201420242034204420542064207420842094210421142124213421442154216421742184219422042214222422342244225422642274228422942304231423242334234423542364237423842394240424142424243424442454246424742484249425042514252425342544255425642574258425942604261426242634264426542664267426842694270427142724273427442754276427742784279428042814282428342844285428642874288428942904291429242934294429542964297429842994300430143024303430443054306430743084309431043114312431343144315431643174318431943204321432243234324432543264327432843294330433143324333433443354336433743384339434043414342434343444345434643474348434943504351435243534354435543564357435843594360436143624363436443654366436743684369437043714372437343744375437643774378437943804381438243834384438543864387438843894390439143924393439443954396439743984399440044014402440344044405440644074408440944104411441244134414441544164417441844194420442144224423442444254426442744284429443044314432443344344435443644374438443944404441444244434444444544464447444844494450445144524453445444554456445744584459446044614462446344644465446644674468446944704471447244734474447544764477447844794480448144824483448444854486448744884489449044914492449344944495449644974498449945004501450245034504450545064507450845094510451145124513451445154516451745184519452045214522452345244525452645274528452945304531453245334534453545364537453845394540454145424543454445454546454745484549455045514552455345544555455645574558455945604561456245634564456545664567456845694570457145724573457445754576457745784579458045814582458345844585458645874588458945904591459245934594459545964597459845994600460146024603460446054606460746084609461046114612461346144615461646174618461946204621462246234624462546264627462846294630463146324633463446354636463746384639464046414642464346444645464646474648464946504651465246534654465546564657465846594660466146624663466446654666466746684669467046714672467346744675467646774678467946804681468246834684468546864687468846894690469146924693469446954696469746984699470047014702470347044705470647074708470947104711471247134714471547164717471847194720472147224723472447254726472747284729473047314732473347344735473647374738473947404741474247434744474547464747474847494750475147524753475447554756475747584759476047614762476347644765476647674768476947704771477247734774477547764777477847794780478147824783478447854786478747884789479047914792479347944795479647974798479948004801480248034804480548064807480848094810481148124813481448154816481748184819482048214822482348244825482648274828482948304831483248334834483548364837483848394840484148424843484448454846484748484849485048514852485348544855485648574858485948604861486248634864486548664867486848694870487148724873487448754876487748784879488048814882488348844885488648874888488948904891489248934894489548964897489848994900490149024903490449054906490749084909491049114912491349144915491649174918491949204921492249234924492549264927492849294930493149324933493449354936493749384939494049414942494349444945494649474948494949504951495249534954495549564957495849594960496149624963496449654966496749684969497049714972497349744975497649774978497949804981498249834984498549864987498849894990499149924993499449954996499749984999500050015002500350045005500650075008500950105011501250135014501550165017501850195020502150225023502450255026502750285029503050315032503350345035503650375038503950405041504250435044504550465047504850495050505150525053505450555056505750585059506050615062506350645065506650675068506950705071507250735074507550765077507850795080508150825083508450855086508750885089509050915092509350945095509650975098509951005101510251035104510551065107510851095110511151125113511451155116511751185119512051215122512351245125512651275128512951305131513251335134513551365137513851395140514151425143514451455146514751485149515051515152515351545155515651575158515951605161516251635164516551665167516851695170517151725173517451755176517751785179518051815182518351845185518651875188518951905191519251935194519551965197519851995200520152025203520452055206520752085209521052115212521352145215521652175218521952205221522252235224522552265227522852295230523152325233523452355236523752385239524052415242524352445245524652475248524952505251525252535254525552565257525852595260526152625263526452655266526752685269527052715272527352745275527652775278527952805281528252835284528552865287528852895290529152925293529452955296529752985299530053015302530353045305530653075308530953105311531253135314531553165317531853195320532153225323532453255326532753285329533053315332533353345335533653375338533953405341534253435344534553465347534853495350535153525353535453555356535753585359536053615362536353645365536653675368536953705371537253735374537553765377537853795380538153825383538453855386538753885389539053915392539353945395539653975398539954005401540254035404540554065407540854095410541154125413541454155416541754185419542054215422542354245425542654275428542954305431543254335434543554365437543854395440544154425443544454455446544754485449545054515452545354545455545654575458545954605461546254635464546554665467546854695470547154725473547454755476547754785479548054815482548354845485548654875488548954905491549254935494549554965497549854995500550155025503550455055506550755085509551055115512551355145515551655175518551955205521552255235524552555265527552855295530553155325533553455355536553755385539554055415542554355445545554655475548554955505551555255535554555555565557555855595560556155625563556455655566556755685569557055715572557355745575557655775578557955805581558255835584558555865587558855895590559155925593559455955596559755985599560056015602560356045605560656075608560956105611561256135614561556165617561856195620562156225623562456255626562756285629563056315632563356345635563656375638563956405641564256435644564556465647564856495650565156525653565456555656565756585659566056615662566356645665566656675668566956705671567256735674567556765677567856795680568156825683568456855686568756885689569056915692569356945695569656975698569957005701570257035704570557065707570857095710571157125713571457155716571757185719572057215722572357245725572657275728572957305731573257335734573557365737573857395740574157425743574457455746574757485749575057515752575357545755575657575758575957605761576257635764576557665767576857695770577157725773577457755776577757785779578057815782578357845785578657875788578957905791579257935794579557965797579857995800580158025803580458055806580758085809581058115812581358145815581658175818581958205821582258235824582558265827582858295830583158325833583458355836583758385839584058415842584358445845584658475848584958505851585258535854585558565857585858595860586158625863586458655866586758685869587058715872587358745875587658775878587958805881588258835884588558865887588858895890589158925893589458955896589758985899590059015902590359045905590659075908590959105911591259135914591559165917591859195920592159225923592459255926592759285929593059315932593359345935593659375938593959405941594259435944594559465947594859495950595159525953595459555956595759585959596059615962596359645965596659675968596959705971597259735974597559765977597859795980598159825983598459855986598759885989599059915992599359945995599659975998599960006001600260036004600560066007600860096010601160126013601460156016601760186019602060216022602360246025602660276028602960306031603260336034603560366037603860396040604160426043604460456046604760486049605060516052605360546055605660576058605960606061606260636064606560666067606860696070607160726073607460756076607760786079608060816082608360846085608660876088608960906091609260936094609560966097609860996100610161026103610461056106610761086109611061116112611361146115611661176118611961206121612261236124612561266127612861296130613161326133613461356136613761386139614061416142614361446145614661476148614961506151615261536154615561566157615861596160616161626163616461656166616761686169617061716172617361746175617661776178617961806181618261836184618561866187618861896190619161926193619461956196619761986199620062016202620362046205620662076208620962106211621262136214621562166217621862196220622162226223622462256226622762286229623062316232623362346235623662376238623962406241624262436244624562466247624862496250625162526253625462556256625762586259626062616262626362646265626662676268626962706271627262736274627562766277627862796280628162826283628462856286628762886289629062916292629362946295629662976298629963006301630263036304630563066307630863096310631163126313631463156316631763186319632063216322632363246325632663276328632963306331633263336334633563366337633863396340634163426343634463456346634763486349635063516352635363546355635663576358635963606361636263636364636563666367636863696370637163726373637463756376637763786379638063816382638363846385638663876388638963906391639263936394639563966397639863996400640164026403640464056406640764086409641064116412641364146415641664176418641964206421642264236424642564266427642864296430643164326433643464356436643764386439644064416442644364446445644664476448644964506451645264536454645564566457645864596460646164626463646464656466646764686469647064716472647364746475647664776478647964806481648264836484648564866487648864896490649164926493649464956496649764986499650065016502650365046505650665076508650965106511651265136514651565166517651865196520652165226523652465256526652765286529653065316532653365346535653665376538653965406541654265436544654565466547654865496550655165526553655465556556655765586559656065616562656365646565656665676568656965706571657265736574657565766577657865796580658165826583658465856586658765886589659065916592659365946595659665976598659966006601660266036604660566066607660866096610661166126613661466156616661766186619662066216622662366246625662666276628662966306631663266336634663566366637663866396640664166426643664466456646664766486649665066516652665366546655665666576658665966606661666266636664666566666667666866696670667166726673667466756676667766786679668066816682668366846685668666876688668966906691669266936694669566966697669866996700670167026703670467056706670767086709671067116712671367146715671667176718671967206721672267236724672567266727672867296730673167326733673467356736673767386739674067416742674367446745674667476748674967506751675267536754675567566757675867596760676167626763676467656766676767686769677067716772677367746775677667776778677967806781678267836784678567866787678867896790679167926793679467956796679767986799680068016802680368046805680668076808680968106811681268136814681568166817681868196820682168226823682468256826682768286829683068316832683368346835683668376838683968406841684268436844684568466847684868496850685168526853685468556856685768586859686068616862686368646865686668676868686968706871687268736874687568766877687868796880688168826883688468856886688768886889689068916892689368946895689668976898689969006901690269036904690569066907690869096910691169126913691469156916691769186919692069216922692369246925692669276928692969306931693269336934693569366937693869396940694169426943694469456946694769486949695069516952695369546955695669576958695969606961696269636964696569666967696869696970697169726973697469756976697769786979698069816982698369846985698669876988698969906991699269936994699569966997699869997000700170027003700470057006700770087009701070117012701370147015701670177018701970207021702270237024702570267027702870297030703170327033703470357036703770387039704070417042704370447045704670477048704970507051705270537054705570567057705870597060706170627063706470657066706770687069707070717072707370747075707670777078707970807081708270837084708570867087708870897090709170927093709470957096709770987099710071017102710371047105710671077108710971107111711271137114711571167117711871197120712171227123712471257126712771287129713071317132713371347135713671377138713971407141714271437144714571467147714871497150715171527153715471557156715771587159716071617162716371647165716671677168716971707171717271737174717571767177717871797180718171827183718471857186718771887189719071917192719371947195719671977198719972007201720272037204720572067207720872097210721172127213721472157216721772187219722072217222722372247225722672277228722972307231723272337234723572367237723872397240724172427243724472457246724772487249725072517252725372547255725672577258725972607261726272637264726572667267726872697270727172727273727472757276727772787279728072817282728372847285728672877288728972907291729272937294729572967297729872997300730173027303730473057306730773087309731073117312731373147315731673177318731973207321732273237324732573267327732873297330733173327333733473357336733773387339734073417342734373447345734673477348734973507351735273537354735573567357735873597360736173627363736473657366736773687369737073717372737373747375737673777378737973807381738273837384738573867387738873897390739173927393739473957396739773987399740074017402740374047405740674077408740974107411741274137414741574167417741874197420742174227423742474257426742774287429743074317432743374347435743674377438743974407441744274437444744574467447744874497450745174527453745474557456745774587459746074617462746374647465746674677468746974707471747274737474747574767477747874797480748174827483748474857486748774887489749074917492749374947495749674977498749975007501750275037504750575067507750875097510751175127513751475157516751775187519752075217522752375247525752675277528752975307531753275337534753575367537753875397540754175427543754475457546754775487549755075517552755375547555755675577558755975607561756275637564756575667567756875697570757175727573757475757576757775787579758075817582758375847585758675877588758975907591759275937594759575967597759875997600760176027603760476057606760776087609761076117612761376147615761676177618761976207621762276237624762576267627762876297630763176327633763476357636763776387639764076417642764376447645764676477648764976507651765276537654765576567657765876597660766176627663766476657666766776687669767076717672767376747675767676777678767976807681768276837684768576867687768876897690769176927693769476957696769776987699770077017702770377047705770677077708770977107711771277137714771577167717771877197720772177227723772477257726772777287729773077317732773377347735773677377738773977407741774277437744774577467747774877497750775177527753775477557756775777587759776077617762776377647765776677677768776977707771777277737774777577767777777877797780778177827783778477857786778777887789779077917792779377947795779677977798779978007801780278037804780578067807780878097810781178127813781478157816781778187819782078217822782378247825782678277828782978307831783278337834783578367837783878397840784178427843784478457846784778487849785078517852785378547855785678577858785978607861786278637864786578667867786878697870787178727873787478757876787778787879788078817882788378847885788678877888788978907891789278937894789578967897789878997900790179027903790479057906790779087909791079117912791379147915791679177918791979207921792279237924792579267927792879297930793179327933793479357936793779387939794079417942794379447945794679477948794979507951795279537954795579567957795879597960796179627963796479657966796779687969797079717972797379747975797679777978797979807981798279837984798579867987798879897990799179927993799479957996799779987999800080018002800380048005800680078008800980108011801280138014801580168017801880198020802180228023802480258026802780288029803080318032803380348035803680378038803980408041804280438044804580468047804880498050805180528053805480558056805780588059806080618062806380648065806680678068806980708071807280738074807580768077807880798080808180828083808480858086808780888089809080918092809380948095809680978098809981008101810281038104810581068107810881098110811181128113811481158116811781188119812081218122812381248125812681278128812981308131813281338134813581368137813881398140814181428143814481458146814781488149815081518152815381548155815681578158815981608161816281638164816581668167816881698170817181728173817481758176817781788179818081818182818381848185818681878188818981908191819281938194819581968197819881998200820182028203820482058206820782088209821082118212821382148215821682178218821982208221822282238224822582268227822882298230823182328233823482358236823782388239824082418242824382448245824682478248824982508251825282538254825582568257825882598260826182628263826482658266826782688269827082718272827382748275827682778278827982808281828282838284828582868287828882898290829182928293829482958296829782988299830083018302830383048305830683078308830983108311831283138314831583168317831883198320832183228323832483258326832783288329833083318332833383348335833683378338833983408341834283438344834583468347834883498350835183528353835483558356835783588359836083618362836383648365836683678368836983708371837283738374837583768377837883798380838183828383838483858386838783888389839083918392839383948395839683978398839984008401840284038404840584068407840884098410841184128413841484158416841784188419842084218422842384248425842684278428842984308431843284338434843584368437843884398440844184428443844484458446844784488449845084518452845384548455845684578458845984608461846284638464846584668467846884698470847184728473847484758476847784788479848084818482848384848485848684878488848984908491849284938494849584968497849884998500850185028503850485058506850785088509851085118512851385148515851685178518851985208521852285238524852585268527852885298530853185328533853485358536853785388539854085418542854385448545854685478548854985508551855285538554855585568557855885598560856185628563856485658566856785688569857085718572857385748575857685778578857985808581858285838584858585868587858885898590859185928593859485958596859785988599860086018602860386048605860686078608860986108611861286138614861586168617861886198620862186228623862486258626862786288629863086318632863386348635863686378638863986408641864286438644864586468647864886498650865186528653865486558656865786588659866086618662866386648665866686678668866986708671867286738674867586768677867886798680868186828683868486858686868786888689869086918692869386948695869686978698869987008701870287038704870587068707870887098710871187128713871487158716871787188719872087218722872387248725872687278728872987308731873287338734873587368737873887398740874187428743874487458746874787488749875087518752875387548755875687578758875987608761876287638764876587668767876887698770877187728773877487758776877787788779878087818782878387848785878687878788878987908791879287938794879587968797879887998800880188028803880488058806880788088809881088118812881388148815881688178818881988208821882288238824882588268827882888298830883188328833883488358836883788388839884088418842884388448845884688478848884988508851885288538854885588568857885888598860886188628863886488658866886788688869887088718872887388748875887688778878887988808881888288838884888588868887888888898890889188928893889488958896889788988899890089018902890389048905890689078908890989108911891289138914891589168917891889198920892189228923892489258926892789288929893089318932893389348935893689378938893989408941894289438944894589468947894889498950895189528953895489558956895789588959896089618962896389648965896689678968896989708971897289738974897589768977897889798980898189828983898489858986898789888989899089918992899389948995899689978998899990009001900290039004900590069007900890099010901190129013901490159016901790189019902090219022902390249025902690279028902990309031903290339034903590369037903890399040904190429043904490459046904790489049905090519052905390549055905690579058905990609061906290639064906590669067906890699070907190729073907490759076907790789079908090819082908390849085908690879088908990909091909290939094909590969097909890999100910191029103910491059106910791089109911091119112911391149115911691179118911991209121912291239124912591269127912891299130913191329133913491359136913791389139914091419142914391449145914691479148914991509151915291539154915591569157915891599160916191629163916491659166916791689169917091719172917391749175917691779178917991809181918291839184918591869187918891899190919191929193919491959196919791989199920092019202920392049205920692079208920992109211921292139214921592169217921892199220922192229223922492259226922792289229923092319232923392349235923692379238923992409241924292439244924592469247924892499250925192529253925492559256925792589259926092619262926392649265926692679268926992709271927292739274927592769277927892799280928192829283928492859286928792889289929092919292929392949295929692979298929993009301930293039304930593069307930893099310931193129313931493159316931793189319932093219322932393249325932693279328932993309331933293339334933593369337933893399340934193429343934493459346934793489349935093519352935393549355935693579358935993609361936293639364936593669367936893699370937193729373937493759376937793789379938093819382938393849385938693879388938993909391939293939394939593969397939893999400940194029403940494059406940794089409941094119412941394149415941694179418941994209421942294239424942594269427942894299430943194329433943494359436943794389439944094419442944394449445944694479448944994509451945294539454945594569457945894599460946194629463946494659466946794689469947094719472947394749475947694779478947994809481948294839484948594869487948894899490949194929493949494959496949794989499950095019502950395049505950695079508950995109511951295139514951595169517951895199520952195229523952495259526952795289529953095319532953395349535953695379538953995409541954295439544954595469547954895499550955195529553955495559556955795589559956095619562956395649565956695679568956995709571957295739574957595769577957895799580958195829583958495859586958795889589959095919592959395949595959695979598959996009601960296039604960596069607960896099610961196129613961496159616961796189619962096219622962396249625962696279628962996309631963296339634963596369637963896399640964196429643964496459646964796489649965096519652965396549655965696579658965996609661966296639664966596669667966896699670967196729673967496759676967796789679968096819682968396849685968696879688968996909691969296939694969596969697969896999700970197029703970497059706970797089709971097119712971397149715971697179718971997209721972297239724972597269727972897299730973197329733973497359736973797389739974097419742974397449745974697479748974997509751975297539754975597569757975897599760976197629763976497659766976797689769977097719772977397749775977697779778977997809781978297839784978597869787978897899790979197929793979497959796979797989799980098019802980398049805980698079808980998109811981298139814981598169817981898199820982198229823982498259826982798289829983098319832983398349835983698379838983998409841984298439844984598469847984898499850985198529853985498559856985798589859986098619862986398649865986698679868986998709871987298739874987598769877987898799880988198829883988498859886988798889889989098919892989398949895989698979898989999009901990299039904990599069907990899099910991199129913991499159916991799189919992099219922992399249925992699279928992999309931993299339934993599369937993899399940994199429943994499459946994799489949995099519952995399549955995699579958995999609961996299639964996599669967996899699970997199729973997499759976997799789979998099819982998399849985998699879988998999909991999299939994999599969997999899991000010001100021000310004100051000610007100081000910010100111001210013100141001510016100171001810019100201002110022100231002410025100261002710028100291003010031100321003310034100351003610037100381003910040100411004210043100441004510046100471004810049100501005110052100531005410055100561005710058100591006010061100621006310064100651006610067100681006910070100711007210073100741007510076100771007810079100801008110082100831008410085100861008710088100891009010091100921009310094100951009610097100981009910100101011010210103101041010510106101071010810109101101011110112101131011410115101161011710118101191012010121101221012310124101251012610127101281012910130101311013210133101341013510136101371013810139101401014110142101431014410145101461014710148101491015010151101521015310154101551015610157101581015910160101611016210163101641016510166101671016810169101701017110172101731017410175101761017710178101791018010181101821018310184101851018610187101881018910190101911019210193101941019510196101971019810199102001020110202102031020410205102061020710208102091021010211102121021310214102151021610217102181021910220102211022210223102241022510226102271022810229102301023110232102331023410235102361023710238102391024010241102421024310244102451024610247102481024910250102511025210253102541025510256102571025810259102601026110262102631026410265102661026710268102691027010271102721027310274102751027610277102781027910280102811028210283102841028510286102871028810289102901029110292102931029410295102961029710298102991030010301103021030310304103051030610307103081030910310103111031210313103141031510316103171031810319103201032110322103231032410325103261032710328103291033010331103321033310334103351033610337103381033910340103411034210343103441034510346103471034810349103501035110352103531035410355103561035710358103591036010361103621036310364103651036610367103681036910370103711037210373103741037510376103771037810379103801038110382103831038410385103861038710388103891039010391103921039310394103951039610397103981039910400104011040210403104041040510406104071040810409104101041110412104131041410415104161041710418104191042010421104221042310424104251042610427104281042910430104311043210433104341043510436104371043810439104401044110442104431044410445104461044710448104491045010451104521045310454104551045610457104581045910460104611046210463104641046510466104671046810469104701047110472104731047410475104761047710478104791048010481104821048310484104851048610487104881048910490104911049210493104941049510496104971049810499105001050110502105031050410505105061050710508105091051010511105121051310514105151051610517105181051910520105211052210523105241052510526105271052810529105301053110532105331053410535105361053710538105391054010541105421054310544105451054610547105481054910550105511055210553105541055510556105571055810559105601056110562105631056410565105661056710568105691057010571105721057310574105751057610577105781057910580105811058210583105841058510586105871058810589105901059110592105931059410595105961059710598105991060010601106021060310604106051060610607106081060910610106111061210613106141061510616106171061810619106201062110622106231062410625106261062710628106291063010631106321063310634106351063610637106381063910640106411064210643106441064510646106471064810649106501065110652106531065410655106561065710658106591066010661106621066310664106651066610667106681066910670106711067210673106741067510676106771067810679106801068110682106831068410685106861068710688106891069010691106921069310694106951069610697106981069910700107011070210703107041070510706107071070810709107101071110712107131071410715107161071710718107191072010721107221072310724107251072610727107281072910730107311073210733107341073510736107371073810739107401074110742107431074410745107461074710748107491075010751107521075310754107551075610757107581075910760107611076210763107641076510766107671076810769107701077110772107731077410775107761077710778107791078010781107821078310784107851078610787107881078910790107911079210793107941079510796107971079810799108001080110802108031080410805108061080710808108091081010811108121081310814108151081610817108181081910820108211082210823108241082510826108271082810829108301083110832108331083410835108361083710838108391084010841108421084310844108451084610847108481084910850108511085210853108541085510856108571085810859108601086110862108631086410865108661086710868108691087010871108721087310874108751087610877108781087910880108811088210883108841088510886108871088810889108901089110892108931089410895108961089710898108991090010901109021090310904109051090610907109081090910910109111091210913109141091510916109171091810919109201092110922109231092410925109261092710928109291093010931109321093310934109351093610937109381093910940109411094210943109441094510946109471094810949109501095110952109531095410955109561095710958109591096010961109621096310964109651096610967109681096910970109711097210973109741097510976109771097810979109801098110982109831098410985109861098710988109891099010991109921099310994109951099610997109981099911000110011100211003110041100511006110071100811009110101101111012110131101411015110161101711018110191102011021110221102311024110251102611027110281102911030110311103211033110341103511036110371103811039110401104111042110431104411045110461104711048110491105011051110521105311054110551105611057110581105911060110611106211063110641106511066110671106811069110701107111072110731107411075110761107711078110791108011081110821108311084110851108611087110881108911090110911109211093110941109511096110971109811099111001110111102111031110411105111061110711108111091111011111111121111311114111151111611117111181111911120111211112211123111241112511126111271112811129111301113111132111331113411135111361113711138111391114011141111421114311144111451114611147111481114911150111511115211153111541115511156111571115811159111601116111162111631116411165111661116711168111691117011171111721117311174111751117611177111781117911180111811118211183111841118511186111871118811189111901119111192111931119411195111961119711198111991120011201112021120311204112051120611207112081120911210112111121211213112141121511216112171121811219112201122111222112231122411225112261122711228112291123011231112321123311234112351123611237112381123911240112411124211243112441124511246112471124811249112501125111252112531125411255112561125711258112591126011261112621126311264112651126611267112681126911270112711127211273112741127511276112771127811279112801128111282112831128411285112861128711288112891129011291112921129311294112951129611297112981129911300113011130211303113041130511306113071130811309113101131111312113131131411315113161131711318113191132011321113221132311324113251132611327113281132911330113311133211333113341133511336113371133811339113401134111342113431134411345113461134711348113491135011351113521135311354113551135611357113581135911360113611136211363113641136511366113671136811369113701137111372113731137411375113761137711378113791138011381113821138311384113851138611387113881138911390113911139211393113941139511396113971139811399114001140111402114031140411405114061140711408114091141011411114121141311414114151141611417114181141911420114211142211423114241142511426114271142811429114301143111432114331143411435114361143711438114391144011441114421144311444114451144611447114481144911450114511145211453114541145511456114571145811459114601146111462114631146411465114661146711468114691147011471114721147311474114751147611477114781147911480114811148211483114841148511486114871148811489114901149111492114931149411495114961149711498114991150011501115021150311504115051150611507115081150911510115111151211513115141151511516115171151811519115201152111522115231152411525115261152711528115291153011531115321153311534115351153611537115381153911540115411154211543115441154511546115471154811549115501155111552115531155411555115561155711558115591156011561115621156311564115651156611567115681156911570115711157211573115741157511576115771157811579115801158111582115831158411585115861158711588115891159011591115921159311594115951159611597115981159911600116011160211603116041160511606116071160811609116101161111612116131161411615116161161711618116191162011621116221162311624116251162611627116281162911630116311163211633116341163511636116371163811639116401164111642116431164411645116461164711648116491165011651116521165311654116551165611657116581165911660116611166211663116641166511666116671166811669116701167111672116731167411675116761167711678116791168011681116821168311684116851168611687116881168911690116911169211693116941169511696116971169811699117001170111702117031170411705117061170711708117091171011711117121171311714117151171611717117181171911720117211172211723117241172511726117271172811729117301173111732117331173411735117361173711738117391174011741117421174311744117451174611747117481174911750117511175211753
  1. # A Swagger 2.0 (a.k.a. OpenAPI) definition of the Engine API.
  2. #
  3. # This is used for generating API documentation and the types used by the
  4. # client/server. See api/README.md for more information.
  5. #
  6. # Some style notes:
  7. # - This file is used by ReDoc, which allows GitHub Flavored Markdown in
  8. # descriptions.
  9. # - There is no maximum line length, for ease of editing and pretty diffs.
  10. # - operationIds are in the format "NounVerb", with a singular noun.
  11. swagger: "2.0"
  12. schemes:
  13. - "http"
  14. - "https"
  15. produces:
  16. - "application/json"
  17. - "text/plain"
  18. consumes:
  19. - "application/json"
  20. - "text/plain"
  21. basePath: "/v1.41"
  22. info:
  23. title: "Docker Engine API"
  24. version: "1.41"
  25. x-logo:
  26. url: "https://docs.docker.com/assets/images/logo-docker-main.png"
  27. description: |
  28. The Engine API is an HTTP API served by Docker Engine. It is the API the
  29. Docker client uses to communicate with the Engine, so everything the Docker
  30. client can do can be done with the API.
  31. Most of the client's commands map directly to API endpoints (e.g. `docker ps`
  32. is `GET /containers/json`). The notable exception is running containers,
  33. which consists of several API calls.
  34. # Errors
  35. The API uses standard HTTP status codes to indicate the success or failure
  36. of the API call. The body of the response will be JSON in the following
  37. format:
  38. ```
  39. {
  40. "message": "page not found"
  41. }
  42. ```
  43. # Versioning
  44. The API is usually changed in each release, so API calls are versioned to
  45. ensure that clients don't break. To lock to a specific version of the API,
  46. you prefix the URL with its version, for example, call `/v1.30/info` to use
  47. the v1.30 version of the `/info` endpoint. If the API version specified in
  48. the URL is not supported by the daemon, a HTTP `400 Bad Request` error message
  49. is returned.
  50. If you omit the version-prefix, the current version of the API (v1.41) is used.
  51. For example, calling `/info` is the same as calling `/v1.41/info`. Using the
  52. API without a version-prefix is deprecated and will be removed in a future release.
  53. Engine releases in the near future should support this version of the API,
  54. so your client will continue to work even if it is talking to a newer Engine.
  55. The API uses an open schema model, which means server may add extra properties
  56. to responses. Likewise, the server will ignore any extra query parameters and
  57. request body properties. When you write clients, you need to ignore additional
  58. properties in responses to ensure they do not break when talking to newer
  59. daemons.
  60. # Authentication
  61. Authentication for registries is handled client side. The client has to send
  62. authentication details to various endpoints that need to communicate with
  63. registries, such as `POST /images/(name)/push`. These are sent as
  64. `X-Registry-Auth` header as a [base64url encoded](https://tools.ietf.org/html/rfc4648#section-5)
  65. (JSON) string with the following structure:
  66. ```
  67. {
  68. "username": "string",
  69. "password": "string",
  70. "email": "string",
  71. "serveraddress": "string"
  72. }
  73. ```
  74. The `serveraddress` is a domain/IP without a protocol. Throughout this
  75. structure, double quotes are required.
  76. If you have already got an identity token from the [`/auth` endpoint](#operation/SystemAuth),
  77. you can just pass this instead of credentials:
  78. ```
  79. {
  80. "identitytoken": "9cbaf023786cd7..."
  81. }
  82. ```
  83. # The tags on paths define the menu sections in the ReDoc documentation, so
  84. # the usage of tags must make sense for that:
  85. # - They should be singular, not plural.
  86. # - There should not be too many tags, or the menu becomes unwieldy. For
  87. # example, it is preferable to add a path to the "System" tag instead of
  88. # creating a tag with a single path in it.
  89. # - The order of tags in this list defines the order in the menu.
  90. tags:
  91. # Primary objects
  92. - name: "Container"
  93. x-displayName: "Containers"
  94. description: |
  95. Create and manage containers.
  96. - name: "Image"
  97. x-displayName: "Images"
  98. - name: "Network"
  99. x-displayName: "Networks"
  100. description: |
  101. Networks are user-defined networks that containers can be attached to.
  102. See the [networking documentation](https://docs.docker.com/network/)
  103. for more information.
  104. - name: "Volume"
  105. x-displayName: "Volumes"
  106. description: |
  107. Create and manage persistent storage that can be attached to containers.
  108. - name: "Exec"
  109. x-displayName: "Exec"
  110. description: |
  111. Run new commands inside running containers. Refer to the
  112. [command-line reference](https://docs.docker.com/engine/reference/commandline/exec/)
  113. for more information.
  114. To exec a command in a container, you first need to create an exec instance,
  115. then start it. These two API endpoints are wrapped up in a single command-line
  116. command, `docker exec`.
  117. # Swarm things
  118. - name: "Swarm"
  119. x-displayName: "Swarm"
  120. description: |
  121. Engines can be clustered together in a swarm. Refer to the
  122. [swarm mode documentation](https://docs.docker.com/engine/swarm/)
  123. for more information.
  124. - name: "Node"
  125. x-displayName: "Nodes"
  126. description: |
  127. Nodes are instances of the Engine participating in a swarm. Swarm mode
  128. must be enabled for these endpoints to work.
  129. - name: "Service"
  130. x-displayName: "Services"
  131. description: |
  132. Services are the definitions of tasks to run on a swarm. Swarm mode must
  133. be enabled for these endpoints to work.
  134. - name: "Task"
  135. x-displayName: "Tasks"
  136. description: |
  137. A task is a container running on a swarm. It is the atomic scheduling unit
  138. of swarm. Swarm mode must be enabled for these endpoints to work.
  139. - name: "Secret"
  140. x-displayName: "Secrets"
  141. description: |
  142. Secrets are sensitive data that can be used by services. Swarm mode must
  143. be enabled for these endpoints to work.
  144. - name: "Config"
  145. x-displayName: "Configs"
  146. description: |
  147. Configs are application configurations that can be used by services. Swarm
  148. mode must be enabled for these endpoints to work.
  149. # System things
  150. - name: "Plugin"
  151. x-displayName: "Plugins"
  152. - name: "System"
  153. x-displayName: "System"
  154. definitions:
  155. Port:
  156. type: "object"
  157. description: "An open port on a container"
  158. required: [PrivatePort, Type]
  159. properties:
  160. IP:
  161. type: "string"
  162. format: "ip-address"
  163. description: "Host IP address that the container's port is mapped to"
  164. PrivatePort:
  165. type: "integer"
  166. format: "uint16"
  167. x-nullable: false
  168. description: "Port on the container"
  169. PublicPort:
  170. type: "integer"
  171. format: "uint16"
  172. description: "Port exposed on the host"
  173. Type:
  174. type: "string"
  175. x-nullable: false
  176. enum: ["tcp", "udp", "sctp"]
  177. example:
  178. PrivatePort: 8080
  179. PublicPort: 80
  180. Type: "tcp"
  181. MountPoint:
  182. type: "object"
  183. description: |
  184. MountPoint represents a mount point configuration inside the container.
  185. This is used for reporting the mountpoints in use by a container.
  186. properties:
  187. Type:
  188. description: |
  189. The mount type:
  190. - `bind` a mount of a file or directory from the host into the container.
  191. - `volume` a docker volume with the given `Name`.
  192. - `tmpfs` a `tmpfs`.
  193. - `npipe` a named pipe from the host into the container.
  194. type: "string"
  195. enum:
  196. - "bind"
  197. - "volume"
  198. - "tmpfs"
  199. - "npipe"
  200. example: "volume"
  201. Name:
  202. description: |
  203. Name is the name reference to the underlying data defined by `Source`
  204. e.g., the volume name.
  205. type: "string"
  206. example: "myvolume"
  207. Source:
  208. description: |
  209. Source location of the mount.
  210. For volumes, this contains the storage location of the volume (within
  211. `/var/lib/docker/volumes/`). For bind-mounts, and `npipe`, this contains
  212. the source (host) part of the bind-mount. For `tmpfs` mount points, this
  213. field is empty.
  214. type: "string"
  215. example: "/var/lib/docker/volumes/myvolume/_data"
  216. Destination:
  217. description: |
  218. Destination is the path relative to the container root (`/`) where
  219. the `Source` is mounted inside the container.
  220. type: "string"
  221. example: "/usr/share/nginx/html/"
  222. Driver:
  223. description: |
  224. Driver is the volume driver used to create the volume (if it is a volume).
  225. type: "string"
  226. example: "local"
  227. Mode:
  228. description: |
  229. Mode is a comma separated list of options supplied by the user when
  230. creating the bind/volume mount.
  231. The default is platform-specific (`"z"` on Linux, empty on Windows).
  232. type: "string"
  233. example: "z"
  234. RW:
  235. description: |
  236. Whether the mount is mounted writable (read-write).
  237. type: "boolean"
  238. example: true
  239. Propagation:
  240. description: |
  241. Propagation describes how mounts are propagated from the host into the
  242. mount point, and vice-versa. Refer to the [Linux kernel documentation](https://www.kernel.org/doc/Documentation/filesystems/sharedsubtree.txt)
  243. for details. This field is not used on Windows.
  244. type: "string"
  245. example: ""
  246. DeviceMapping:
  247. type: "object"
  248. description: "A device mapping between the host and container"
  249. properties:
  250. PathOnHost:
  251. type: "string"
  252. PathInContainer:
  253. type: "string"
  254. CgroupPermissions:
  255. type: "string"
  256. example:
  257. PathOnHost: "/dev/deviceName"
  258. PathInContainer: "/dev/deviceName"
  259. CgroupPermissions: "mrw"
  260. DeviceRequest:
  261. type: "object"
  262. description: "A request for devices to be sent to device drivers"
  263. properties:
  264. Driver:
  265. type: "string"
  266. example: "nvidia"
  267. Count:
  268. type: "integer"
  269. example: -1
  270. DeviceIDs:
  271. type: "array"
  272. items:
  273. type: "string"
  274. example:
  275. - "0"
  276. - "1"
  277. - "GPU-fef8089b-4820-abfc-e83e-94318197576e"
  278. Capabilities:
  279. description: |
  280. A list of capabilities; an OR list of AND lists of capabilities.
  281. type: "array"
  282. items:
  283. type: "array"
  284. items:
  285. type: "string"
  286. example:
  287. # gpu AND nvidia AND compute
  288. - ["gpu", "nvidia", "compute"]
  289. Options:
  290. description: |
  291. Driver-specific options, specified as a key/value pairs. These options
  292. are passed directly to the driver.
  293. type: "object"
  294. additionalProperties:
  295. type: "string"
  296. ThrottleDevice:
  297. type: "object"
  298. properties:
  299. Path:
  300. description: "Device path"
  301. type: "string"
  302. Rate:
  303. description: "Rate"
  304. type: "integer"
  305. format: "int64"
  306. minimum: 0
  307. Mount:
  308. type: "object"
  309. properties:
  310. Target:
  311. description: "Container path."
  312. type: "string"
  313. Source:
  314. description: "Mount source (e.g. a volume name, a host path)."
  315. type: "string"
  316. Type:
  317. description: |
  318. The mount type. Available types:
  319. - `bind` Mounts a file or directory from the host into the container. Must exist prior to creating the container.
  320. - `volume` Creates a volume with the given name and options (or uses a pre-existing volume with the same name and options). These are **not** removed when the container is removed.
  321. - `tmpfs` Create a tmpfs with the given options. The mount source cannot be specified for tmpfs.
  322. - `npipe` Mounts a named pipe from the host into the container. Must exist prior to creating the container.
  323. type: "string"
  324. enum:
  325. - "bind"
  326. - "volume"
  327. - "tmpfs"
  328. - "npipe"
  329. ReadOnly:
  330. description: "Whether the mount should be read-only."
  331. type: "boolean"
  332. Consistency:
  333. description: "The consistency requirement for the mount: `default`, `consistent`, `cached`, or `delegated`."
  334. type: "string"
  335. BindOptions:
  336. description: "Optional configuration for the `bind` type."
  337. type: "object"
  338. properties:
  339. Propagation:
  340. description: "A propagation mode with the value `[r]private`, `[r]shared`, or `[r]slave`."
  341. type: "string"
  342. enum:
  343. - "private"
  344. - "rprivate"
  345. - "shared"
  346. - "rshared"
  347. - "slave"
  348. - "rslave"
  349. NonRecursive:
  350. description: "Disable recursive bind mount."
  351. type: "boolean"
  352. default: false
  353. VolumeOptions:
  354. description: "Optional configuration for the `volume` type."
  355. type: "object"
  356. properties:
  357. NoCopy:
  358. description: "Populate volume with data from the target."
  359. type: "boolean"
  360. default: false
  361. Labels:
  362. description: "User-defined key/value metadata."
  363. type: "object"
  364. additionalProperties:
  365. type: "string"
  366. DriverConfig:
  367. description: "Map of driver specific options"
  368. type: "object"
  369. properties:
  370. Name:
  371. description: "Name of the driver to use to create the volume."
  372. type: "string"
  373. Options:
  374. description: "key/value map of driver specific options."
  375. type: "object"
  376. additionalProperties:
  377. type: "string"
  378. TmpfsOptions:
  379. description: "Optional configuration for the `tmpfs` type."
  380. type: "object"
  381. properties:
  382. SizeBytes:
  383. description: "The size for the tmpfs mount in bytes."
  384. type: "integer"
  385. format: "int64"
  386. Mode:
  387. description: "The permission mode for the tmpfs mount in an integer."
  388. type: "integer"
  389. RestartPolicy:
  390. description: |
  391. The behavior to apply when the container exits. The default is not to
  392. restart.
  393. An ever increasing delay (double the previous delay, starting at 100ms) is
  394. added before each restart to prevent flooding the server.
  395. type: "object"
  396. properties:
  397. Name:
  398. type: "string"
  399. description: |
  400. - Empty string means not to restart
  401. - `no` Do not automatically restart
  402. - `always` Always restart
  403. - `unless-stopped` Restart always except when the user has manually stopped the container
  404. - `on-failure` Restart only when the container exit code is non-zero
  405. enum:
  406. - ""
  407. - "no"
  408. - "always"
  409. - "unless-stopped"
  410. - "on-failure"
  411. MaximumRetryCount:
  412. type: "integer"
  413. description: |
  414. If `on-failure` is used, the number of times to retry before giving up.
  415. Resources:
  416. description: "A container's resources (cgroups config, ulimits, etc)"
  417. type: "object"
  418. properties:
  419. # Applicable to all platforms
  420. CpuShares:
  421. description: |
  422. An integer value representing this container's relative CPU weight
  423. versus other containers.
  424. type: "integer"
  425. Memory:
  426. description: "Memory limit in bytes."
  427. type: "integer"
  428. format: "int64"
  429. default: 0
  430. # Applicable to UNIX platforms
  431. CgroupParent:
  432. description: |
  433. Path to `cgroups` under which the container's `cgroup` is created. If
  434. the path is not absolute, the path is considered to be relative to the
  435. `cgroups` path of the init process. Cgroups are created if they do not
  436. already exist.
  437. type: "string"
  438. BlkioWeight:
  439. description: "Block IO weight (relative weight)."
  440. type: "integer"
  441. minimum: 0
  442. maximum: 1000
  443. BlkioWeightDevice:
  444. description: |
  445. Block IO weight (relative device weight) in the form:
  446. ```
  447. [{"Path": "device_path", "Weight": weight}]
  448. ```
  449. type: "array"
  450. items:
  451. type: "object"
  452. properties:
  453. Path:
  454. type: "string"
  455. Weight:
  456. type: "integer"
  457. minimum: 0
  458. BlkioDeviceReadBps:
  459. description: |
  460. Limit read rate (bytes per second) from a device, in the form:
  461. ```
  462. [{"Path": "device_path", "Rate": rate}]
  463. ```
  464. type: "array"
  465. items:
  466. $ref: "#/definitions/ThrottleDevice"
  467. BlkioDeviceWriteBps:
  468. description: |
  469. Limit write rate (bytes per second) to a device, in the form:
  470. ```
  471. [{"Path": "device_path", "Rate": rate}]
  472. ```
  473. type: "array"
  474. items:
  475. $ref: "#/definitions/ThrottleDevice"
  476. BlkioDeviceReadIOps:
  477. description: |
  478. Limit read rate (IO per second) from a device, in the form:
  479. ```
  480. [{"Path": "device_path", "Rate": rate}]
  481. ```
  482. type: "array"
  483. items:
  484. $ref: "#/definitions/ThrottleDevice"
  485. BlkioDeviceWriteIOps:
  486. description: |
  487. Limit write rate (IO per second) to a device, in the form:
  488. ```
  489. [{"Path": "device_path", "Rate": rate}]
  490. ```
  491. type: "array"
  492. items:
  493. $ref: "#/definitions/ThrottleDevice"
  494. CpuPeriod:
  495. description: "The length of a CPU period in microseconds."
  496. type: "integer"
  497. format: "int64"
  498. CpuQuota:
  499. description: |
  500. Microseconds of CPU time that the container can get in a CPU period.
  501. type: "integer"
  502. format: "int64"
  503. CpuRealtimePeriod:
  504. description: |
  505. The length of a CPU real-time period in microseconds. Set to 0 to
  506. allocate no time allocated to real-time tasks.
  507. type: "integer"
  508. format: "int64"
  509. CpuRealtimeRuntime:
  510. description: |
  511. The length of a CPU real-time runtime in microseconds. Set to 0 to
  512. allocate no time allocated to real-time tasks.
  513. type: "integer"
  514. format: "int64"
  515. CpusetCpus:
  516. description: |
  517. CPUs in which to allow execution (e.g., `0-3`, `0,1`).
  518. type: "string"
  519. example: "0-3"
  520. CpusetMems:
  521. description: |
  522. Memory nodes (MEMs) in which to allow execution (0-3, 0,1). Only
  523. effective on NUMA systems.
  524. type: "string"
  525. Devices:
  526. description: "A list of devices to add to the container."
  527. type: "array"
  528. items:
  529. $ref: "#/definitions/DeviceMapping"
  530. DeviceCgroupRules:
  531. description: "a list of cgroup rules to apply to the container"
  532. type: "array"
  533. items:
  534. type: "string"
  535. example: "c 13:* rwm"
  536. DeviceRequests:
  537. description: |
  538. A list of requests for devices to be sent to device drivers.
  539. type: "array"
  540. items:
  541. $ref: "#/definitions/DeviceRequest"
  542. KernelMemory:
  543. description: |
  544. Kernel memory limit in bytes.
  545. <p><br /></p>
  546. > **Deprecated**: This field is deprecated as the kernel 5.4 deprecated
  547. > `kmem.limit_in_bytes`.
  548. type: "integer"
  549. format: "int64"
  550. example: 209715200
  551. KernelMemoryTCP:
  552. description: "Hard limit for kernel TCP buffer memory (in bytes)."
  553. type: "integer"
  554. format: "int64"
  555. MemoryReservation:
  556. description: "Memory soft limit in bytes."
  557. type: "integer"
  558. format: "int64"
  559. MemorySwap:
  560. description: |
  561. Total memory limit (memory + swap). Set as `-1` to enable unlimited
  562. swap.
  563. type: "integer"
  564. format: "int64"
  565. MemorySwappiness:
  566. description: |
  567. Tune a container's memory swappiness behavior. Accepts an integer
  568. between 0 and 100.
  569. type: "integer"
  570. format: "int64"
  571. minimum: 0
  572. maximum: 100
  573. NanoCpus:
  574. description: "CPU quota in units of 10<sup>-9</sup> CPUs."
  575. type: "integer"
  576. format: "int64"
  577. OomKillDisable:
  578. description: "Disable OOM Killer for the container."
  579. type: "boolean"
  580. Init:
  581. description: |
  582. Run an init inside the container that forwards signals and reaps
  583. processes. This field is omitted if empty, and the default (as
  584. configured on the daemon) is used.
  585. type: "boolean"
  586. x-nullable: true
  587. PidsLimit:
  588. description: |
  589. Tune a container's PIDs limit. Set `0` or `-1` for unlimited, or `null`
  590. to not change.
  591. type: "integer"
  592. format: "int64"
  593. x-nullable: true
  594. Ulimits:
  595. description: |
  596. A list of resource limits to set in the container. For example:
  597. ```
  598. {"Name": "nofile", "Soft": 1024, "Hard": 2048}
  599. ```
  600. type: "array"
  601. items:
  602. type: "object"
  603. properties:
  604. Name:
  605. description: "Name of ulimit"
  606. type: "string"
  607. Soft:
  608. description: "Soft limit"
  609. type: "integer"
  610. Hard:
  611. description: "Hard limit"
  612. type: "integer"
  613. # Applicable to Windows
  614. CpuCount:
  615. description: |
  616. The number of usable CPUs (Windows only).
  617. On Windows Server containers, the processor resource controls are
  618. mutually exclusive. The order of precedence is `CPUCount` first, then
  619. `CPUShares`, and `CPUPercent` last.
  620. type: "integer"
  621. format: "int64"
  622. CpuPercent:
  623. description: |
  624. The usable percentage of the available CPUs (Windows only).
  625. On Windows Server containers, the processor resource controls are
  626. mutually exclusive. The order of precedence is `CPUCount` first, then
  627. `CPUShares`, and `CPUPercent` last.
  628. type: "integer"
  629. format: "int64"
  630. IOMaximumIOps:
  631. description: "Maximum IOps for the container system drive (Windows only)"
  632. type: "integer"
  633. format: "int64"
  634. IOMaximumBandwidth:
  635. description: |
  636. Maximum IO in bytes per second for the container system drive
  637. (Windows only).
  638. type: "integer"
  639. format: "int64"
  640. Limit:
  641. description: |
  642. An object describing a limit on resources which can be requested by a task.
  643. type: "object"
  644. properties:
  645. NanoCPUs:
  646. type: "integer"
  647. format: "int64"
  648. example: 4000000000
  649. MemoryBytes:
  650. type: "integer"
  651. format: "int64"
  652. example: 8272408576
  653. Pids:
  654. description: |
  655. Limits the maximum number of PIDs in the container. Set `0` for unlimited.
  656. type: "integer"
  657. format: "int64"
  658. default: 0
  659. example: 100
  660. ResourceObject:
  661. description: |
  662. An object describing the resources which can be advertised by a node and
  663. requested by a task.
  664. type: "object"
  665. properties:
  666. NanoCPUs:
  667. type: "integer"
  668. format: "int64"
  669. example: 4000000000
  670. MemoryBytes:
  671. type: "integer"
  672. format: "int64"
  673. example: 8272408576
  674. GenericResources:
  675. $ref: "#/definitions/GenericResources"
  676. GenericResources:
  677. description: |
  678. User-defined resources can be either Integer resources (e.g, `SSD=3`) or
  679. String resources (e.g, `GPU=UUID1`).
  680. type: "array"
  681. items:
  682. type: "object"
  683. properties:
  684. NamedResourceSpec:
  685. type: "object"
  686. properties:
  687. Kind:
  688. type: "string"
  689. Value:
  690. type: "string"
  691. DiscreteResourceSpec:
  692. type: "object"
  693. properties:
  694. Kind:
  695. type: "string"
  696. Value:
  697. type: "integer"
  698. format: "int64"
  699. example:
  700. - DiscreteResourceSpec:
  701. Kind: "SSD"
  702. Value: 3
  703. - NamedResourceSpec:
  704. Kind: "GPU"
  705. Value: "UUID1"
  706. - NamedResourceSpec:
  707. Kind: "GPU"
  708. Value: "UUID2"
  709. HealthConfig:
  710. description: "A test to perform to check that the container is healthy."
  711. type: "object"
  712. properties:
  713. Test:
  714. description: |
  715. The test to perform. Possible values are:
  716. - `[]` inherit healthcheck from image or parent image
  717. - `["NONE"]` disable healthcheck
  718. - `["CMD", args...]` exec arguments directly
  719. - `["CMD-SHELL", command]` run command with system's default shell
  720. type: "array"
  721. items:
  722. type: "string"
  723. Interval:
  724. description: |
  725. The time to wait between checks in nanoseconds. It should be 0 or at
  726. least 1000000 (1 ms). 0 means inherit.
  727. type: "integer"
  728. format: "int64"
  729. Timeout:
  730. description: |
  731. The time to wait before considering the check to have hung. It should
  732. be 0 or at least 1000000 (1 ms). 0 means inherit.
  733. type: "integer"
  734. format: "int64"
  735. Retries:
  736. description: |
  737. The number of consecutive failures needed to consider a container as
  738. unhealthy. 0 means inherit.
  739. type: "integer"
  740. StartPeriod:
  741. description: |
  742. Start period for the container to initialize before starting
  743. health-retries countdown in nanoseconds. It should be 0 or at least
  744. 1000000 (1 ms). 0 means inherit.
  745. type: "integer"
  746. format: "int64"
  747. Health:
  748. description: |
  749. Health stores information about the container's healthcheck results.
  750. type: "object"
  751. x-nullable: true
  752. properties:
  753. Status:
  754. description: |
  755. Status is one of `none`, `starting`, `healthy` or `unhealthy`
  756. - "none" Indicates there is no healthcheck
  757. - "starting" Starting indicates that the container is not yet ready
  758. - "healthy" Healthy indicates that the container is running correctly
  759. - "unhealthy" Unhealthy indicates that the container has a problem
  760. type: "string"
  761. enum:
  762. - "none"
  763. - "starting"
  764. - "healthy"
  765. - "unhealthy"
  766. example: "healthy"
  767. FailingStreak:
  768. description: "FailingStreak is the number of consecutive failures"
  769. type: "integer"
  770. example: 0
  771. Log:
  772. type: "array"
  773. description: |
  774. Log contains the last few results (oldest first)
  775. items:
  776. $ref: "#/definitions/HealthcheckResult"
  777. HealthcheckResult:
  778. description: |
  779. HealthcheckResult stores information about a single run of a healthcheck probe
  780. type: "object"
  781. x-nullable: true
  782. properties:
  783. Start:
  784. description: |
  785. Date and time at which this check started in
  786. [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format with nano-seconds.
  787. type: "string"
  788. format: "date-time"
  789. example: "2020-01-04T10:44:24.496525531Z"
  790. End:
  791. description: |
  792. Date and time at which this check ended in
  793. [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format with nano-seconds.
  794. type: "string"
  795. format: "dateTime"
  796. example: "2020-01-04T10:45:21.364524523Z"
  797. ExitCode:
  798. description: |
  799. ExitCode meanings:
  800. - `0` healthy
  801. - `1` unhealthy
  802. - `2` reserved (considered unhealthy)
  803. - other values: error running probe
  804. type: "integer"
  805. example: 0
  806. Output:
  807. description: "Output from last check"
  808. type: "string"
  809. HostConfig:
  810. description: "Container configuration that depends on the host we are running on"
  811. allOf:
  812. - $ref: "#/definitions/Resources"
  813. - type: "object"
  814. properties:
  815. # Applicable to all platforms
  816. Binds:
  817. type: "array"
  818. description: |
  819. A list of volume bindings for this container. Each volume binding
  820. is a string in one of these forms:
  821. - `host-src:container-dest[:options]` to bind-mount a host path
  822. into the container. Both `host-src`, and `container-dest` must
  823. be an _absolute_ path.
  824. - `volume-name:container-dest[:options]` to bind-mount a volume
  825. managed by a volume driver into the container. `container-dest`
  826. must be an _absolute_ path.
  827. `options` is an optional, comma-delimited list of:
  828. - `nocopy` disables automatic copying of data from the container
  829. path to the volume. The `nocopy` flag only applies to named volumes.
  830. - `[ro|rw]` mounts a volume read-only or read-write, respectively.
  831. If omitted or set to `rw`, volumes are mounted read-write.
  832. - `[z|Z]` applies SELinux labels to allow or deny multiple containers
  833. to read and write to the same volume.
  834. - `z`: a _shared_ content label is applied to the content. This
  835. label indicates that multiple containers can share the volume
  836. content, for both reading and writing.
  837. - `Z`: a _private unshared_ label is applied to the content.
  838. This label indicates that only the current container can use
  839. a private volume. Labeling systems such as SELinux require
  840. proper labels to be placed on volume content that is mounted
  841. into a container. Without a label, the security system can
  842. prevent a container's processes from using the content. By
  843. default, the labels set by the host operating system are not
  844. modified.
  845. - `[[r]shared|[r]slave|[r]private]` specifies mount
  846. [propagation behavior](https://www.kernel.org/doc/Documentation/filesystems/sharedsubtree.txt).
  847. This only applies to bind-mounted volumes, not internal volumes
  848. or named volumes. Mount propagation requires the source mount
  849. point (the location where the source directory is mounted in the
  850. host operating system) to have the correct propagation properties.
  851. For shared volumes, the source mount point must be set to `shared`.
  852. For slave volumes, the mount must be set to either `shared` or
  853. `slave`.
  854. items:
  855. type: "string"
  856. ContainerIDFile:
  857. type: "string"
  858. description: "Path to a file where the container ID is written"
  859. LogConfig:
  860. type: "object"
  861. description: "The logging configuration for this container"
  862. properties:
  863. Type:
  864. type: "string"
  865. enum:
  866. - "json-file"
  867. - "syslog"
  868. - "journald"
  869. - "gelf"
  870. - "fluentd"
  871. - "awslogs"
  872. - "splunk"
  873. - "etwlogs"
  874. - "none"
  875. Config:
  876. type: "object"
  877. additionalProperties:
  878. type: "string"
  879. NetworkMode:
  880. type: "string"
  881. description: |
  882. Network mode to use for this container. Supported standard values
  883. are: `bridge`, `host`, `none`, and `container:<name|id>`. Any
  884. other value is taken as a custom network's name to which this
  885. container should connect to.
  886. PortBindings:
  887. $ref: "#/definitions/PortMap"
  888. RestartPolicy:
  889. $ref: "#/definitions/RestartPolicy"
  890. AutoRemove:
  891. type: "boolean"
  892. description: |
  893. Automatically remove the container when the container's process
  894. exits. This has no effect if `RestartPolicy` is set.
  895. VolumeDriver:
  896. type: "string"
  897. description: "Driver that this container uses to mount volumes."
  898. VolumesFrom:
  899. type: "array"
  900. description: |
  901. A list of volumes to inherit from another container, specified in
  902. the form `<container name>[:<ro|rw>]`.
  903. items:
  904. type: "string"
  905. Mounts:
  906. description: |
  907. Specification for mounts to be added to the container.
  908. type: "array"
  909. items:
  910. $ref: "#/definitions/Mount"
  911. # Applicable to UNIX platforms
  912. CapAdd:
  913. type: "array"
  914. description: |
  915. A list of kernel capabilities to add to the container. Conflicts
  916. with option 'Capabilities'.
  917. items:
  918. type: "string"
  919. CapDrop:
  920. type: "array"
  921. description: |
  922. A list of kernel capabilities to drop from the container. Conflicts
  923. with option 'Capabilities'.
  924. items:
  925. type: "string"
  926. CgroupnsMode:
  927. type: "string"
  928. enum:
  929. - "private"
  930. - "host"
  931. description: |
  932. cgroup namespace mode for the container. Possible values are:
  933. - `"private"`: the container runs in its own private cgroup namespace
  934. - `"host"`: use the host system's cgroup namespace
  935. If not specified, the daemon default is used, which can either be `"private"`
  936. or `"host"`, depending on daemon version, kernel support and configuration.
  937. Dns:
  938. type: "array"
  939. description: "A list of DNS servers for the container to use."
  940. items:
  941. type: "string"
  942. DnsOptions:
  943. type: "array"
  944. description: "A list of DNS options."
  945. items:
  946. type: "string"
  947. DnsSearch:
  948. type: "array"
  949. description: "A list of DNS search domains."
  950. items:
  951. type: "string"
  952. ExtraHosts:
  953. type: "array"
  954. description: |
  955. A list of hostnames/IP mappings to add to the container's `/etc/hosts`
  956. file. Specified in the form `["hostname:IP"]`.
  957. items:
  958. type: "string"
  959. GroupAdd:
  960. type: "array"
  961. description: |
  962. A list of additional groups that the container process will run as.
  963. items:
  964. type: "string"
  965. IpcMode:
  966. type: "string"
  967. description: |
  968. IPC sharing mode for the container. Possible values are:
  969. - `"none"`: own private IPC namespace, with /dev/shm not mounted
  970. - `"private"`: own private IPC namespace
  971. - `"shareable"`: own private IPC namespace, with a possibility to share it with other containers
  972. - `"container:<name|id>"`: join another (shareable) container's IPC namespace
  973. - `"host"`: use the host system's IPC namespace
  974. If not specified, daemon default is used, which can either be `"private"`
  975. or `"shareable"`, depending on daemon version and configuration.
  976. Cgroup:
  977. type: "string"
  978. description: "Cgroup to use for the container."
  979. Links:
  980. type: "array"
  981. description: |
  982. A list of links for the container in the form `container_name:alias`.
  983. items:
  984. type: "string"
  985. OomScoreAdj:
  986. type: "integer"
  987. description: |
  988. An integer value containing the score given to the container in
  989. order to tune OOM killer preferences.
  990. example: 500
  991. PidMode:
  992. type: "string"
  993. description: |
  994. Set the PID (Process) Namespace mode for the container. It can be
  995. either:
  996. - `"container:<name|id>"`: joins another container's PID namespace
  997. - `"host"`: use the host's PID namespace inside the container
  998. Privileged:
  999. type: "boolean"
  1000. description: "Gives the container full access to the host."
  1001. PublishAllPorts:
  1002. type: "boolean"
  1003. description: |
  1004. Allocates an ephemeral host port for all of a container's
  1005. exposed ports.
  1006. Ports are de-allocated when the container stops and allocated when
  1007. the container starts. The allocated port might be changed when
  1008. restarting the container.
  1009. The port is selected from the ephemeral port range that depends on
  1010. the kernel. For example, on Linux the range is defined by
  1011. `/proc/sys/net/ipv4/ip_local_port_range`.
  1012. ReadonlyRootfs:
  1013. type: "boolean"
  1014. description: "Mount the container's root filesystem as read only."
  1015. SecurityOpt:
  1016. type: "array"
  1017. description: |
  1018. A list of string values to customize labels for MLS systems, such
  1019. as SELinux.
  1020. items:
  1021. type: "string"
  1022. StorageOpt:
  1023. type: "object"
  1024. description: |
  1025. Storage driver options for this container, in the form `{"size": "120G"}`.
  1026. additionalProperties:
  1027. type: "string"
  1028. Tmpfs:
  1029. type: "object"
  1030. description: |
  1031. A map of container directories which should be replaced by tmpfs
  1032. mounts, and their corresponding mount options. For example:
  1033. ```
  1034. { "/run": "rw,noexec,nosuid,size=65536k" }
  1035. ```
  1036. additionalProperties:
  1037. type: "string"
  1038. UTSMode:
  1039. type: "string"
  1040. description: "UTS namespace to use for the container."
  1041. UsernsMode:
  1042. type: "string"
  1043. description: |
  1044. Sets the usernamespace mode for the container when usernamespace
  1045. remapping option is enabled.
  1046. ShmSize:
  1047. type: "integer"
  1048. format: "int64"
  1049. description: |
  1050. Size of `/dev/shm` in bytes. If omitted, the system uses 64MB.
  1051. minimum: 0
  1052. Sysctls:
  1053. type: "object"
  1054. description: |
  1055. A list of kernel parameters (sysctls) to set in the container.
  1056. For example:
  1057. ```
  1058. {"net.ipv4.ip_forward": "1"}
  1059. ```
  1060. additionalProperties:
  1061. type: "string"
  1062. Runtime:
  1063. type: "string"
  1064. description: "Runtime to use with this container."
  1065. # Applicable to Windows
  1066. ConsoleSize:
  1067. type: "array"
  1068. description: |
  1069. Initial console size, as an `[height, width]` array. (Windows only)
  1070. minItems: 2
  1071. maxItems: 2
  1072. items:
  1073. type: "integer"
  1074. minimum: 0
  1075. Isolation:
  1076. type: "string"
  1077. description: |
  1078. Isolation technology of the container. (Windows only)
  1079. enum:
  1080. - "default"
  1081. - "process"
  1082. - "hyperv"
  1083. MaskedPaths:
  1084. type: "array"
  1085. description: |
  1086. The list of paths to be masked inside the container (this overrides
  1087. the default set of paths).
  1088. items:
  1089. type: "string"
  1090. ReadonlyPaths:
  1091. type: "array"
  1092. description: |
  1093. The list of paths to be set as read-only inside the container
  1094. (this overrides the default set of paths).
  1095. items:
  1096. type: "string"
  1097. ContainerConfig:
  1098. description: |
  1099. Configuration for a container that is portable between hosts.
  1100. When used as `ContainerConfig` field in an image, `ContainerConfig` is an
  1101. optional field containing the configuration of the container that was last
  1102. committed when creating the image.
  1103. Previous versions of Docker builder used this field to store build cache,
  1104. and it is not in active use anymore.
  1105. type: "object"
  1106. properties:
  1107. Hostname:
  1108. description: |
  1109. The hostname to use for the container, as a valid RFC 1123 hostname.
  1110. type: "string"
  1111. example: "439f4e91bd1d"
  1112. Domainname:
  1113. description: |
  1114. The domain name to use for the container.
  1115. type: "string"
  1116. User:
  1117. description: "The user that commands are run as inside the container."
  1118. type: "string"
  1119. AttachStdin:
  1120. description: "Whether to attach to `stdin`."
  1121. type: "boolean"
  1122. default: false
  1123. AttachStdout:
  1124. description: "Whether to attach to `stdout`."
  1125. type: "boolean"
  1126. default: true
  1127. AttachStderr:
  1128. description: "Whether to attach to `stderr`."
  1129. type: "boolean"
  1130. default: true
  1131. ExposedPorts:
  1132. description: |
  1133. An object mapping ports to an empty object in the form:
  1134. `{"<port>/<tcp|udp|sctp>": {}}`
  1135. type: "object"
  1136. x-nullable: true
  1137. additionalProperties:
  1138. type: "object"
  1139. enum:
  1140. - {}
  1141. default: {}
  1142. example: {
  1143. "80/tcp": {},
  1144. "443/tcp": {}
  1145. }
  1146. Tty:
  1147. description: |
  1148. Attach standard streams to a TTY, including `stdin` if it is not closed.
  1149. type: "boolean"
  1150. default: false
  1151. OpenStdin:
  1152. description: "Open `stdin`"
  1153. type: "boolean"
  1154. default: false
  1155. StdinOnce:
  1156. description: "Close `stdin` after one attached client disconnects"
  1157. type: "boolean"
  1158. default: false
  1159. Env:
  1160. description: |
  1161. A list of environment variables to set inside the container in the
  1162. form `["VAR=value", ...]`. A variable without `=` is removed from the
  1163. environment, rather than to have an empty value.
  1164. type: "array"
  1165. items:
  1166. type: "string"
  1167. example:
  1168. - "PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
  1169. Cmd:
  1170. description: |
  1171. Command to run specified as a string or an array of strings.
  1172. type: "array"
  1173. items:
  1174. type: "string"
  1175. example: ["/bin/sh"]
  1176. Healthcheck:
  1177. $ref: "#/definitions/HealthConfig"
  1178. ArgsEscaped:
  1179. description: "Command is already escaped (Windows only)"
  1180. type: "boolean"
  1181. default: false
  1182. example: false
  1183. x-nullable: true
  1184. Image:
  1185. description: |
  1186. The name (or reference) of the image to use when creating the container,
  1187. or which was used when the container was created.
  1188. type: "string"
  1189. example: "example-image:1.0"
  1190. Volumes:
  1191. description: |
  1192. An object mapping mount point paths inside the container to empty
  1193. objects.
  1194. type: "object"
  1195. additionalProperties:
  1196. type: "object"
  1197. enum:
  1198. - {}
  1199. default: {}
  1200. WorkingDir:
  1201. description: "The working directory for commands to run in."
  1202. type: "string"
  1203. example: "/public/"
  1204. Entrypoint:
  1205. description: |
  1206. The entry point for the container as a string or an array of strings.
  1207. If the array consists of exactly one empty string (`[""]`) then the
  1208. entry point is reset to system default (i.e., the entry point used by
  1209. docker when there is no `ENTRYPOINT` instruction in the `Dockerfile`).
  1210. type: "array"
  1211. items:
  1212. type: "string"
  1213. example: []
  1214. NetworkDisabled:
  1215. description: "Disable networking for the container."
  1216. type: "boolean"
  1217. x-nullable: true
  1218. MacAddress:
  1219. description: "MAC address of the container."
  1220. type: "string"
  1221. x-nullable: true
  1222. OnBuild:
  1223. description: |
  1224. `ONBUILD` metadata that were defined in the image's `Dockerfile`.
  1225. type: "array"
  1226. x-nullable: true
  1227. items:
  1228. type: "string"
  1229. example: []
  1230. Labels:
  1231. description: "User-defined key/value metadata."
  1232. type: "object"
  1233. additionalProperties:
  1234. type: "string"
  1235. example:
  1236. com.example.some-label: "some-value"
  1237. com.example.some-other-label: "some-other-value"
  1238. StopSignal:
  1239. description: |
  1240. Signal to stop a container as a string or unsigned integer.
  1241. type: "string"
  1242. example: "SIGTERM"
  1243. x-nullable: true
  1244. StopTimeout:
  1245. description: "Timeout to stop a container in seconds."
  1246. type: "integer"
  1247. default: 10
  1248. x-nullable: true
  1249. Shell:
  1250. description: |
  1251. Shell for when `RUN`, `CMD`, and `ENTRYPOINT` uses a shell.
  1252. type: "array"
  1253. x-nullable: true
  1254. items:
  1255. type: "string"
  1256. example: ["/bin/sh", "-c"]
  1257. NetworkingConfig:
  1258. description: |
  1259. NetworkingConfig represents the container's networking configuration for
  1260. each of its interfaces.
  1261. It is used for the networking configs specified in the `docker create`
  1262. and `docker network connect` commands.
  1263. type: "object"
  1264. properties:
  1265. EndpointsConfig:
  1266. description: |
  1267. A mapping of network name to endpoint configuration for that network.
  1268. type: "object"
  1269. additionalProperties:
  1270. $ref: "#/definitions/EndpointSettings"
  1271. example:
  1272. # putting an example here, instead of using the example values from
  1273. # /definitions/EndpointSettings, because containers/create currently
  1274. # does not support attaching to multiple networks, so the example request
  1275. # would be confusing if it showed that multiple networks can be contained
  1276. # in the EndpointsConfig.
  1277. # TODO remove once we support multiple networks on container create (see https://github.com/moby/moby/blob/07e6b843594e061f82baa5fa23c2ff7d536c2a05/daemon/create.go#L323)
  1278. EndpointsConfig:
  1279. isolated_nw:
  1280. IPAMConfig:
  1281. IPv4Address: "172.20.30.33"
  1282. IPv6Address: "2001:db8:abcd::3033"
  1283. LinkLocalIPs:
  1284. - "169.254.34.68"
  1285. - "fe80::3468"
  1286. Links:
  1287. - "container_1"
  1288. - "container_2"
  1289. Aliases:
  1290. - "server_x"
  1291. - "server_y"
  1292. NetworkSettings:
  1293. description: "NetworkSettings exposes the network settings in the API"
  1294. type: "object"
  1295. properties:
  1296. Bridge:
  1297. description: Name of the network's bridge (for example, `docker0`).
  1298. type: "string"
  1299. example: "docker0"
  1300. SandboxID:
  1301. description: SandboxID uniquely represents a container's network stack.
  1302. type: "string"
  1303. example: "9d12daf2c33f5959c8bf90aa513e4f65b561738661003029ec84830cd503a0c3"
  1304. HairpinMode:
  1305. description: |
  1306. Indicates if hairpin NAT should be enabled on the virtual interface.
  1307. type: "boolean"
  1308. example: false
  1309. LinkLocalIPv6Address:
  1310. description: IPv6 unicast address using the link-local prefix.
  1311. type: "string"
  1312. example: "fe80::42:acff:fe11:1"
  1313. LinkLocalIPv6PrefixLen:
  1314. description: Prefix length of the IPv6 unicast address.
  1315. type: "integer"
  1316. example: "64"
  1317. Ports:
  1318. $ref: "#/definitions/PortMap"
  1319. SandboxKey:
  1320. description: SandboxKey identifies the sandbox
  1321. type: "string"
  1322. example: "/var/run/docker/netns/8ab54b426c38"
  1323. # TODO is SecondaryIPAddresses actually used?
  1324. SecondaryIPAddresses:
  1325. description: ""
  1326. type: "array"
  1327. items:
  1328. $ref: "#/definitions/Address"
  1329. x-nullable: true
  1330. # TODO is SecondaryIPv6Addresses actually used?
  1331. SecondaryIPv6Addresses:
  1332. description: ""
  1333. type: "array"
  1334. items:
  1335. $ref: "#/definitions/Address"
  1336. x-nullable: true
  1337. # TODO properties below are part of DefaultNetworkSettings, which is
  1338. # marked as deprecated since Docker 1.9 and to be removed in Docker v17.12
  1339. EndpointID:
  1340. description: |
  1341. EndpointID uniquely represents a service endpoint in a Sandbox.
  1342. <p><br /></p>
  1343. > **Deprecated**: This field is only propagated when attached to the
  1344. > default "bridge" network. Use the information from the "bridge"
  1345. > network inside the `Networks` map instead, which contains the same
  1346. > information. This field was deprecated in Docker 1.9 and is scheduled
  1347. > to be removed in Docker 17.12.0
  1348. type: "string"
  1349. example: "b88f5b905aabf2893f3cbc4ee42d1ea7980bbc0a92e2c8922b1e1795298afb0b"
  1350. Gateway:
  1351. description: |
  1352. Gateway address for the default "bridge" network.
  1353. <p><br /></p>
  1354. > **Deprecated**: This field is only propagated when attached to the
  1355. > default "bridge" network. Use the information from the "bridge"
  1356. > network inside the `Networks` map instead, which contains the same
  1357. > information. This field was deprecated in Docker 1.9 and is scheduled
  1358. > to be removed in Docker 17.12.0
  1359. type: "string"
  1360. example: "172.17.0.1"
  1361. GlobalIPv6Address:
  1362. description: |
  1363. Global IPv6 address for the default "bridge" network.
  1364. <p><br /></p>
  1365. > **Deprecated**: This field is only propagated when attached to the
  1366. > default "bridge" network. Use the information from the "bridge"
  1367. > network inside the `Networks` map instead, which contains the same
  1368. > information. This field was deprecated in Docker 1.9 and is scheduled
  1369. > to be removed in Docker 17.12.0
  1370. type: "string"
  1371. example: "2001:db8::5689"
  1372. GlobalIPv6PrefixLen:
  1373. description: |
  1374. Mask length of the global IPv6 address.
  1375. <p><br /></p>
  1376. > **Deprecated**: This field is only propagated when attached to the
  1377. > default "bridge" network. Use the information from the "bridge"
  1378. > network inside the `Networks` map instead, which contains the same
  1379. > information. This field was deprecated in Docker 1.9 and is scheduled
  1380. > to be removed in Docker 17.12.0
  1381. type: "integer"
  1382. example: 64
  1383. IPAddress:
  1384. description: |
  1385. IPv4 address for the default "bridge" network.
  1386. <p><br /></p>
  1387. > **Deprecated**: This field is only propagated when attached to the
  1388. > default "bridge" network. Use the information from the "bridge"
  1389. > network inside the `Networks` map instead, which contains the same
  1390. > information. This field was deprecated in Docker 1.9 and is scheduled
  1391. > to be removed in Docker 17.12.0
  1392. type: "string"
  1393. example: "172.17.0.4"
  1394. IPPrefixLen:
  1395. description: |
  1396. Mask length of the IPv4 address.
  1397. <p><br /></p>
  1398. > **Deprecated**: This field is only propagated when attached to the
  1399. > default "bridge" network. Use the information from the "bridge"
  1400. > network inside the `Networks` map instead, which contains the same
  1401. > information. This field was deprecated in Docker 1.9 and is scheduled
  1402. > to be removed in Docker 17.12.0
  1403. type: "integer"
  1404. example: 16
  1405. IPv6Gateway:
  1406. description: |
  1407. IPv6 gateway address for this network.
  1408. <p><br /></p>
  1409. > **Deprecated**: This field is only propagated when attached to the
  1410. > default "bridge" network. Use the information from the "bridge"
  1411. > network inside the `Networks` map instead, which contains the same
  1412. > information. This field was deprecated in Docker 1.9 and is scheduled
  1413. > to be removed in Docker 17.12.0
  1414. type: "string"
  1415. example: "2001:db8:2::100"
  1416. MacAddress:
  1417. description: |
  1418. MAC address for the container on the default "bridge" network.
  1419. <p><br /></p>
  1420. > **Deprecated**: This field is only propagated when attached to the
  1421. > default "bridge" network. Use the information from the "bridge"
  1422. > network inside the `Networks` map instead, which contains the same
  1423. > information. This field was deprecated in Docker 1.9 and is scheduled
  1424. > to be removed in Docker 17.12.0
  1425. type: "string"
  1426. example: "02:42:ac:11:00:04"
  1427. Networks:
  1428. description: |
  1429. Information about all networks that the container is connected to.
  1430. type: "object"
  1431. additionalProperties:
  1432. $ref: "#/definitions/EndpointSettings"
  1433. Address:
  1434. description: Address represents an IPv4 or IPv6 IP address.
  1435. type: "object"
  1436. properties:
  1437. Addr:
  1438. description: IP address.
  1439. type: "string"
  1440. PrefixLen:
  1441. description: Mask length of the IP address.
  1442. type: "integer"
  1443. PortMap:
  1444. description: |
  1445. PortMap describes the mapping of container ports to host ports, using the
  1446. container's port-number and protocol as key in the format `<port>/<protocol>`,
  1447. for example, `80/udp`.
  1448. If a container's port is mapped for multiple protocols, separate entries
  1449. are added to the mapping table.
  1450. type: "object"
  1451. additionalProperties:
  1452. type: "array"
  1453. x-nullable: true
  1454. items:
  1455. $ref: "#/definitions/PortBinding"
  1456. example:
  1457. "443/tcp":
  1458. - HostIp: "127.0.0.1"
  1459. HostPort: "4443"
  1460. "80/tcp":
  1461. - HostIp: "0.0.0.0"
  1462. HostPort: "80"
  1463. - HostIp: "0.0.0.0"
  1464. HostPort: "8080"
  1465. "80/udp":
  1466. - HostIp: "0.0.0.0"
  1467. HostPort: "80"
  1468. "53/udp":
  1469. - HostIp: "0.0.0.0"
  1470. HostPort: "53"
  1471. "2377/tcp": null
  1472. PortBinding:
  1473. description: |
  1474. PortBinding represents a binding between a host IP address and a host
  1475. port.
  1476. type: "object"
  1477. properties:
  1478. HostIp:
  1479. description: "Host IP address that the container's port is mapped to."
  1480. type: "string"
  1481. example: "127.0.0.1"
  1482. HostPort:
  1483. description: "Host port number that the container's port is mapped to."
  1484. type: "string"
  1485. example: "4443"
  1486. GraphDriverData:
  1487. description: |
  1488. Information about the storage driver used to store the container's and
  1489. image's filesystem.
  1490. type: "object"
  1491. required: [Name, Data]
  1492. properties:
  1493. Name:
  1494. description: "Name of the storage driver."
  1495. type: "string"
  1496. x-nullable: false
  1497. example: "overlay2"
  1498. Data:
  1499. description: |
  1500. Low-level storage metadata, provided as key/value pairs.
  1501. This information is driver-specific, and depends on the storage-driver
  1502. in use, and should be used for informational purposes only.
  1503. type: "object"
  1504. x-nullable: false
  1505. additionalProperties:
  1506. type: "string"
  1507. example: {
  1508. "MergedDir": "/var/lib/docker/overlay2/ef749362d13333e65fc95c572eb525abbe0052e16e086cb64bc3b98ae9aa6d74/merged",
  1509. "UpperDir": "/var/lib/docker/overlay2/ef749362d13333e65fc95c572eb525abbe0052e16e086cb64bc3b98ae9aa6d74/diff",
  1510. "WorkDir": "/var/lib/docker/overlay2/ef749362d13333e65fc95c572eb525abbe0052e16e086cb64bc3b98ae9aa6d74/work"
  1511. }
  1512. ImageInspect:
  1513. description: |
  1514. Information about an image in the local image cache.
  1515. type: "object"
  1516. properties:
  1517. Id:
  1518. description: |
  1519. ID is the content-addressable ID of an image.
  1520. This identifier is a content-addressable digest calculated from the
  1521. image's configuration (which includes the digests of layers used by
  1522. the image).
  1523. Note that this digest differs from the `RepoDigests` below, which
  1524. holds digests of image manifests that reference the image.
  1525. type: "string"
  1526. x-nullable: false
  1527. example: "sha256:ec3f0931a6e6b6855d76b2d7b0be30e81860baccd891b2e243280bf1cd8ad710"
  1528. RepoTags:
  1529. description: |
  1530. List of image names/tags in the local image cache that reference this
  1531. image.
  1532. Multiple image tags can refer to the same image, and this list may be
  1533. empty if no tags reference the image, in which case the image is
  1534. "untagged", in which case it can still be referenced by its ID.
  1535. type: "array"
  1536. items:
  1537. type: "string"
  1538. example:
  1539. - "example:1.0"
  1540. - "example:latest"
  1541. - "example:stable"
  1542. - "internal.registry.example.com:5000/example:1.0"
  1543. RepoDigests:
  1544. description: |
  1545. List of content-addressable digests of locally available image manifests
  1546. that the image is referenced from. Multiple manifests can refer to the
  1547. same image.
  1548. These digests are usually only available if the image was either pulled
  1549. from a registry, or if the image was pushed to a registry, which is when
  1550. the manifest is generated and its digest calculated.
  1551. type: "array"
  1552. items:
  1553. type: "string"
  1554. example:
  1555. - "example@sha256:afcc7f1ac1b49db317a7196c902e61c6c3c4607d63599ee1a82d702d249a0ccb"
  1556. - "internal.registry.example.com:5000/example@sha256:b69959407d21e8a062e0416bf13405bb2b71ed7a84dde4158ebafacfa06f5578"
  1557. Parent:
  1558. description: |
  1559. ID of the parent image.
  1560. Depending on how the image was created, this field may be empty and
  1561. is only set for images that were built/created locally. This field
  1562. is empty if the image was pulled from an image registry.
  1563. type: "string"
  1564. x-nullable: false
  1565. example: ""
  1566. Comment:
  1567. description: |
  1568. Optional message that was set when committing or importing the image.
  1569. type: "string"
  1570. x-nullable: false
  1571. example: ""
  1572. Created:
  1573. description: |
  1574. Date and time at which the image was created, formatted in
  1575. [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format with nano-seconds.
  1576. type: "string"
  1577. x-nullable: false
  1578. example: "2022-02-04T21:20:12.497794809Z"
  1579. Container:
  1580. description: |
  1581. The ID of the container that was used to create the image.
  1582. Depending on how the image was created, this field may be empty.
  1583. type: "string"
  1584. x-nullable: false
  1585. example: "65974bc86f1770ae4bff79f651ebdbce166ae9aada632ee3fa9af3a264911735"
  1586. ContainerConfig:
  1587. $ref: "#/definitions/ContainerConfig"
  1588. DockerVersion:
  1589. description: |
  1590. The version of Docker that was used to build the image.
  1591. Depending on how the image was created, this field may be empty.
  1592. type: "string"
  1593. x-nullable: false
  1594. example: "20.10.7"
  1595. Author:
  1596. description: |
  1597. Name of the author that was specified when committing the image, or as
  1598. specified through MAINTAINER (deprecated) in the Dockerfile.
  1599. type: "string"
  1600. x-nullable: false
  1601. example: ""
  1602. Config:
  1603. $ref: "#/definitions/ContainerConfig"
  1604. Architecture:
  1605. description: |
  1606. Hardware CPU architecture that the image runs on.
  1607. type: "string"
  1608. x-nullable: false
  1609. example: "arm"
  1610. Variant:
  1611. description: |
  1612. CPU architecture variant (presently ARM-only).
  1613. type: "string"
  1614. x-nullable: true
  1615. example: "v7"
  1616. Os:
  1617. description: |
  1618. Operating System the image is built to run on.
  1619. type: "string"
  1620. x-nullable: false
  1621. example: "linux"
  1622. OsVersion:
  1623. description: |
  1624. Operating System version the image is built to run on (especially
  1625. for Windows).
  1626. type: "string"
  1627. example: ""
  1628. x-nullable: true
  1629. Size:
  1630. description: |
  1631. Total size of the image including all layers it is composed of.
  1632. type: "integer"
  1633. format: "int64"
  1634. x-nullable: false
  1635. example: 1239828
  1636. VirtualSize:
  1637. description: |
  1638. Total size of the image including all layers it is composed of.
  1639. In versions of Docker before v1.10, this field was calculated from
  1640. the image itself and all of its parent images. Docker v1.10 and up
  1641. store images self-contained, and no longer use a parent-chain, making
  1642. this field an equivalent of the Size field.
  1643. This field is kept for backward compatibility, but may be removed in
  1644. a future version of the API.
  1645. type: "integer"
  1646. format: "int64"
  1647. x-nullable: false
  1648. example: 1239828
  1649. GraphDriver:
  1650. $ref: "#/definitions/GraphDriverData"
  1651. RootFS:
  1652. description: |
  1653. Information about the image's RootFS, including the layer IDs.
  1654. type: "object"
  1655. required: [Type]
  1656. properties:
  1657. Type:
  1658. type: "string"
  1659. x-nullable: false
  1660. example: "layers"
  1661. Layers:
  1662. type: "array"
  1663. items:
  1664. type: "string"
  1665. example:
  1666. - "sha256:1834950e52ce4d5a88a1bbd131c537f4d0e56d10ff0dd69e66be3b7dfa9df7e6"
  1667. - "sha256:5f70bf18a086007016e948b04aed3b82103a36bea41755b6cddfaf10ace3c6ef"
  1668. Metadata:
  1669. description: |
  1670. Additional metadata of the image in the local cache. This information
  1671. is local to the daemon, and not part of the image itself.
  1672. type: "object"
  1673. properties:
  1674. LastTagTime:
  1675. description: |
  1676. Date and time at which the image was last tagged in
  1677. [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format with nano-seconds.
  1678. This information is only available if the image was tagged locally,
  1679. and omitted otherwise.
  1680. type: "string"
  1681. format: "dateTime"
  1682. example: "2022-02-28T14:40:02.623929178Z"
  1683. x-nullable: true
  1684. ImageSummary:
  1685. type: "object"
  1686. required:
  1687. - Id
  1688. - ParentId
  1689. - RepoTags
  1690. - RepoDigests
  1691. - Created
  1692. - Size
  1693. - SharedSize
  1694. - VirtualSize
  1695. - Labels
  1696. - Containers
  1697. properties:
  1698. Id:
  1699. description: |
  1700. ID is the content-addressable ID of an image.
  1701. This identifier is a content-addressable digest calculated from the
  1702. image's configuration (which includes the digests of layers used by
  1703. the image).
  1704. Note that this digest differs from the `RepoDigests` below, which
  1705. holds digests of image manifests that reference the image.
  1706. type: "string"
  1707. x-nullable: false
  1708. example: "sha256:ec3f0931a6e6b6855d76b2d7b0be30e81860baccd891b2e243280bf1cd8ad710"
  1709. ParentId:
  1710. description: |
  1711. ID of the parent image.
  1712. Depending on how the image was created, this field may be empty and
  1713. is only set for images that were built/created locally. This field
  1714. is empty if the image was pulled from an image registry.
  1715. type: "string"
  1716. x-nullable: false
  1717. example: ""
  1718. RepoTags:
  1719. description: |
  1720. List of image names/tags in the local image cache that reference this
  1721. image.
  1722. Multiple image tags can refer to the same image, and this list may be
  1723. empty if no tags reference the image, in which case the image is
  1724. "untagged", in which case it can still be referenced by its ID.
  1725. type: "array"
  1726. x-nullable: false
  1727. items:
  1728. type: "string"
  1729. example:
  1730. - "example:1.0"
  1731. - "example:latest"
  1732. - "example:stable"
  1733. - "internal.registry.example.com:5000/example:1.0"
  1734. RepoDigests:
  1735. description: |
  1736. List of content-addressable digests of locally available image manifests
  1737. that the image is referenced from. Multiple manifests can refer to the
  1738. same image.
  1739. These digests are usually only available if the image was either pulled
  1740. from a registry, or if the image was pushed to a registry, which is when
  1741. the manifest is generated and its digest calculated.
  1742. type: "array"
  1743. x-nullable: false
  1744. items:
  1745. type: "string"
  1746. example:
  1747. - "example@sha256:afcc7f1ac1b49db317a7196c902e61c6c3c4607d63599ee1a82d702d249a0ccb"
  1748. - "internal.registry.example.com:5000/example@sha256:b69959407d21e8a062e0416bf13405bb2b71ed7a84dde4158ebafacfa06f5578"
  1749. Created:
  1750. description: |
  1751. Date and time at which the image was created as a Unix timestamp
  1752. (number of seconds sinds EPOCH).
  1753. type: "integer"
  1754. x-nullable: false
  1755. example: "1644009612"
  1756. Size:
  1757. description: |
  1758. Total size of the image including all layers it is composed of.
  1759. type: "integer"
  1760. format: "int64"
  1761. x-nullable: false
  1762. example: 172064416
  1763. SharedSize:
  1764. description: |
  1765. Total size of image layers that are shared between this image and other
  1766. images.
  1767. This size is not calculated by default. `-1` indicates that the value
  1768. has not been set / calculated.
  1769. type: "integer"
  1770. format: "int64"
  1771. x-nullable: false
  1772. example: 1239828
  1773. VirtualSize:
  1774. description: |
  1775. Total size of the image including all layers it is composed of.
  1776. In versions of Docker before v1.10, this field was calculated from
  1777. the image itself and all of its parent images. Docker v1.10 and up
  1778. store images self-contained, and no longer use a parent-chain, making
  1779. this field an equivalent of the Size field.
  1780. This field is kept for backward compatibility, but may be removed in
  1781. a future version of the API.
  1782. type: "integer"
  1783. format: "int64"
  1784. x-nullable: false
  1785. example: 172064416
  1786. Labels:
  1787. description: "User-defined key/value metadata."
  1788. type: "object"
  1789. x-nullable: false
  1790. additionalProperties:
  1791. type: "string"
  1792. example:
  1793. com.example.some-label: "some-value"
  1794. com.example.some-other-label: "some-other-value"
  1795. Containers:
  1796. description: |
  1797. Number of containers using this image. Includes both stopped and running
  1798. containers.
  1799. This size is not calculated by default, and depends on which API endpoint
  1800. is used. `-1` indicates that the value has not been set / calculated.
  1801. x-nullable: false
  1802. type: "integer"
  1803. example: 2
  1804. AuthConfig:
  1805. type: "object"
  1806. properties:
  1807. username:
  1808. type: "string"
  1809. password:
  1810. type: "string"
  1811. email:
  1812. type: "string"
  1813. serveraddress:
  1814. type: "string"
  1815. example:
  1816. username: "hannibal"
  1817. password: "xxxx"
  1818. serveraddress: "https://index.docker.io/v1/"
  1819. ProcessConfig:
  1820. type: "object"
  1821. properties:
  1822. privileged:
  1823. type: "boolean"
  1824. user:
  1825. type: "string"
  1826. tty:
  1827. type: "boolean"
  1828. entrypoint:
  1829. type: "string"
  1830. arguments:
  1831. type: "array"
  1832. items:
  1833. type: "string"
  1834. Volume:
  1835. type: "object"
  1836. required: [Name, Driver, Mountpoint, Labels, Scope, Options]
  1837. properties:
  1838. Name:
  1839. type: "string"
  1840. description: "Name of the volume."
  1841. x-nullable: false
  1842. example: "tardis"
  1843. Driver:
  1844. type: "string"
  1845. description: "Name of the volume driver used by the volume."
  1846. x-nullable: false
  1847. example: "custom"
  1848. Mountpoint:
  1849. type: "string"
  1850. description: "Mount path of the volume on the host."
  1851. x-nullable: false
  1852. example: "/var/lib/docker/volumes/tardis"
  1853. CreatedAt:
  1854. type: "string"
  1855. format: "dateTime"
  1856. description: "Date/Time the volume was created."
  1857. example: "2016-06-07T20:31:11.853781916Z"
  1858. Status:
  1859. type: "object"
  1860. description: |
  1861. Low-level details about the volume, provided by the volume driver.
  1862. Details are returned as a map with key/value pairs:
  1863. `{"key":"value","key2":"value2"}`.
  1864. The `Status` field is optional, and is omitted if the volume driver
  1865. does not support this feature.
  1866. additionalProperties:
  1867. type: "object"
  1868. example:
  1869. hello: "world"
  1870. Labels:
  1871. type: "object"
  1872. description: "User-defined key/value metadata."
  1873. x-nullable: false
  1874. additionalProperties:
  1875. type: "string"
  1876. example:
  1877. com.example.some-label: "some-value"
  1878. com.example.some-other-label: "some-other-value"
  1879. Scope:
  1880. type: "string"
  1881. description: |
  1882. The level at which the volume exists. Either `global` for cluster-wide,
  1883. or `local` for machine level.
  1884. default: "local"
  1885. x-nullable: false
  1886. enum: ["local", "global"]
  1887. example: "local"
  1888. Options:
  1889. type: "object"
  1890. description: |
  1891. The driver specific options used when creating the volume.
  1892. additionalProperties:
  1893. type: "string"
  1894. example:
  1895. device: "tmpfs"
  1896. o: "size=100m,uid=1000"
  1897. type: "tmpfs"
  1898. UsageData:
  1899. type: "object"
  1900. x-nullable: true
  1901. required: [Size, RefCount]
  1902. description: |
  1903. Usage details about the volume. This information is used by the
  1904. `GET /system/df` endpoint, and omitted in other endpoints.
  1905. properties:
  1906. Size:
  1907. type: "integer"
  1908. format: "int64"
  1909. default: -1
  1910. description: |
  1911. Amount of disk space used by the volume (in bytes). This information
  1912. is only available for volumes created with the `"local"` volume
  1913. driver. For volumes created with other volume drivers, this field
  1914. is set to `-1` ("not available")
  1915. x-nullable: false
  1916. RefCount:
  1917. type: "integer"
  1918. format: "int64"
  1919. default: -1
  1920. description: |
  1921. The number of containers referencing this volume. This field
  1922. is set to `-1` if the reference-count is not available.
  1923. x-nullable: false
  1924. VolumeCreateOptions:
  1925. description: "Volume configuration"
  1926. type: "object"
  1927. title: "VolumeConfig"
  1928. x-go-name: "VolumeCreateBody"
  1929. properties:
  1930. Name:
  1931. description: |
  1932. The new volume's name. If not specified, Docker generates a name.
  1933. type: "string"
  1934. x-nullable: false
  1935. example: "tardis"
  1936. Driver:
  1937. description: "Name of the volume driver to use."
  1938. type: "string"
  1939. default: "local"
  1940. x-nullable: false
  1941. example: "custom"
  1942. DriverOpts:
  1943. description: |
  1944. A mapping of driver options and values. These options are
  1945. passed directly to the driver and are driver specific.
  1946. type: "object"
  1947. additionalProperties:
  1948. type: "string"
  1949. example:
  1950. device: "tmpfs"
  1951. o: "size=100m,uid=1000"
  1952. type: "tmpfs"
  1953. Labels:
  1954. description: "User-defined key/value metadata."
  1955. type: "object"
  1956. additionalProperties:
  1957. type: "string"
  1958. example:
  1959. com.example.some-label: "some-value"
  1960. com.example.some-other-label: "some-other-value"
  1961. VolumeListResponse:
  1962. type: "object"
  1963. title: "VolumeListResponse"
  1964. x-go-name: "VolumeListOKBody"
  1965. description: "Volume list response"
  1966. properties:
  1967. Volumes:
  1968. type: "array"
  1969. description: "List of volumes"
  1970. items:
  1971. $ref: "#/definitions/Volume"
  1972. Warnings:
  1973. type: "array"
  1974. description: |
  1975. Warnings that occurred when fetching the list of volumes.
  1976. items:
  1977. type: "string"
  1978. example: []
  1979. Network:
  1980. type: "object"
  1981. properties:
  1982. Name:
  1983. type: "string"
  1984. Id:
  1985. type: "string"
  1986. Created:
  1987. type: "string"
  1988. format: "dateTime"
  1989. Scope:
  1990. type: "string"
  1991. Driver:
  1992. type: "string"
  1993. EnableIPv6:
  1994. type: "boolean"
  1995. IPAM:
  1996. $ref: "#/definitions/IPAM"
  1997. Internal:
  1998. type: "boolean"
  1999. Attachable:
  2000. type: "boolean"
  2001. Ingress:
  2002. type: "boolean"
  2003. Containers:
  2004. type: "object"
  2005. additionalProperties:
  2006. $ref: "#/definitions/NetworkContainer"
  2007. Options:
  2008. type: "object"
  2009. additionalProperties:
  2010. type: "string"
  2011. Labels:
  2012. type: "object"
  2013. additionalProperties:
  2014. type: "string"
  2015. example:
  2016. Name: "net01"
  2017. Id: "7d86d31b1478e7cca9ebed7e73aa0fdeec46c5ca29497431d3007d2d9e15ed99"
  2018. Created: "2016-10-19T04:33:30.360899459Z"
  2019. Scope: "local"
  2020. Driver: "bridge"
  2021. EnableIPv6: false
  2022. IPAM:
  2023. Driver: "default"
  2024. Config:
  2025. - Subnet: "172.19.0.0/16"
  2026. Gateway: "172.19.0.1"
  2027. Options:
  2028. foo: "bar"
  2029. Internal: false
  2030. Attachable: false
  2031. Ingress: false
  2032. Containers:
  2033. 19a4d5d687db25203351ed79d478946f861258f018fe384f229f2efa4b23513c:
  2034. Name: "test"
  2035. EndpointID: "628cadb8bcb92de107b2a1e516cbffe463e321f548feb37697cce00ad694f21a"
  2036. MacAddress: "02:42:ac:13:00:02"
  2037. IPv4Address: "172.19.0.2/16"
  2038. IPv6Address: ""
  2039. Options:
  2040. com.docker.network.bridge.default_bridge: "true"
  2041. com.docker.network.bridge.enable_icc: "true"
  2042. com.docker.network.bridge.enable_ip_masquerade: "true"
  2043. com.docker.network.bridge.host_binding_ipv4: "0.0.0.0"
  2044. com.docker.network.bridge.name: "docker0"
  2045. com.docker.network.driver.mtu: "1500"
  2046. Labels:
  2047. com.example.some-label: "some-value"
  2048. com.example.some-other-label: "some-other-value"
  2049. IPAM:
  2050. type: "object"
  2051. properties:
  2052. Driver:
  2053. description: "Name of the IPAM driver to use."
  2054. type: "string"
  2055. default: "default"
  2056. Config:
  2057. description: |
  2058. List of IPAM configuration options, specified as a map:
  2059. ```
  2060. {"Subnet": <CIDR>, "IPRange": <CIDR>, "Gateway": <IP address>, "AuxAddress": <device_name:IP address>}
  2061. ```
  2062. type: "array"
  2063. items:
  2064. $ref: "#/definitions/IPAMConfig"
  2065. Options:
  2066. description: "Driver-specific options, specified as a map."
  2067. type: "object"
  2068. additionalProperties:
  2069. type: "string"
  2070. IPAMConfig:
  2071. type: "object"
  2072. properties:
  2073. Subnet:
  2074. type: "string"
  2075. IPRange:
  2076. type: "string"
  2077. Gateway:
  2078. type: "string"
  2079. AuxiliaryAddresses:
  2080. type: "object"
  2081. additionalProperties:
  2082. type: "string"
  2083. NetworkContainer:
  2084. type: "object"
  2085. properties:
  2086. Name:
  2087. type: "string"
  2088. EndpointID:
  2089. type: "string"
  2090. MacAddress:
  2091. type: "string"
  2092. IPv4Address:
  2093. type: "string"
  2094. IPv6Address:
  2095. type: "string"
  2096. BuildInfo:
  2097. type: "object"
  2098. properties:
  2099. id:
  2100. type: "string"
  2101. stream:
  2102. type: "string"
  2103. error:
  2104. type: "string"
  2105. errorDetail:
  2106. $ref: "#/definitions/ErrorDetail"
  2107. status:
  2108. type: "string"
  2109. progress:
  2110. type: "string"
  2111. progressDetail:
  2112. $ref: "#/definitions/ProgressDetail"
  2113. aux:
  2114. $ref: "#/definitions/ImageID"
  2115. BuildCache:
  2116. type: "object"
  2117. description: |
  2118. BuildCache contains information about a build cache record.
  2119. properties:
  2120. ID:
  2121. type: "string"
  2122. description: |
  2123. Unique ID of the build cache record.
  2124. example: "ndlpt0hhvkqcdfkputsk4cq9c"
  2125. Parent:
  2126. description: |
  2127. ID of the parent build cache record.
  2128. type: "string"
  2129. example: "hw53o5aio51xtltp5xjp8v7fx"
  2130. Type:
  2131. type: "string"
  2132. description: |
  2133. Cache record type.
  2134. example: "regular"
  2135. # see https://github.com/moby/buildkit/blob/fce4a32258dc9d9664f71a4831d5de10f0670677/client/diskusage.go#L75-L84
  2136. enum:
  2137. - "internal"
  2138. - "frontend"
  2139. - "source.local"
  2140. - "source.git.checkout"
  2141. - "exec.cachemount"
  2142. - "regular"
  2143. Description:
  2144. type: "string"
  2145. description: |
  2146. Description of the build-step that produced the build cache.
  2147. example: "mount / from exec /bin/sh -c echo 'Binary::apt::APT::Keep-Downloaded-Packages \"true\";' > /etc/apt/apt.conf.d/keep-cache"
  2148. InUse:
  2149. type: "boolean"
  2150. description: |
  2151. Indicates if the build cache is in use.
  2152. example: false
  2153. Shared:
  2154. type: "boolean"
  2155. description: |
  2156. Indicates if the build cache is shared.
  2157. example: true
  2158. Size:
  2159. description: |
  2160. Amount of disk space used by the build cache (in bytes).
  2161. type: "integer"
  2162. example: 51
  2163. CreatedAt:
  2164. description: |
  2165. Date and time at which the build cache was created in
  2166. [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format with nano-seconds.
  2167. type: "string"
  2168. format: "dateTime"
  2169. example: "2016-08-18T10:44:24.496525531Z"
  2170. LastUsedAt:
  2171. description: |
  2172. Date and time at which the build cache was last used in
  2173. [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format with nano-seconds.
  2174. type: "string"
  2175. format: "dateTime"
  2176. x-nullable: true
  2177. example: "2017-08-09T07:09:37.632105588Z"
  2178. UsageCount:
  2179. type: "integer"
  2180. example: 26
  2181. ImageID:
  2182. type: "object"
  2183. description: "Image ID or Digest"
  2184. properties:
  2185. ID:
  2186. type: "string"
  2187. example:
  2188. ID: "sha256:85f05633ddc1c50679be2b16a0479ab6f7637f8884e0cfe0f4d20e1ebb3d6e7c"
  2189. CreateImageInfo:
  2190. type: "object"
  2191. properties:
  2192. id:
  2193. type: "string"
  2194. error:
  2195. type: "string"
  2196. errorDetail:
  2197. $ref: "#/definitions/ErrorDetail"
  2198. status:
  2199. type: "string"
  2200. progress:
  2201. type: "string"
  2202. progressDetail:
  2203. $ref: "#/definitions/ProgressDetail"
  2204. PushImageInfo:
  2205. type: "object"
  2206. properties:
  2207. error:
  2208. type: "string"
  2209. status:
  2210. type: "string"
  2211. progress:
  2212. type: "string"
  2213. progressDetail:
  2214. $ref: "#/definitions/ProgressDetail"
  2215. ErrorDetail:
  2216. type: "object"
  2217. properties:
  2218. code:
  2219. type: "integer"
  2220. message:
  2221. type: "string"
  2222. ProgressDetail:
  2223. type: "object"
  2224. properties:
  2225. current:
  2226. type: "integer"
  2227. total:
  2228. type: "integer"
  2229. ErrorResponse:
  2230. description: "Represents an error."
  2231. type: "object"
  2232. required: ["message"]
  2233. properties:
  2234. message:
  2235. description: "The error message."
  2236. type: "string"
  2237. x-nullable: false
  2238. example:
  2239. message: "Something went wrong."
  2240. IdResponse:
  2241. description: "Response to an API call that returns just an Id"
  2242. type: "object"
  2243. required: ["Id"]
  2244. properties:
  2245. Id:
  2246. description: "The id of the newly created object."
  2247. type: "string"
  2248. x-nullable: false
  2249. EndpointSettings:
  2250. description: "Configuration for a network endpoint."
  2251. type: "object"
  2252. properties:
  2253. # Configurations
  2254. IPAMConfig:
  2255. $ref: "#/definitions/EndpointIPAMConfig"
  2256. Links:
  2257. type: "array"
  2258. items:
  2259. type: "string"
  2260. example:
  2261. - "container_1"
  2262. - "container_2"
  2263. Aliases:
  2264. type: "array"
  2265. items:
  2266. type: "string"
  2267. example:
  2268. - "server_x"
  2269. - "server_y"
  2270. # Operational data
  2271. NetworkID:
  2272. description: |
  2273. Unique ID of the network.
  2274. type: "string"
  2275. example: "08754567f1f40222263eab4102e1c733ae697e8e354aa9cd6e18d7402835292a"
  2276. EndpointID:
  2277. description: |
  2278. Unique ID for the service endpoint in a Sandbox.
  2279. type: "string"
  2280. example: "b88f5b905aabf2893f3cbc4ee42d1ea7980bbc0a92e2c8922b1e1795298afb0b"
  2281. Gateway:
  2282. description: |
  2283. Gateway address for this network.
  2284. type: "string"
  2285. example: "172.17.0.1"
  2286. IPAddress:
  2287. description: |
  2288. IPv4 address.
  2289. type: "string"
  2290. example: "172.17.0.4"
  2291. IPPrefixLen:
  2292. description: |
  2293. Mask length of the IPv4 address.
  2294. type: "integer"
  2295. example: 16
  2296. IPv6Gateway:
  2297. description: |
  2298. IPv6 gateway address.
  2299. type: "string"
  2300. example: "2001:db8:2::100"
  2301. GlobalIPv6Address:
  2302. description: |
  2303. Global IPv6 address.
  2304. type: "string"
  2305. example: "2001:db8::5689"
  2306. GlobalIPv6PrefixLen:
  2307. description: |
  2308. Mask length of the global IPv6 address.
  2309. type: "integer"
  2310. format: "int64"
  2311. example: 64
  2312. MacAddress:
  2313. description: |
  2314. MAC address for the endpoint on this network.
  2315. type: "string"
  2316. example: "02:42:ac:11:00:04"
  2317. DriverOpts:
  2318. description: |
  2319. DriverOpts is a mapping of driver options and values. These options
  2320. are passed directly to the driver and are driver specific.
  2321. type: "object"
  2322. x-nullable: true
  2323. additionalProperties:
  2324. type: "string"
  2325. example:
  2326. com.example.some-label: "some-value"
  2327. com.example.some-other-label: "some-other-value"
  2328. EndpointIPAMConfig:
  2329. description: |
  2330. EndpointIPAMConfig represents an endpoint's IPAM configuration.
  2331. type: "object"
  2332. x-nullable: true
  2333. properties:
  2334. IPv4Address:
  2335. type: "string"
  2336. example: "172.20.30.33"
  2337. IPv6Address:
  2338. type: "string"
  2339. example: "2001:db8:abcd::3033"
  2340. LinkLocalIPs:
  2341. type: "array"
  2342. items:
  2343. type: "string"
  2344. example:
  2345. - "169.254.34.68"
  2346. - "fe80::3468"
  2347. PluginMount:
  2348. type: "object"
  2349. x-nullable: false
  2350. required: [Name, Description, Settable, Source, Destination, Type, Options]
  2351. properties:
  2352. Name:
  2353. type: "string"
  2354. x-nullable: false
  2355. example: "some-mount"
  2356. Description:
  2357. type: "string"
  2358. x-nullable: false
  2359. example: "This is a mount that's used by the plugin."
  2360. Settable:
  2361. type: "array"
  2362. items:
  2363. type: "string"
  2364. Source:
  2365. type: "string"
  2366. example: "/var/lib/docker/plugins/"
  2367. Destination:
  2368. type: "string"
  2369. x-nullable: false
  2370. example: "/mnt/state"
  2371. Type:
  2372. type: "string"
  2373. x-nullable: false
  2374. example: "bind"
  2375. Options:
  2376. type: "array"
  2377. items:
  2378. type: "string"
  2379. example:
  2380. - "rbind"
  2381. - "rw"
  2382. PluginDevice:
  2383. type: "object"
  2384. required: [Name, Description, Settable, Path]
  2385. x-nullable: false
  2386. properties:
  2387. Name:
  2388. type: "string"
  2389. x-nullable: false
  2390. Description:
  2391. type: "string"
  2392. x-nullable: false
  2393. Settable:
  2394. type: "array"
  2395. items:
  2396. type: "string"
  2397. Path:
  2398. type: "string"
  2399. example: "/dev/fuse"
  2400. PluginEnv:
  2401. type: "object"
  2402. x-nullable: false
  2403. required: [Name, Description, Settable, Value]
  2404. properties:
  2405. Name:
  2406. x-nullable: false
  2407. type: "string"
  2408. Description:
  2409. x-nullable: false
  2410. type: "string"
  2411. Settable:
  2412. type: "array"
  2413. items:
  2414. type: "string"
  2415. Value:
  2416. type: "string"
  2417. PluginInterfaceType:
  2418. type: "object"
  2419. x-nullable: false
  2420. required: [Prefix, Capability, Version]
  2421. properties:
  2422. Prefix:
  2423. type: "string"
  2424. x-nullable: false
  2425. Capability:
  2426. type: "string"
  2427. x-nullable: false
  2428. Version:
  2429. type: "string"
  2430. x-nullable: false
  2431. PluginPrivilege:
  2432. description: |
  2433. Describes a permission the user has to accept upon installing
  2434. the plugin.
  2435. type: "object"
  2436. x-go-name: "PluginPrivilege"
  2437. properties:
  2438. Name:
  2439. type: "string"
  2440. example: "network"
  2441. Description:
  2442. type: "string"
  2443. Value:
  2444. type: "array"
  2445. items:
  2446. type: "string"
  2447. example:
  2448. - "host"
  2449. Plugin:
  2450. description: "A plugin for the Engine API"
  2451. type: "object"
  2452. required: [Settings, Enabled, Config, Name]
  2453. properties:
  2454. Id:
  2455. type: "string"
  2456. example: "5724e2c8652da337ab2eedd19fc6fc0ec908e4bd907c7421bf6a8dfc70c4c078"
  2457. Name:
  2458. type: "string"
  2459. x-nullable: false
  2460. example: "tiborvass/sample-volume-plugin"
  2461. Enabled:
  2462. description:
  2463. True if the plugin is running. False if the plugin is not running,
  2464. only installed.
  2465. type: "boolean"
  2466. x-nullable: false
  2467. example: true
  2468. Settings:
  2469. description: "Settings that can be modified by users."
  2470. type: "object"
  2471. x-nullable: false
  2472. required: [Args, Devices, Env, Mounts]
  2473. properties:
  2474. Mounts:
  2475. type: "array"
  2476. items:
  2477. $ref: "#/definitions/PluginMount"
  2478. Env:
  2479. type: "array"
  2480. items:
  2481. type: "string"
  2482. example:
  2483. - "DEBUG=0"
  2484. Args:
  2485. type: "array"
  2486. items:
  2487. type: "string"
  2488. Devices:
  2489. type: "array"
  2490. items:
  2491. $ref: "#/definitions/PluginDevice"
  2492. PluginReference:
  2493. description: "plugin remote reference used to push/pull the plugin"
  2494. type: "string"
  2495. x-nullable: false
  2496. example: "localhost:5000/tiborvass/sample-volume-plugin:latest"
  2497. Config:
  2498. description: "The config of a plugin."
  2499. type: "object"
  2500. x-nullable: false
  2501. required:
  2502. - Description
  2503. - Documentation
  2504. - Interface
  2505. - Entrypoint
  2506. - WorkDir
  2507. - Network
  2508. - Linux
  2509. - PidHost
  2510. - PropagatedMount
  2511. - IpcHost
  2512. - Mounts
  2513. - Env
  2514. - Args
  2515. properties:
  2516. DockerVersion:
  2517. description: "Docker Version used to create the plugin"
  2518. type: "string"
  2519. x-nullable: false
  2520. example: "17.06.0-ce"
  2521. Description:
  2522. type: "string"
  2523. x-nullable: false
  2524. example: "A sample volume plugin for Docker"
  2525. Documentation:
  2526. type: "string"
  2527. x-nullable: false
  2528. example: "https://docs.docker.com/engine/extend/plugins/"
  2529. Interface:
  2530. description: "The interface between Docker and the plugin"
  2531. x-nullable: false
  2532. type: "object"
  2533. required: [Types, Socket]
  2534. properties:
  2535. Types:
  2536. type: "array"
  2537. items:
  2538. $ref: "#/definitions/PluginInterfaceType"
  2539. example:
  2540. - "docker.volumedriver/1.0"
  2541. Socket:
  2542. type: "string"
  2543. x-nullable: false
  2544. example: "plugins.sock"
  2545. ProtocolScheme:
  2546. type: "string"
  2547. example: "some.protocol/v1.0"
  2548. description: "Protocol to use for clients connecting to the plugin."
  2549. enum:
  2550. - ""
  2551. - "moby.plugins.http/v1"
  2552. Entrypoint:
  2553. type: "array"
  2554. items:
  2555. type: "string"
  2556. example:
  2557. - "/usr/bin/sample-volume-plugin"
  2558. - "/data"
  2559. WorkDir:
  2560. type: "string"
  2561. x-nullable: false
  2562. example: "/bin/"
  2563. User:
  2564. type: "object"
  2565. x-nullable: false
  2566. properties:
  2567. UID:
  2568. type: "integer"
  2569. format: "uint32"
  2570. example: 1000
  2571. GID:
  2572. type: "integer"
  2573. format: "uint32"
  2574. example: 1000
  2575. Network:
  2576. type: "object"
  2577. x-nullable: false
  2578. required: [Type]
  2579. properties:
  2580. Type:
  2581. x-nullable: false
  2582. type: "string"
  2583. example: "host"
  2584. Linux:
  2585. type: "object"
  2586. x-nullable: false
  2587. required: [Capabilities, AllowAllDevices, Devices]
  2588. properties:
  2589. Capabilities:
  2590. type: "array"
  2591. items:
  2592. type: "string"
  2593. example:
  2594. - "CAP_SYS_ADMIN"
  2595. - "CAP_SYSLOG"
  2596. AllowAllDevices:
  2597. type: "boolean"
  2598. x-nullable: false
  2599. example: false
  2600. Devices:
  2601. type: "array"
  2602. items:
  2603. $ref: "#/definitions/PluginDevice"
  2604. PropagatedMount:
  2605. type: "string"
  2606. x-nullable: false
  2607. example: "/mnt/volumes"
  2608. IpcHost:
  2609. type: "boolean"
  2610. x-nullable: false
  2611. example: false
  2612. PidHost:
  2613. type: "boolean"
  2614. x-nullable: false
  2615. example: false
  2616. Mounts:
  2617. type: "array"
  2618. items:
  2619. $ref: "#/definitions/PluginMount"
  2620. Env:
  2621. type: "array"
  2622. items:
  2623. $ref: "#/definitions/PluginEnv"
  2624. example:
  2625. - Name: "DEBUG"
  2626. Description: "If set, prints debug messages"
  2627. Settable: null
  2628. Value: "0"
  2629. Args:
  2630. type: "object"
  2631. x-nullable: false
  2632. required: [Name, Description, Settable, Value]
  2633. properties:
  2634. Name:
  2635. x-nullable: false
  2636. type: "string"
  2637. example: "args"
  2638. Description:
  2639. x-nullable: false
  2640. type: "string"
  2641. example: "command line arguments"
  2642. Settable:
  2643. type: "array"
  2644. items:
  2645. type: "string"
  2646. Value:
  2647. type: "array"
  2648. items:
  2649. type: "string"
  2650. rootfs:
  2651. type: "object"
  2652. properties:
  2653. type:
  2654. type: "string"
  2655. example: "layers"
  2656. diff_ids:
  2657. type: "array"
  2658. items:
  2659. type: "string"
  2660. example:
  2661. - "sha256:675532206fbf3030b8458f88d6e26d4eb1577688a25efec97154c94e8b6b4887"
  2662. - "sha256:e216a057b1cb1efc11f8a268f37ef62083e70b1b38323ba252e25ac88904a7e8"
  2663. ObjectVersion:
  2664. description: |
  2665. The version number of the object such as node, service, etc. This is needed
  2666. to avoid conflicting writes. The client must send the version number along
  2667. with the modified specification when updating these objects.
  2668. This approach ensures safe concurrency and determinism in that the change
  2669. on the object may not be applied if the version number has changed from the
  2670. last read. In other words, if two update requests specify the same base
  2671. version, only one of the requests can succeed. As a result, two separate
  2672. update requests that happen at the same time will not unintentionally
  2673. overwrite each other.
  2674. type: "object"
  2675. properties:
  2676. Index:
  2677. type: "integer"
  2678. format: "uint64"
  2679. example: 373531
  2680. NodeSpec:
  2681. type: "object"
  2682. properties:
  2683. Name:
  2684. description: "Name for the node."
  2685. type: "string"
  2686. example: "my-node"
  2687. Labels:
  2688. description: "User-defined key/value metadata."
  2689. type: "object"
  2690. additionalProperties:
  2691. type: "string"
  2692. Role:
  2693. description: "Role of the node."
  2694. type: "string"
  2695. enum:
  2696. - "worker"
  2697. - "manager"
  2698. example: "manager"
  2699. Availability:
  2700. description: "Availability of the node."
  2701. type: "string"
  2702. enum:
  2703. - "active"
  2704. - "pause"
  2705. - "drain"
  2706. example: "active"
  2707. example:
  2708. Availability: "active"
  2709. Name: "node-name"
  2710. Role: "manager"
  2711. Labels:
  2712. foo: "bar"
  2713. Node:
  2714. type: "object"
  2715. properties:
  2716. ID:
  2717. type: "string"
  2718. example: "24ifsmvkjbyhk"
  2719. Version:
  2720. $ref: "#/definitions/ObjectVersion"
  2721. CreatedAt:
  2722. description: |
  2723. Date and time at which the node was added to the swarm in
  2724. [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format with nano-seconds.
  2725. type: "string"
  2726. format: "dateTime"
  2727. example: "2016-08-18T10:44:24.496525531Z"
  2728. UpdatedAt:
  2729. description: |
  2730. Date and time at which the node was last updated in
  2731. [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format with nano-seconds.
  2732. type: "string"
  2733. format: "dateTime"
  2734. example: "2017-08-09T07:09:37.632105588Z"
  2735. Spec:
  2736. $ref: "#/definitions/NodeSpec"
  2737. Description:
  2738. $ref: "#/definitions/NodeDescription"
  2739. Status:
  2740. $ref: "#/definitions/NodeStatus"
  2741. ManagerStatus:
  2742. $ref: "#/definitions/ManagerStatus"
  2743. NodeDescription:
  2744. description: |
  2745. NodeDescription encapsulates the properties of the Node as reported by the
  2746. agent.
  2747. type: "object"
  2748. properties:
  2749. Hostname:
  2750. type: "string"
  2751. example: "bf3067039e47"
  2752. Platform:
  2753. $ref: "#/definitions/Platform"
  2754. Resources:
  2755. $ref: "#/definitions/ResourceObject"
  2756. Engine:
  2757. $ref: "#/definitions/EngineDescription"
  2758. TLSInfo:
  2759. $ref: "#/definitions/TLSInfo"
  2760. Platform:
  2761. description: |
  2762. Platform represents the platform (Arch/OS).
  2763. type: "object"
  2764. properties:
  2765. Architecture:
  2766. description: |
  2767. Architecture represents the hardware architecture (for example,
  2768. `x86_64`).
  2769. type: "string"
  2770. example: "x86_64"
  2771. OS:
  2772. description: |
  2773. OS represents the Operating System (for example, `linux` or `windows`).
  2774. type: "string"
  2775. example: "linux"
  2776. EngineDescription:
  2777. description: "EngineDescription provides information about an engine."
  2778. type: "object"
  2779. properties:
  2780. EngineVersion:
  2781. type: "string"
  2782. example: "17.06.0"
  2783. Labels:
  2784. type: "object"
  2785. additionalProperties:
  2786. type: "string"
  2787. example:
  2788. foo: "bar"
  2789. Plugins:
  2790. type: "array"
  2791. items:
  2792. type: "object"
  2793. properties:
  2794. Type:
  2795. type: "string"
  2796. Name:
  2797. type: "string"
  2798. example:
  2799. - Type: "Log"
  2800. Name: "awslogs"
  2801. - Type: "Log"
  2802. Name: "fluentd"
  2803. - Type: "Log"
  2804. Name: "gcplogs"
  2805. - Type: "Log"
  2806. Name: "gelf"
  2807. - Type: "Log"
  2808. Name: "journald"
  2809. - Type: "Log"
  2810. Name: "json-file"
  2811. - Type: "Log"
  2812. Name: "splunk"
  2813. - Type: "Log"
  2814. Name: "syslog"
  2815. - Type: "Network"
  2816. Name: "bridge"
  2817. - Type: "Network"
  2818. Name: "host"
  2819. - Type: "Network"
  2820. Name: "ipvlan"
  2821. - Type: "Network"
  2822. Name: "macvlan"
  2823. - Type: "Network"
  2824. Name: "null"
  2825. - Type: "Network"
  2826. Name: "overlay"
  2827. - Type: "Volume"
  2828. Name: "local"
  2829. - Type: "Volume"
  2830. Name: "localhost:5000/vieux/sshfs:latest"
  2831. - Type: "Volume"
  2832. Name: "vieux/sshfs:latest"
  2833. TLSInfo:
  2834. description: |
  2835. Information about the issuer of leaf TLS certificates and the trusted root
  2836. CA certificate.
  2837. type: "object"
  2838. properties:
  2839. TrustRoot:
  2840. description: |
  2841. The root CA certificate(s) that are used to validate leaf TLS
  2842. certificates.
  2843. type: "string"
  2844. CertIssuerSubject:
  2845. description:
  2846. The base64-url-safe-encoded raw subject bytes of the issuer.
  2847. type: "string"
  2848. CertIssuerPublicKey:
  2849. description: |
  2850. The base64-url-safe-encoded raw public key bytes of the issuer.
  2851. type: "string"
  2852. example:
  2853. TrustRoot: |
  2854. -----BEGIN CERTIFICATE-----
  2855. MIIBajCCARCgAwIBAgIUbYqrLSOSQHoxD8CwG6Bi2PJi9c8wCgYIKoZIzj0EAwIw
  2856. EzERMA8GA1UEAxMIc3dhcm0tY2EwHhcNMTcwNDI0MjE0MzAwWhcNMzcwNDE5MjE0
  2857. MzAwWjATMREwDwYDVQQDEwhzd2FybS1jYTBZMBMGByqGSM49AgEGCCqGSM49AwEH
  2858. A0IABJk/VyMPYdaqDXJb/VXh5n/1Yuv7iNrxV3Qb3l06XD46seovcDWs3IZNV1lf
  2859. 3Skyr0ofcchipoiHkXBODojJydSjQjBAMA4GA1UdDwEB/wQEAwIBBjAPBgNVHRMB
  2860. Af8EBTADAQH/MB0GA1UdDgQWBBRUXxuRcnFjDfR/RIAUQab8ZV/n4jAKBggqhkjO
  2861. PQQDAgNIADBFAiAy+JTe6Uc3KyLCMiqGl2GyWGQqQDEcO3/YG36x7om65AIhAJvz
  2862. pxv6zFeVEkAEEkqIYi0omA9+CjanB/6Bz4n1uw8H
  2863. -----END CERTIFICATE-----
  2864. CertIssuerSubject: "MBMxETAPBgNVBAMTCHN3YXJtLWNh"
  2865. CertIssuerPublicKey: "MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEmT9XIw9h1qoNclv9VeHmf/Vi6/uI2vFXdBveXTpcPjqx6i9wNazchk1XWV/dKTKvSh9xyGKmiIeRcE4OiMnJ1A=="
  2866. NodeStatus:
  2867. description: |
  2868. NodeStatus represents the status of a node.
  2869. It provides the current status of the node, as seen by the manager.
  2870. type: "object"
  2871. properties:
  2872. State:
  2873. $ref: "#/definitions/NodeState"
  2874. Message:
  2875. type: "string"
  2876. example: ""
  2877. Addr:
  2878. description: "IP address of the node."
  2879. type: "string"
  2880. example: "172.17.0.2"
  2881. NodeState:
  2882. description: "NodeState represents the state of a node."
  2883. type: "string"
  2884. enum:
  2885. - "unknown"
  2886. - "down"
  2887. - "ready"
  2888. - "disconnected"
  2889. example: "ready"
  2890. ManagerStatus:
  2891. description: |
  2892. ManagerStatus represents the status of a manager.
  2893. It provides the current status of a node's manager component, if the node
  2894. is a manager.
  2895. x-nullable: true
  2896. type: "object"
  2897. properties:
  2898. Leader:
  2899. type: "boolean"
  2900. default: false
  2901. example: true
  2902. Reachability:
  2903. $ref: "#/definitions/Reachability"
  2904. Addr:
  2905. description: |
  2906. The IP address and port at which the manager is reachable.
  2907. type: "string"
  2908. example: "10.0.0.46:2377"
  2909. Reachability:
  2910. description: "Reachability represents the reachability of a node."
  2911. type: "string"
  2912. enum:
  2913. - "unknown"
  2914. - "unreachable"
  2915. - "reachable"
  2916. example: "reachable"
  2917. SwarmSpec:
  2918. description: "User modifiable swarm configuration."
  2919. type: "object"
  2920. properties:
  2921. Name:
  2922. description: "Name of the swarm."
  2923. type: "string"
  2924. example: "default"
  2925. Labels:
  2926. description: "User-defined key/value metadata."
  2927. type: "object"
  2928. additionalProperties:
  2929. type: "string"
  2930. example:
  2931. com.example.corp.type: "production"
  2932. com.example.corp.department: "engineering"
  2933. Orchestration:
  2934. description: "Orchestration configuration."
  2935. type: "object"
  2936. x-nullable: true
  2937. properties:
  2938. TaskHistoryRetentionLimit:
  2939. description: |
  2940. The number of historic tasks to keep per instance or node. If
  2941. negative, never remove completed or failed tasks.
  2942. type: "integer"
  2943. format: "int64"
  2944. example: 10
  2945. Raft:
  2946. description: "Raft configuration."
  2947. type: "object"
  2948. properties:
  2949. SnapshotInterval:
  2950. description: "The number of log entries between snapshots."
  2951. type: "integer"
  2952. format: "uint64"
  2953. example: 10000
  2954. KeepOldSnapshots:
  2955. description: |
  2956. The number of snapshots to keep beyond the current snapshot.
  2957. type: "integer"
  2958. format: "uint64"
  2959. LogEntriesForSlowFollowers:
  2960. description: |
  2961. The number of log entries to keep around to sync up slow followers
  2962. after a snapshot is created.
  2963. type: "integer"
  2964. format: "uint64"
  2965. example: 500
  2966. ElectionTick:
  2967. description: |
  2968. The number of ticks that a follower will wait for a message from
  2969. the leader before becoming a candidate and starting an election.
  2970. `ElectionTick` must be greater than `HeartbeatTick`.
  2971. A tick currently defaults to one second, so these translate
  2972. directly to seconds currently, but this is NOT guaranteed.
  2973. type: "integer"
  2974. example: 3
  2975. HeartbeatTick:
  2976. description: |
  2977. The number of ticks between heartbeats. Every HeartbeatTick ticks,
  2978. the leader will send a heartbeat to the followers.
  2979. A tick currently defaults to one second, so these translate
  2980. directly to seconds currently, but this is NOT guaranteed.
  2981. type: "integer"
  2982. example: 1
  2983. Dispatcher:
  2984. description: "Dispatcher configuration."
  2985. type: "object"
  2986. x-nullable: true
  2987. properties:
  2988. HeartbeatPeriod:
  2989. description: |
  2990. The delay for an agent to send a heartbeat to the dispatcher.
  2991. type: "integer"
  2992. format: "int64"
  2993. example: 5000000000
  2994. CAConfig:
  2995. description: "CA configuration."
  2996. type: "object"
  2997. x-nullable: true
  2998. properties:
  2999. NodeCertExpiry:
  3000. description: "The duration node certificates are issued for."
  3001. type: "integer"
  3002. format: "int64"
  3003. example: 7776000000000000
  3004. ExternalCAs:
  3005. description: |
  3006. Configuration for forwarding signing requests to an external
  3007. certificate authority.
  3008. type: "array"
  3009. items:
  3010. type: "object"
  3011. properties:
  3012. Protocol:
  3013. description: |
  3014. Protocol for communication with the external CA (currently
  3015. only `cfssl` is supported).
  3016. type: "string"
  3017. enum:
  3018. - "cfssl"
  3019. default: "cfssl"
  3020. URL:
  3021. description: |
  3022. URL where certificate signing requests should be sent.
  3023. type: "string"
  3024. Options:
  3025. description: |
  3026. An object with key/value pairs that are interpreted as
  3027. protocol-specific options for the external CA driver.
  3028. type: "object"
  3029. additionalProperties:
  3030. type: "string"
  3031. CACert:
  3032. description: |
  3033. The root CA certificate (in PEM format) this external CA uses
  3034. to issue TLS certificates (assumed to be to the current swarm
  3035. root CA certificate if not provided).
  3036. type: "string"
  3037. SigningCACert:
  3038. description: |
  3039. The desired signing CA certificate for all swarm node TLS leaf
  3040. certificates, in PEM format.
  3041. type: "string"
  3042. SigningCAKey:
  3043. description: |
  3044. The desired signing CA key for all swarm node TLS leaf certificates,
  3045. in PEM format.
  3046. type: "string"
  3047. ForceRotate:
  3048. description: |
  3049. An integer whose purpose is to force swarm to generate a new
  3050. signing CA certificate and key, if none have been specified in
  3051. `SigningCACert` and `SigningCAKey`
  3052. format: "uint64"
  3053. type: "integer"
  3054. EncryptionConfig:
  3055. description: "Parameters related to encryption-at-rest."
  3056. type: "object"
  3057. properties:
  3058. AutoLockManagers:
  3059. description: |
  3060. If set, generate a key and use it to lock data stored on the
  3061. managers.
  3062. type: "boolean"
  3063. example: false
  3064. TaskDefaults:
  3065. description: "Defaults for creating tasks in this cluster."
  3066. type: "object"
  3067. properties:
  3068. LogDriver:
  3069. description: |
  3070. The log driver to use for tasks created in the orchestrator if
  3071. unspecified by a service.
  3072. Updating this value only affects new tasks. Existing tasks continue
  3073. to use their previously configured log driver until recreated.
  3074. type: "object"
  3075. properties:
  3076. Name:
  3077. description: |
  3078. The log driver to use as a default for new tasks.
  3079. type: "string"
  3080. example: "json-file"
  3081. Options:
  3082. description: |
  3083. Driver-specific options for the selectd log driver, specified
  3084. as key/value pairs.
  3085. type: "object"
  3086. additionalProperties:
  3087. type: "string"
  3088. example:
  3089. "max-file": "10"
  3090. "max-size": "100m"
  3091. # The Swarm information for `GET /info`. It is the same as `GET /swarm`, but
  3092. # without `JoinTokens`.
  3093. ClusterInfo:
  3094. description: |
  3095. ClusterInfo represents information about the swarm as is returned by the
  3096. "/info" endpoint. Join-tokens are not included.
  3097. x-nullable: true
  3098. type: "object"
  3099. properties:
  3100. ID:
  3101. description: "The ID of the swarm."
  3102. type: "string"
  3103. example: "abajmipo7b4xz5ip2nrla6b11"
  3104. Version:
  3105. $ref: "#/definitions/ObjectVersion"
  3106. CreatedAt:
  3107. description: |
  3108. Date and time at which the swarm was initialised in
  3109. [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format with nano-seconds.
  3110. type: "string"
  3111. format: "dateTime"
  3112. example: "2016-08-18T10:44:24.496525531Z"
  3113. UpdatedAt:
  3114. description: |
  3115. Date and time at which the swarm was last updated in
  3116. [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format with nano-seconds.
  3117. type: "string"
  3118. format: "dateTime"
  3119. example: "2017-08-09T07:09:37.632105588Z"
  3120. Spec:
  3121. $ref: "#/definitions/SwarmSpec"
  3122. TLSInfo:
  3123. $ref: "#/definitions/TLSInfo"
  3124. RootRotationInProgress:
  3125. description: |
  3126. Whether there is currently a root CA rotation in progress for the swarm
  3127. type: "boolean"
  3128. example: false
  3129. DataPathPort:
  3130. description: |
  3131. DataPathPort specifies the data path port number for data traffic.
  3132. Acceptable port range is 1024 to 49151.
  3133. If no port is set or is set to 0, the default port (4789) is used.
  3134. type: "integer"
  3135. format: "uint32"
  3136. default: 4789
  3137. example: 4789
  3138. DefaultAddrPool:
  3139. description: |
  3140. Default Address Pool specifies default subnet pools for global scope
  3141. networks.
  3142. type: "array"
  3143. items:
  3144. type: "string"
  3145. format: "CIDR"
  3146. example: ["10.10.0.0/16", "20.20.0.0/16"]
  3147. SubnetSize:
  3148. description: |
  3149. SubnetSize specifies the subnet size of the networks created from the
  3150. default subnet pool.
  3151. type: "integer"
  3152. format: "uint32"
  3153. maximum: 29
  3154. default: 24
  3155. example: 24
  3156. JoinTokens:
  3157. description: |
  3158. JoinTokens contains the tokens workers and managers need to join the swarm.
  3159. type: "object"
  3160. properties:
  3161. Worker:
  3162. description: |
  3163. The token workers can use to join the swarm.
  3164. type: "string"
  3165. example: "SWMTKN-1-3pu6hszjas19xyp7ghgosyx9k8atbfcr8p2is99znpy26u2lkl-1awxwuwd3z9j1z3puu7rcgdbx"
  3166. Manager:
  3167. description: |
  3168. The token managers can use to join the swarm.
  3169. type: "string"
  3170. example: "SWMTKN-1-3pu6hszjas19xyp7ghgosyx9k8atbfcr8p2is99znpy26u2lkl-7p73s1dx5in4tatdymyhg9hu2"
  3171. Swarm:
  3172. type: "object"
  3173. allOf:
  3174. - $ref: "#/definitions/ClusterInfo"
  3175. - type: "object"
  3176. properties:
  3177. JoinTokens:
  3178. $ref: "#/definitions/JoinTokens"
  3179. TaskSpec:
  3180. description: "User modifiable task configuration."
  3181. type: "object"
  3182. properties:
  3183. PluginSpec:
  3184. type: "object"
  3185. description: |
  3186. Plugin spec for the service. *(Experimental release only.)*
  3187. <p><br /></p>
  3188. > **Note**: ContainerSpec, NetworkAttachmentSpec, and PluginSpec are
  3189. > mutually exclusive. PluginSpec is only used when the Runtime field
  3190. > is set to `plugin`. NetworkAttachmentSpec is used when the Runtime
  3191. > field is set to `attachment`.
  3192. properties:
  3193. Name:
  3194. description: "The name or 'alias' to use for the plugin."
  3195. type: "string"
  3196. Remote:
  3197. description: "The plugin image reference to use."
  3198. type: "string"
  3199. Disabled:
  3200. description: "Disable the plugin once scheduled."
  3201. type: "boolean"
  3202. PluginPrivilege:
  3203. type: "array"
  3204. items:
  3205. $ref: "#/definitions/PluginPrivilege"
  3206. ContainerSpec:
  3207. type: "object"
  3208. description: |
  3209. Container spec for the service.
  3210. <p><br /></p>
  3211. > **Note**: ContainerSpec, NetworkAttachmentSpec, and PluginSpec are
  3212. > mutually exclusive. PluginSpec is only used when the Runtime field
  3213. > is set to `plugin`. NetworkAttachmentSpec is used when the Runtime
  3214. > field is set to `attachment`.
  3215. properties:
  3216. Image:
  3217. description: "The image name to use for the container"
  3218. type: "string"
  3219. Labels:
  3220. description: "User-defined key/value data."
  3221. type: "object"
  3222. additionalProperties:
  3223. type: "string"
  3224. Command:
  3225. description: "The command to be run in the image."
  3226. type: "array"
  3227. items:
  3228. type: "string"
  3229. Args:
  3230. description: "Arguments to the command."
  3231. type: "array"
  3232. items:
  3233. type: "string"
  3234. Hostname:
  3235. description: |
  3236. The hostname to use for the container, as a valid
  3237. [RFC 1123](https://tools.ietf.org/html/rfc1123) hostname.
  3238. type: "string"
  3239. Env:
  3240. description: |
  3241. A list of environment variables in the form `VAR=value`.
  3242. type: "array"
  3243. items:
  3244. type: "string"
  3245. Dir:
  3246. description: "The working directory for commands to run in."
  3247. type: "string"
  3248. User:
  3249. description: "The user inside the container."
  3250. type: "string"
  3251. Groups:
  3252. type: "array"
  3253. description: |
  3254. A list of additional groups that the container process will run as.
  3255. items:
  3256. type: "string"
  3257. Privileges:
  3258. type: "object"
  3259. description: "Security options for the container"
  3260. properties:
  3261. CredentialSpec:
  3262. type: "object"
  3263. description: "CredentialSpec for managed service account (Windows only)"
  3264. properties:
  3265. Config:
  3266. type: "string"
  3267. example: "0bt9dmxjvjiqermk6xrop3ekq"
  3268. description: |
  3269. Load credential spec from a Swarm Config with the given ID.
  3270. The specified config must also be present in the Configs
  3271. field with the Runtime property set.
  3272. <p><br /></p>
  3273. > **Note**: `CredentialSpec.File`, `CredentialSpec.Registry`,
  3274. > and `CredentialSpec.Config` are mutually exclusive.
  3275. File:
  3276. type: "string"
  3277. example: "spec.json"
  3278. description: |
  3279. Load credential spec from this file. The file is read by
  3280. the daemon, and must be present in the `CredentialSpecs`
  3281. subdirectory in the docker data directory, which defaults
  3282. to `C:\ProgramData\Docker\` on Windows.
  3283. For example, specifying `spec.json` loads
  3284. `C:\ProgramData\Docker\CredentialSpecs\spec.json`.
  3285. <p><br /></p>
  3286. > **Note**: `CredentialSpec.File`, `CredentialSpec.Registry`,
  3287. > and `CredentialSpec.Config` are mutually exclusive.
  3288. Registry:
  3289. type: "string"
  3290. description: |
  3291. Load credential spec from this value in the Windows
  3292. registry. The specified registry value must be located in:
  3293. `HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Virtualization\Containers\CredentialSpecs`
  3294. <p><br /></p>
  3295. > **Note**: `CredentialSpec.File`, `CredentialSpec.Registry`,
  3296. > and `CredentialSpec.Config` are mutually exclusive.
  3297. SELinuxContext:
  3298. type: "object"
  3299. description: "SELinux labels of the container"
  3300. properties:
  3301. Disable:
  3302. type: "boolean"
  3303. description: "Disable SELinux"
  3304. User:
  3305. type: "string"
  3306. description: "SELinux user label"
  3307. Role:
  3308. type: "string"
  3309. description: "SELinux role label"
  3310. Type:
  3311. type: "string"
  3312. description: "SELinux type label"
  3313. Level:
  3314. type: "string"
  3315. description: "SELinux level label"
  3316. TTY:
  3317. description: "Whether a pseudo-TTY should be allocated."
  3318. type: "boolean"
  3319. OpenStdin:
  3320. description: "Open `stdin`"
  3321. type: "boolean"
  3322. ReadOnly:
  3323. description: "Mount the container's root filesystem as read only."
  3324. type: "boolean"
  3325. Mounts:
  3326. description: |
  3327. Specification for mounts to be added to containers created as part
  3328. of the service.
  3329. type: "array"
  3330. items:
  3331. $ref: "#/definitions/Mount"
  3332. StopSignal:
  3333. description: "Signal to stop the container."
  3334. type: "string"
  3335. StopGracePeriod:
  3336. description: |
  3337. Amount of time to wait for the container to terminate before
  3338. forcefully killing it.
  3339. type: "integer"
  3340. format: "int64"
  3341. HealthCheck:
  3342. $ref: "#/definitions/HealthConfig"
  3343. Hosts:
  3344. type: "array"
  3345. description: |
  3346. A list of hostname/IP mappings to add to the container's `hosts`
  3347. file. The format of extra hosts is specified in the
  3348. [hosts(5)](http://man7.org/linux/man-pages/man5/hosts.5.html)
  3349. man page:
  3350. IP_address canonical_hostname [aliases...]
  3351. items:
  3352. type: "string"
  3353. DNSConfig:
  3354. description: |
  3355. Specification for DNS related configurations in resolver configuration
  3356. file (`resolv.conf`).
  3357. type: "object"
  3358. properties:
  3359. Nameservers:
  3360. description: "The IP addresses of the name servers."
  3361. type: "array"
  3362. items:
  3363. type: "string"
  3364. Search:
  3365. description: "A search list for host-name lookup."
  3366. type: "array"
  3367. items:
  3368. type: "string"
  3369. Options:
  3370. description: |
  3371. A list of internal resolver variables to be modified (e.g.,
  3372. `debug`, `ndots:3`, etc.).
  3373. type: "array"
  3374. items:
  3375. type: "string"
  3376. Secrets:
  3377. description: |
  3378. Secrets contains references to zero or more secrets that will be
  3379. exposed to the service.
  3380. type: "array"
  3381. items:
  3382. type: "object"
  3383. properties:
  3384. File:
  3385. description: |
  3386. File represents a specific target that is backed by a file.
  3387. type: "object"
  3388. properties:
  3389. Name:
  3390. description: |
  3391. Name represents the final filename in the filesystem.
  3392. type: "string"
  3393. UID:
  3394. description: "UID represents the file UID."
  3395. type: "string"
  3396. GID:
  3397. description: "GID represents the file GID."
  3398. type: "string"
  3399. Mode:
  3400. description: "Mode represents the FileMode of the file."
  3401. type: "integer"
  3402. format: "uint32"
  3403. SecretID:
  3404. description: |
  3405. SecretID represents the ID of the specific secret that we're
  3406. referencing.
  3407. type: "string"
  3408. SecretName:
  3409. description: |
  3410. SecretName is the name of the secret that this references,
  3411. but this is just provided for lookup/display purposes. The
  3412. secret in the reference will be identified by its ID.
  3413. type: "string"
  3414. Configs:
  3415. description: |
  3416. Configs contains references to zero or more configs that will be
  3417. exposed to the service.
  3418. type: "array"
  3419. items:
  3420. type: "object"
  3421. properties:
  3422. File:
  3423. description: |
  3424. File represents a specific target that is backed by a file.
  3425. <p><br /><p>
  3426. > **Note**: `Configs.File` and `Configs.Runtime` are mutually exclusive
  3427. type: "object"
  3428. properties:
  3429. Name:
  3430. description: |
  3431. Name represents the final filename in the filesystem.
  3432. type: "string"
  3433. UID:
  3434. description: "UID represents the file UID."
  3435. type: "string"
  3436. GID:
  3437. description: "GID represents the file GID."
  3438. type: "string"
  3439. Mode:
  3440. description: "Mode represents the FileMode of the file."
  3441. type: "integer"
  3442. format: "uint32"
  3443. Runtime:
  3444. description: |
  3445. Runtime represents a target that is not mounted into the
  3446. container but is used by the task
  3447. <p><br /><p>
  3448. > **Note**: `Configs.File` and `Configs.Runtime` are mutually
  3449. > exclusive
  3450. type: "object"
  3451. ConfigID:
  3452. description: |
  3453. ConfigID represents the ID of the specific config that we're
  3454. referencing.
  3455. type: "string"
  3456. ConfigName:
  3457. description: |
  3458. ConfigName is the name of the config that this references,
  3459. but this is just provided for lookup/display purposes. The
  3460. config in the reference will be identified by its ID.
  3461. type: "string"
  3462. Isolation:
  3463. type: "string"
  3464. description: |
  3465. Isolation technology of the containers running the service.
  3466. (Windows only)
  3467. enum:
  3468. - "default"
  3469. - "process"
  3470. - "hyperv"
  3471. Init:
  3472. description: |
  3473. Run an init inside the container that forwards signals and reaps
  3474. processes. This field is omitted if empty, and the default (as
  3475. configured on the daemon) is used.
  3476. type: "boolean"
  3477. x-nullable: true
  3478. Sysctls:
  3479. description: |
  3480. Set kernel namedspaced parameters (sysctls) in the container.
  3481. The Sysctls option on services accepts the same sysctls as the
  3482. are supported on containers. Note that while the same sysctls are
  3483. supported, no guarantees or checks are made about their
  3484. suitability for a clustered environment, and it's up to the user
  3485. to determine whether a given sysctl will work properly in a
  3486. Service.
  3487. type: "object"
  3488. additionalProperties:
  3489. type: "string"
  3490. # This option is not used by Windows containers
  3491. CapabilityAdd:
  3492. type: "array"
  3493. description: |
  3494. A list of kernel capabilities to add to the default set
  3495. for the container.
  3496. items:
  3497. type: "string"
  3498. example:
  3499. - "CAP_NET_RAW"
  3500. - "CAP_SYS_ADMIN"
  3501. - "CAP_SYS_CHROOT"
  3502. - "CAP_SYSLOG"
  3503. CapabilityDrop:
  3504. type: "array"
  3505. description: |
  3506. A list of kernel capabilities to drop from the default set
  3507. for the container.
  3508. items:
  3509. type: "string"
  3510. example:
  3511. - "CAP_NET_RAW"
  3512. Ulimits:
  3513. description: |
  3514. A list of resource limits to set in the container. For example: `{"Name": "nofile", "Soft": 1024, "Hard": 2048}`"
  3515. type: "array"
  3516. items:
  3517. type: "object"
  3518. properties:
  3519. Name:
  3520. description: "Name of ulimit"
  3521. type: "string"
  3522. Soft:
  3523. description: "Soft limit"
  3524. type: "integer"
  3525. Hard:
  3526. description: "Hard limit"
  3527. type: "integer"
  3528. NetworkAttachmentSpec:
  3529. description: |
  3530. Read-only spec type for non-swarm containers attached to swarm overlay
  3531. networks.
  3532. <p><br /></p>
  3533. > **Note**: ContainerSpec, NetworkAttachmentSpec, and PluginSpec are
  3534. > mutually exclusive. PluginSpec is only used when the Runtime field
  3535. > is set to `plugin`. NetworkAttachmentSpec is used when the Runtime
  3536. > field is set to `attachment`.
  3537. type: "object"
  3538. properties:
  3539. ContainerID:
  3540. description: "ID of the container represented by this task"
  3541. type: "string"
  3542. Resources:
  3543. description: |
  3544. Resource requirements which apply to each individual container created
  3545. as part of the service.
  3546. type: "object"
  3547. properties:
  3548. Limits:
  3549. description: "Define resources limits."
  3550. $ref: "#/definitions/Limit"
  3551. Reservations:
  3552. description: "Define resources reservation."
  3553. $ref: "#/definitions/ResourceObject"
  3554. RestartPolicy:
  3555. description: |
  3556. Specification for the restart policy which applies to containers
  3557. created as part of this service.
  3558. type: "object"
  3559. properties:
  3560. Condition:
  3561. description: "Condition for restart."
  3562. type: "string"
  3563. enum:
  3564. - "none"
  3565. - "on-failure"
  3566. - "any"
  3567. Delay:
  3568. description: "Delay between restart attempts."
  3569. type: "integer"
  3570. format: "int64"
  3571. MaxAttempts:
  3572. description: |
  3573. Maximum attempts to restart a given container before giving up
  3574. (default value is 0, which is ignored).
  3575. type: "integer"
  3576. format: "int64"
  3577. default: 0
  3578. Window:
  3579. description: |
  3580. Windows is the time window used to evaluate the restart policy
  3581. (default value is 0, which is unbounded).
  3582. type: "integer"
  3583. format: "int64"
  3584. default: 0
  3585. Placement:
  3586. type: "object"
  3587. properties:
  3588. Constraints:
  3589. description: |
  3590. An array of constraint expressions to limit the set of nodes where
  3591. a task can be scheduled. Constraint expressions can either use a
  3592. _match_ (`==`) or _exclude_ (`!=`) rule. Multiple constraints find
  3593. nodes that satisfy every expression (AND match). Constraints can
  3594. match node or Docker Engine labels as follows:
  3595. node attribute | matches | example
  3596. ---------------------|--------------------------------|-----------------------------------------------
  3597. `node.id` | Node ID | `node.id==2ivku8v2gvtg4`
  3598. `node.hostname` | Node hostname | `node.hostname!=node-2`
  3599. `node.role` | Node role (`manager`/`worker`) | `node.role==manager`
  3600. `node.platform.os` | Node operating system | `node.platform.os==windows`
  3601. `node.platform.arch` | Node architecture | `node.platform.arch==x86_64`
  3602. `node.labels` | User-defined node labels | `node.labels.security==high`
  3603. `engine.labels` | Docker Engine's labels | `engine.labels.operatingsystem==ubuntu-14.04`
  3604. `engine.labels` apply to Docker Engine labels like operating system,
  3605. drivers, etc. Swarm administrators add `node.labels` for operational
  3606. purposes by using the [`node update endpoint`](#operation/NodeUpdate).
  3607. type: "array"
  3608. items:
  3609. type: "string"
  3610. example:
  3611. - "node.hostname!=node3.corp.example.com"
  3612. - "node.role!=manager"
  3613. - "node.labels.type==production"
  3614. - "node.platform.os==linux"
  3615. - "node.platform.arch==x86_64"
  3616. Preferences:
  3617. description: |
  3618. Preferences provide a way to make the scheduler aware of factors
  3619. such as topology. They are provided in order from highest to
  3620. lowest precedence.
  3621. type: "array"
  3622. items:
  3623. type: "object"
  3624. properties:
  3625. Spread:
  3626. type: "object"
  3627. properties:
  3628. SpreadDescriptor:
  3629. description: |
  3630. label descriptor, such as `engine.labels.az`.
  3631. type: "string"
  3632. example:
  3633. - Spread:
  3634. SpreadDescriptor: "node.labels.datacenter"
  3635. - Spread:
  3636. SpreadDescriptor: "node.labels.rack"
  3637. MaxReplicas:
  3638. description: |
  3639. Maximum number of replicas for per node (default value is 0, which
  3640. is unlimited)
  3641. type: "integer"
  3642. format: "int64"
  3643. default: 0
  3644. Platforms:
  3645. description: |
  3646. Platforms stores all the platforms that the service's image can
  3647. run on. This field is used in the platform filter for scheduling.
  3648. If empty, then the platform filter is off, meaning there are no
  3649. scheduling restrictions.
  3650. type: "array"
  3651. items:
  3652. $ref: "#/definitions/Platform"
  3653. ForceUpdate:
  3654. description: |
  3655. A counter that triggers an update even if no relevant parameters have
  3656. been changed.
  3657. type: "integer"
  3658. Runtime:
  3659. description: |
  3660. Runtime is the type of runtime specified for the task executor.
  3661. type: "string"
  3662. Networks:
  3663. description: "Specifies which networks the service should attach to."
  3664. type: "array"
  3665. items:
  3666. $ref: "#/definitions/NetworkAttachmentConfig"
  3667. LogDriver:
  3668. description: |
  3669. Specifies the log driver to use for tasks created from this spec. If
  3670. not present, the default one for the swarm will be used, finally
  3671. falling back to the engine default if not specified.
  3672. type: "object"
  3673. properties:
  3674. Name:
  3675. type: "string"
  3676. Options:
  3677. type: "object"
  3678. additionalProperties:
  3679. type: "string"
  3680. TaskState:
  3681. type: "string"
  3682. enum:
  3683. - "new"
  3684. - "allocated"
  3685. - "pending"
  3686. - "assigned"
  3687. - "accepted"
  3688. - "preparing"
  3689. - "ready"
  3690. - "starting"
  3691. - "running"
  3692. - "complete"
  3693. - "shutdown"
  3694. - "failed"
  3695. - "rejected"
  3696. - "remove"
  3697. - "orphaned"
  3698. Task:
  3699. type: "object"
  3700. properties:
  3701. ID:
  3702. description: "The ID of the task."
  3703. type: "string"
  3704. Version:
  3705. $ref: "#/definitions/ObjectVersion"
  3706. CreatedAt:
  3707. type: "string"
  3708. format: "dateTime"
  3709. UpdatedAt:
  3710. type: "string"
  3711. format: "dateTime"
  3712. Name:
  3713. description: "Name of the task."
  3714. type: "string"
  3715. Labels:
  3716. description: "User-defined key/value metadata."
  3717. type: "object"
  3718. additionalProperties:
  3719. type: "string"
  3720. Spec:
  3721. $ref: "#/definitions/TaskSpec"
  3722. ServiceID:
  3723. description: "The ID of the service this task is part of."
  3724. type: "string"
  3725. Slot:
  3726. type: "integer"
  3727. NodeID:
  3728. description: "The ID of the node that this task is on."
  3729. type: "string"
  3730. AssignedGenericResources:
  3731. $ref: "#/definitions/GenericResources"
  3732. Status:
  3733. type: "object"
  3734. properties:
  3735. Timestamp:
  3736. type: "string"
  3737. format: "dateTime"
  3738. State:
  3739. $ref: "#/definitions/TaskState"
  3740. Message:
  3741. type: "string"
  3742. Err:
  3743. type: "string"
  3744. ContainerStatus:
  3745. type: "object"
  3746. properties:
  3747. ContainerID:
  3748. type: "string"
  3749. PID:
  3750. type: "integer"
  3751. ExitCode:
  3752. type: "integer"
  3753. DesiredState:
  3754. $ref: "#/definitions/TaskState"
  3755. JobIteration:
  3756. description: |
  3757. If the Service this Task belongs to is a job-mode service, contains
  3758. the JobIteration of the Service this Task was created for. Absent if
  3759. the Task was created for a Replicated or Global Service.
  3760. $ref: "#/definitions/ObjectVersion"
  3761. example:
  3762. ID: "0kzzo1i0y4jz6027t0k7aezc7"
  3763. Version:
  3764. Index: 71
  3765. CreatedAt: "2016-06-07T21:07:31.171892745Z"
  3766. UpdatedAt: "2016-06-07T21:07:31.376370513Z"
  3767. Spec:
  3768. ContainerSpec:
  3769. Image: "redis"
  3770. Resources:
  3771. Limits: {}
  3772. Reservations: {}
  3773. RestartPolicy:
  3774. Condition: "any"
  3775. MaxAttempts: 0
  3776. Placement: {}
  3777. ServiceID: "9mnpnzenvg8p8tdbtq4wvbkcz"
  3778. Slot: 1
  3779. NodeID: "60gvrl6tm78dmak4yl7srz94v"
  3780. Status:
  3781. Timestamp: "2016-06-07T21:07:31.290032978Z"
  3782. State: "running"
  3783. Message: "started"
  3784. ContainerStatus:
  3785. ContainerID: "e5d62702a1b48d01c3e02ca1e0212a250801fa8d67caca0b6f35919ebc12f035"
  3786. PID: 677
  3787. DesiredState: "running"
  3788. NetworksAttachments:
  3789. - Network:
  3790. ID: "4qvuz4ko70xaltuqbt8956gd1"
  3791. Version:
  3792. Index: 18
  3793. CreatedAt: "2016-06-07T20:31:11.912919752Z"
  3794. UpdatedAt: "2016-06-07T21:07:29.955277358Z"
  3795. Spec:
  3796. Name: "ingress"
  3797. Labels:
  3798. com.docker.swarm.internal: "true"
  3799. DriverConfiguration: {}
  3800. IPAMOptions:
  3801. Driver: {}
  3802. Configs:
  3803. - Subnet: "10.255.0.0/16"
  3804. Gateway: "10.255.0.1"
  3805. DriverState:
  3806. Name: "overlay"
  3807. Options:
  3808. com.docker.network.driver.overlay.vxlanid_list: "256"
  3809. IPAMOptions:
  3810. Driver:
  3811. Name: "default"
  3812. Configs:
  3813. - Subnet: "10.255.0.0/16"
  3814. Gateway: "10.255.0.1"
  3815. Addresses:
  3816. - "10.255.0.10/16"
  3817. AssignedGenericResources:
  3818. - DiscreteResourceSpec:
  3819. Kind: "SSD"
  3820. Value: 3
  3821. - NamedResourceSpec:
  3822. Kind: "GPU"
  3823. Value: "UUID1"
  3824. - NamedResourceSpec:
  3825. Kind: "GPU"
  3826. Value: "UUID2"
  3827. ServiceSpec:
  3828. description: "User modifiable configuration for a service."
  3829. type: object
  3830. properties:
  3831. Name:
  3832. description: "Name of the service."
  3833. type: "string"
  3834. Labels:
  3835. description: "User-defined key/value metadata."
  3836. type: "object"
  3837. additionalProperties:
  3838. type: "string"
  3839. TaskTemplate:
  3840. $ref: "#/definitions/TaskSpec"
  3841. Mode:
  3842. description: "Scheduling mode for the service."
  3843. type: "object"
  3844. properties:
  3845. Replicated:
  3846. type: "object"
  3847. properties:
  3848. Replicas:
  3849. type: "integer"
  3850. format: "int64"
  3851. Global:
  3852. type: "object"
  3853. ReplicatedJob:
  3854. description: |
  3855. The mode used for services with a finite number of tasks that run
  3856. to a completed state.
  3857. type: "object"
  3858. properties:
  3859. MaxConcurrent:
  3860. description: |
  3861. The maximum number of replicas to run simultaneously.
  3862. type: "integer"
  3863. format: "int64"
  3864. default: 1
  3865. TotalCompletions:
  3866. description: |
  3867. The total number of replicas desired to reach the Completed
  3868. state. If unset, will default to the value of `MaxConcurrent`
  3869. type: "integer"
  3870. format: "int64"
  3871. GlobalJob:
  3872. description: |
  3873. The mode used for services which run a task to the completed state
  3874. on each valid node.
  3875. type: "object"
  3876. UpdateConfig:
  3877. description: "Specification for the update strategy of the service."
  3878. type: "object"
  3879. properties:
  3880. Parallelism:
  3881. description: |
  3882. Maximum number of tasks to be updated in one iteration (0 means
  3883. unlimited parallelism).
  3884. type: "integer"
  3885. format: "int64"
  3886. Delay:
  3887. description: "Amount of time between updates, in nanoseconds."
  3888. type: "integer"
  3889. format: "int64"
  3890. FailureAction:
  3891. description: |
  3892. Action to take if an updated task fails to run, or stops running
  3893. during the update.
  3894. type: "string"
  3895. enum:
  3896. - "continue"
  3897. - "pause"
  3898. - "rollback"
  3899. Monitor:
  3900. description: |
  3901. Amount of time to monitor each updated task for failures, in
  3902. nanoseconds.
  3903. type: "integer"
  3904. format: "int64"
  3905. MaxFailureRatio:
  3906. description: |
  3907. The fraction of tasks that may fail during an update before the
  3908. failure action is invoked, specified as a floating point number
  3909. between 0 and 1.
  3910. type: "number"
  3911. default: 0
  3912. Order:
  3913. description: |
  3914. The order of operations when rolling out an updated task. Either
  3915. the old task is shut down before the new task is started, or the
  3916. new task is started before the old task is shut down.
  3917. type: "string"
  3918. enum:
  3919. - "stop-first"
  3920. - "start-first"
  3921. RollbackConfig:
  3922. description: "Specification for the rollback strategy of the service."
  3923. type: "object"
  3924. properties:
  3925. Parallelism:
  3926. description: |
  3927. Maximum number of tasks to be rolled back in one iteration (0 means
  3928. unlimited parallelism).
  3929. type: "integer"
  3930. format: "int64"
  3931. Delay:
  3932. description: |
  3933. Amount of time between rollback iterations, in nanoseconds.
  3934. type: "integer"
  3935. format: "int64"
  3936. FailureAction:
  3937. description: |
  3938. Action to take if an rolled back task fails to run, or stops
  3939. running during the rollback.
  3940. type: "string"
  3941. enum:
  3942. - "continue"
  3943. - "pause"
  3944. Monitor:
  3945. description: |
  3946. Amount of time to monitor each rolled back task for failures, in
  3947. nanoseconds.
  3948. type: "integer"
  3949. format: "int64"
  3950. MaxFailureRatio:
  3951. description: |
  3952. The fraction of tasks that may fail during a rollback before the
  3953. failure action is invoked, specified as a floating point number
  3954. between 0 and 1.
  3955. type: "number"
  3956. default: 0
  3957. Order:
  3958. description: |
  3959. The order of operations when rolling back a task. Either the old
  3960. task is shut down before the new task is started, or the new task
  3961. is started before the old task is shut down.
  3962. type: "string"
  3963. enum:
  3964. - "stop-first"
  3965. - "start-first"
  3966. Networks:
  3967. description: "Specifies which networks the service should attach to."
  3968. type: "array"
  3969. items:
  3970. $ref: "#/definitions/NetworkAttachmentConfig"
  3971. EndpointSpec:
  3972. $ref: "#/definitions/EndpointSpec"
  3973. EndpointPortConfig:
  3974. type: "object"
  3975. properties:
  3976. Name:
  3977. type: "string"
  3978. Protocol:
  3979. type: "string"
  3980. enum:
  3981. - "tcp"
  3982. - "udp"
  3983. - "sctp"
  3984. TargetPort:
  3985. description: "The port inside the container."
  3986. type: "integer"
  3987. PublishedPort:
  3988. description: "The port on the swarm hosts."
  3989. type: "integer"
  3990. PublishMode:
  3991. description: |
  3992. The mode in which port is published.
  3993. <p><br /></p>
  3994. - "ingress" makes the target port accessible on every node,
  3995. regardless of whether there is a task for the service running on
  3996. that node or not.
  3997. - "host" bypasses the routing mesh and publish the port directly on
  3998. the swarm node where that service is running.
  3999. type: "string"
  4000. enum:
  4001. - "ingress"
  4002. - "host"
  4003. default: "ingress"
  4004. example: "ingress"
  4005. EndpointSpec:
  4006. description: "Properties that can be configured to access and load balance a service."
  4007. type: "object"
  4008. properties:
  4009. Mode:
  4010. description: |
  4011. The mode of resolution to use for internal load balancing between tasks.
  4012. type: "string"
  4013. enum:
  4014. - "vip"
  4015. - "dnsrr"
  4016. default: "vip"
  4017. Ports:
  4018. description: |
  4019. List of exposed ports that this service is accessible on from the
  4020. outside. Ports can only be provided if `vip` resolution mode is used.
  4021. type: "array"
  4022. items:
  4023. $ref: "#/definitions/EndpointPortConfig"
  4024. Service:
  4025. type: "object"
  4026. properties:
  4027. ID:
  4028. type: "string"
  4029. Version:
  4030. $ref: "#/definitions/ObjectVersion"
  4031. CreatedAt:
  4032. type: "string"
  4033. format: "dateTime"
  4034. UpdatedAt:
  4035. type: "string"
  4036. format: "dateTime"
  4037. Spec:
  4038. $ref: "#/definitions/ServiceSpec"
  4039. Endpoint:
  4040. type: "object"
  4041. properties:
  4042. Spec:
  4043. $ref: "#/definitions/EndpointSpec"
  4044. Ports:
  4045. type: "array"
  4046. items:
  4047. $ref: "#/definitions/EndpointPortConfig"
  4048. VirtualIPs:
  4049. type: "array"
  4050. items:
  4051. type: "object"
  4052. properties:
  4053. NetworkID:
  4054. type: "string"
  4055. Addr:
  4056. type: "string"
  4057. UpdateStatus:
  4058. description: "The status of a service update."
  4059. type: "object"
  4060. properties:
  4061. State:
  4062. type: "string"
  4063. enum:
  4064. - "updating"
  4065. - "paused"
  4066. - "completed"
  4067. StartedAt:
  4068. type: "string"
  4069. format: "dateTime"
  4070. CompletedAt:
  4071. type: "string"
  4072. format: "dateTime"
  4073. Message:
  4074. type: "string"
  4075. ServiceStatus:
  4076. description: |
  4077. The status of the service's tasks. Provided only when requested as
  4078. part of a ServiceList operation.
  4079. type: "object"
  4080. properties:
  4081. RunningTasks:
  4082. description: |
  4083. The number of tasks for the service currently in the Running state.
  4084. type: "integer"
  4085. format: "uint64"
  4086. example: 7
  4087. DesiredTasks:
  4088. description: |
  4089. The number of tasks for the service desired to be running.
  4090. For replicated services, this is the replica count from the
  4091. service spec. For global services, this is computed by taking
  4092. count of all tasks for the service with a Desired State other
  4093. than Shutdown.
  4094. type: "integer"
  4095. format: "uint64"
  4096. example: 10
  4097. CompletedTasks:
  4098. description: |
  4099. The number of tasks for a job that are in the Completed state.
  4100. This field must be cross-referenced with the service type, as the
  4101. value of 0 may mean the service is not in a job mode, or it may
  4102. mean the job-mode service has no tasks yet Completed.
  4103. type: "integer"
  4104. format: "uint64"
  4105. JobStatus:
  4106. description: |
  4107. The status of the service when it is in one of ReplicatedJob or
  4108. GlobalJob modes. Absent on Replicated and Global mode services. The
  4109. JobIteration is an ObjectVersion, but unlike the Service's version,
  4110. does not need to be sent with an update request.
  4111. type: "object"
  4112. properties:
  4113. JobIteration:
  4114. description: |
  4115. JobIteration is a value increased each time a Job is executed,
  4116. successfully or otherwise. "Executed", in this case, means the
  4117. job as a whole has been started, not that an individual Task has
  4118. been launched. A job is "Executed" when its ServiceSpec is
  4119. updated. JobIteration can be used to disambiguate Tasks belonging
  4120. to different executions of a job. Though JobIteration will
  4121. increase with each subsequent execution, it may not necessarily
  4122. increase by 1, and so JobIteration should not be used to
  4123. $ref: "#/definitions/ObjectVersion"
  4124. LastExecution:
  4125. description: |
  4126. The last time, as observed by the server, that this job was
  4127. started.
  4128. type: "string"
  4129. format: "dateTime"
  4130. example:
  4131. ID: "9mnpnzenvg8p8tdbtq4wvbkcz"
  4132. Version:
  4133. Index: 19
  4134. CreatedAt: "2016-06-07T21:05:51.880065305Z"
  4135. UpdatedAt: "2016-06-07T21:07:29.962229872Z"
  4136. Spec:
  4137. Name: "hopeful_cori"
  4138. TaskTemplate:
  4139. ContainerSpec:
  4140. Image: "redis"
  4141. Resources:
  4142. Limits: {}
  4143. Reservations: {}
  4144. RestartPolicy:
  4145. Condition: "any"
  4146. MaxAttempts: 0
  4147. Placement: {}
  4148. ForceUpdate: 0
  4149. Mode:
  4150. Replicated:
  4151. Replicas: 1
  4152. UpdateConfig:
  4153. Parallelism: 1
  4154. Delay: 1000000000
  4155. FailureAction: "pause"
  4156. Monitor: 15000000000
  4157. MaxFailureRatio: 0.15
  4158. RollbackConfig:
  4159. Parallelism: 1
  4160. Delay: 1000000000
  4161. FailureAction: "pause"
  4162. Monitor: 15000000000
  4163. MaxFailureRatio: 0.15
  4164. EndpointSpec:
  4165. Mode: "vip"
  4166. Ports:
  4167. -
  4168. Protocol: "tcp"
  4169. TargetPort: 6379
  4170. PublishedPort: 30001
  4171. Endpoint:
  4172. Spec:
  4173. Mode: "vip"
  4174. Ports:
  4175. -
  4176. Protocol: "tcp"
  4177. TargetPort: 6379
  4178. PublishedPort: 30001
  4179. Ports:
  4180. -
  4181. Protocol: "tcp"
  4182. TargetPort: 6379
  4183. PublishedPort: 30001
  4184. VirtualIPs:
  4185. -
  4186. NetworkID: "4qvuz4ko70xaltuqbt8956gd1"
  4187. Addr: "10.255.0.2/16"
  4188. -
  4189. NetworkID: "4qvuz4ko70xaltuqbt8956gd1"
  4190. Addr: "10.255.0.3/16"
  4191. ImageDeleteResponseItem:
  4192. type: "object"
  4193. properties:
  4194. Untagged:
  4195. description: "The image ID of an image that was untagged"
  4196. type: "string"
  4197. Deleted:
  4198. description: "The image ID of an image that was deleted"
  4199. type: "string"
  4200. ServiceUpdateResponse:
  4201. type: "object"
  4202. properties:
  4203. Warnings:
  4204. description: "Optional warning messages"
  4205. type: "array"
  4206. items:
  4207. type: "string"
  4208. example:
  4209. Warning: "unable to pin image doesnotexist:latest to digest: image library/doesnotexist:latest not found"
  4210. ContainerSummary:
  4211. type: "object"
  4212. properties:
  4213. Id:
  4214. description: "The ID of this container"
  4215. type: "string"
  4216. x-go-name: "ID"
  4217. Names:
  4218. description: "The names that this container has been given"
  4219. type: "array"
  4220. items:
  4221. type: "string"
  4222. Image:
  4223. description: "The name of the image used when creating this container"
  4224. type: "string"
  4225. ImageID:
  4226. description: "The ID of the image that this container was created from"
  4227. type: "string"
  4228. Command:
  4229. description: "Command to run when starting the container"
  4230. type: "string"
  4231. Created:
  4232. description: "When the container was created"
  4233. type: "integer"
  4234. format: "int64"
  4235. Ports:
  4236. description: "The ports exposed by this container"
  4237. type: "array"
  4238. items:
  4239. $ref: "#/definitions/Port"
  4240. SizeRw:
  4241. description: "The size of files that have been created or changed by this container"
  4242. type: "integer"
  4243. format: "int64"
  4244. SizeRootFs:
  4245. description: "The total size of all the files in this container"
  4246. type: "integer"
  4247. format: "int64"
  4248. Labels:
  4249. description: "User-defined key/value metadata."
  4250. type: "object"
  4251. additionalProperties:
  4252. type: "string"
  4253. State:
  4254. description: "The state of this container (e.g. `Exited`)"
  4255. type: "string"
  4256. Status:
  4257. description: "Additional human-readable status of this container (e.g. `Exit 0`)"
  4258. type: "string"
  4259. HostConfig:
  4260. type: "object"
  4261. properties:
  4262. NetworkMode:
  4263. type: "string"
  4264. NetworkSettings:
  4265. description: "A summary of the container's network settings"
  4266. type: "object"
  4267. properties:
  4268. Networks:
  4269. type: "object"
  4270. additionalProperties:
  4271. $ref: "#/definitions/EndpointSettings"
  4272. Mounts:
  4273. type: "array"
  4274. items:
  4275. $ref: "#/definitions/MountPoint"
  4276. Driver:
  4277. description: "Driver represents a driver (network, logging, secrets)."
  4278. type: "object"
  4279. required: [Name]
  4280. properties:
  4281. Name:
  4282. description: "Name of the driver."
  4283. type: "string"
  4284. x-nullable: false
  4285. example: "some-driver"
  4286. Options:
  4287. description: "Key/value map of driver-specific options."
  4288. type: "object"
  4289. x-nullable: false
  4290. additionalProperties:
  4291. type: "string"
  4292. example:
  4293. OptionA: "value for driver-specific option A"
  4294. OptionB: "value for driver-specific option B"
  4295. SecretSpec:
  4296. type: "object"
  4297. properties:
  4298. Name:
  4299. description: "User-defined name of the secret."
  4300. type: "string"
  4301. Labels:
  4302. description: "User-defined key/value metadata."
  4303. type: "object"
  4304. additionalProperties:
  4305. type: "string"
  4306. example:
  4307. com.example.some-label: "some-value"
  4308. com.example.some-other-label: "some-other-value"
  4309. Data:
  4310. description: |
  4311. Base64-url-safe-encoded ([RFC 4648](https://tools.ietf.org/html/rfc4648#section-5))
  4312. data to store as secret.
  4313. This field is only used to _create_ a secret, and is not returned by
  4314. other endpoints.
  4315. type: "string"
  4316. example: ""
  4317. Driver:
  4318. description: |
  4319. Name of the secrets driver used to fetch the secret's value from an
  4320. external secret store.
  4321. $ref: "#/definitions/Driver"
  4322. Templating:
  4323. description: |
  4324. Templating driver, if applicable
  4325. Templating controls whether and how to evaluate the config payload as
  4326. a template. If no driver is set, no templating is used.
  4327. $ref: "#/definitions/Driver"
  4328. Secret:
  4329. type: "object"
  4330. properties:
  4331. ID:
  4332. type: "string"
  4333. example: "blt1owaxmitz71s9v5zh81zun"
  4334. Version:
  4335. $ref: "#/definitions/ObjectVersion"
  4336. CreatedAt:
  4337. type: "string"
  4338. format: "dateTime"
  4339. example: "2017-07-20T13:55:28.678958722Z"
  4340. UpdatedAt:
  4341. type: "string"
  4342. format: "dateTime"
  4343. example: "2017-07-20T13:55:28.678958722Z"
  4344. Spec:
  4345. $ref: "#/definitions/SecretSpec"
  4346. ConfigSpec:
  4347. type: "object"
  4348. properties:
  4349. Name:
  4350. description: "User-defined name of the config."
  4351. type: "string"
  4352. Labels:
  4353. description: "User-defined key/value metadata."
  4354. type: "object"
  4355. additionalProperties:
  4356. type: "string"
  4357. Data:
  4358. description: |
  4359. Base64-url-safe-encoded ([RFC 4648](https://tools.ietf.org/html/rfc4648#section-5))
  4360. config data.
  4361. type: "string"
  4362. Templating:
  4363. description: |
  4364. Templating driver, if applicable
  4365. Templating controls whether and how to evaluate the config payload as
  4366. a template. If no driver is set, no templating is used.
  4367. $ref: "#/definitions/Driver"
  4368. Config:
  4369. type: "object"
  4370. properties:
  4371. ID:
  4372. type: "string"
  4373. Version:
  4374. $ref: "#/definitions/ObjectVersion"
  4375. CreatedAt:
  4376. type: "string"
  4377. format: "dateTime"
  4378. UpdatedAt:
  4379. type: "string"
  4380. format: "dateTime"
  4381. Spec:
  4382. $ref: "#/definitions/ConfigSpec"
  4383. ContainerState:
  4384. description: |
  4385. ContainerState stores container's running state. It's part of ContainerJSONBase
  4386. and will be returned by the "inspect" command.
  4387. type: "object"
  4388. x-nullable: true
  4389. properties:
  4390. Status:
  4391. description: |
  4392. String representation of the container state. Can be one of "created",
  4393. "running", "paused", "restarting", "removing", "exited", or "dead".
  4394. type: "string"
  4395. enum: ["created", "running", "paused", "restarting", "removing", "exited", "dead"]
  4396. example: "running"
  4397. Running:
  4398. description: |
  4399. Whether this container is running.
  4400. Note that a running container can be _paused_. The `Running` and `Paused`
  4401. booleans are not mutually exclusive:
  4402. When pausing a container (on Linux), the freezer cgroup is used to suspend
  4403. all processes in the container. Freezing the process requires the process to
  4404. be running. As a result, paused containers are both `Running` _and_ `Paused`.
  4405. Use the `Status` field instead to determine if a container's state is "running".
  4406. type: "boolean"
  4407. example: true
  4408. Paused:
  4409. description: "Whether this container is paused."
  4410. type: "boolean"
  4411. example: false
  4412. Restarting:
  4413. description: "Whether this container is restarting."
  4414. type: "boolean"
  4415. example: false
  4416. OOMKilled:
  4417. description: |
  4418. Whether this container has been killed because it ran out of memory.
  4419. type: "boolean"
  4420. example: false
  4421. Dead:
  4422. type: "boolean"
  4423. example: false
  4424. Pid:
  4425. description: "The process ID of this container"
  4426. type: "integer"
  4427. example: 1234
  4428. ExitCode:
  4429. description: "The last exit code of this container"
  4430. type: "integer"
  4431. example: 0
  4432. Error:
  4433. type: "string"
  4434. StartedAt:
  4435. description: "The time when this container was last started."
  4436. type: "string"
  4437. example: "2020-01-06T09:06:59.461876391Z"
  4438. FinishedAt:
  4439. description: "The time when this container last exited."
  4440. type: "string"
  4441. example: "2020-01-06T09:07:59.461876391Z"
  4442. Health:
  4443. $ref: "#/definitions/Health"
  4444. ContainerWaitResponse:
  4445. description: "OK response to ContainerWait operation"
  4446. type: "object"
  4447. x-go-name: "ContainerWaitOKBody"
  4448. title: "ContainerWaitResponse"
  4449. required: [StatusCode]
  4450. properties:
  4451. StatusCode:
  4452. description: "Exit code of the container"
  4453. type: "integer"
  4454. format: "int64"
  4455. x-nullable: false
  4456. Error:
  4457. $ref: "#/definitions/ContainerWaitExitError"
  4458. ContainerWaitExitError:
  4459. description: "container waiting error, if any"
  4460. type: "object"
  4461. x-go-name: "ContainerWaitOKBodyError"
  4462. properties:
  4463. Message:
  4464. description: "Details of an error"
  4465. type: "string"
  4466. SystemVersion:
  4467. type: "object"
  4468. description: |
  4469. Response of Engine API: GET "/version"
  4470. properties:
  4471. Platform:
  4472. type: "object"
  4473. required: [Name]
  4474. properties:
  4475. Name:
  4476. type: "string"
  4477. Components:
  4478. type: "array"
  4479. description: |
  4480. Information about system components
  4481. items:
  4482. type: "object"
  4483. x-go-name: ComponentVersion
  4484. required: [Name, Version]
  4485. properties:
  4486. Name:
  4487. description: |
  4488. Name of the component
  4489. type: "string"
  4490. example: "Engine"
  4491. Version:
  4492. description: |
  4493. Version of the component
  4494. type: "string"
  4495. x-nullable: false
  4496. example: "19.03.12"
  4497. Details:
  4498. description: |
  4499. Key/value pairs of strings with additional information about the
  4500. component. These values are intended for informational purposes
  4501. only, and their content is not defined, and not part of the API
  4502. specification.
  4503. These messages can be printed by the client as information to the user.
  4504. type: "object"
  4505. x-nullable: true
  4506. Version:
  4507. description: "The version of the daemon"
  4508. type: "string"
  4509. example: "19.03.12"
  4510. ApiVersion:
  4511. description: |
  4512. The default (and highest) API version that is supported by the daemon
  4513. type: "string"
  4514. example: "1.40"
  4515. MinAPIVersion:
  4516. description: |
  4517. The minimum API version that is supported by the daemon
  4518. type: "string"
  4519. example: "1.12"
  4520. GitCommit:
  4521. description: |
  4522. The Git commit of the source code that was used to build the daemon
  4523. type: "string"
  4524. example: "48a66213fe"
  4525. GoVersion:
  4526. description: |
  4527. The version Go used to compile the daemon, and the version of the Go
  4528. runtime in use.
  4529. type: "string"
  4530. example: "go1.13.14"
  4531. Os:
  4532. description: |
  4533. The operating system that the daemon is running on ("linux" or "windows")
  4534. type: "string"
  4535. example: "linux"
  4536. Arch:
  4537. description: |
  4538. The architecture that the daemon is running on
  4539. type: "string"
  4540. example: "amd64"
  4541. KernelVersion:
  4542. description: |
  4543. The kernel version (`uname -r`) that the daemon is running on.
  4544. This field is omitted when empty.
  4545. type: "string"
  4546. example: "4.19.76-linuxkit"
  4547. Experimental:
  4548. description: |
  4549. Indicates if the daemon is started with experimental features enabled.
  4550. This field is omitted when empty / false.
  4551. type: "boolean"
  4552. example: true
  4553. BuildTime:
  4554. description: |
  4555. The date and time that the daemon was compiled.
  4556. type: "string"
  4557. example: "2020-06-22T15:49:27.000000000+00:00"
  4558. SystemInfo:
  4559. type: "object"
  4560. properties:
  4561. ID:
  4562. description: |
  4563. Unique identifier of the daemon.
  4564. <p><br /></p>
  4565. > **Note**: The format of the ID itself is not part of the API, and
  4566. > should not be considered stable.
  4567. type: "string"
  4568. example: "7TRN:IPZB:QYBB:VPBQ:UMPP:KARE:6ZNR:XE6T:7EWV:PKF4:ZOJD:TPYS"
  4569. Containers:
  4570. description: "Total number of containers on the host."
  4571. type: "integer"
  4572. example: 14
  4573. ContainersRunning:
  4574. description: |
  4575. Number of containers with status `"running"`.
  4576. type: "integer"
  4577. example: 3
  4578. ContainersPaused:
  4579. description: |
  4580. Number of containers with status `"paused"`.
  4581. type: "integer"
  4582. example: 1
  4583. ContainersStopped:
  4584. description: |
  4585. Number of containers with status `"stopped"`.
  4586. type: "integer"
  4587. example: 10
  4588. Images:
  4589. description: |
  4590. Total number of images on the host.
  4591. Both _tagged_ and _untagged_ (dangling) images are counted.
  4592. type: "integer"
  4593. example: 508
  4594. Driver:
  4595. description: "Name of the storage driver in use."
  4596. type: "string"
  4597. example: "overlay2"
  4598. DriverStatus:
  4599. description: |
  4600. Information specific to the storage driver, provided as
  4601. "label" / "value" pairs.
  4602. This information is provided by the storage driver, and formatted
  4603. in a way consistent with the output of `docker info` on the command
  4604. line.
  4605. <p><br /></p>
  4606. > **Note**: The information returned in this field, including the
  4607. > formatting of values and labels, should not be considered stable,
  4608. > and may change without notice.
  4609. type: "array"
  4610. items:
  4611. type: "array"
  4612. items:
  4613. type: "string"
  4614. example:
  4615. - ["Backing Filesystem", "extfs"]
  4616. - ["Supports d_type", "true"]
  4617. - ["Native Overlay Diff", "true"]
  4618. DockerRootDir:
  4619. description: |
  4620. Root directory of persistent Docker state.
  4621. Defaults to `/var/lib/docker` on Linux, and `C:\ProgramData\docker`
  4622. on Windows.
  4623. type: "string"
  4624. example: "/var/lib/docker"
  4625. Plugins:
  4626. $ref: "#/definitions/PluginsInfo"
  4627. MemoryLimit:
  4628. description: "Indicates if the host has memory limit support enabled."
  4629. type: "boolean"
  4630. example: true
  4631. SwapLimit:
  4632. description: "Indicates if the host has memory swap limit support enabled."
  4633. type: "boolean"
  4634. example: true
  4635. KernelMemory:
  4636. description: |
  4637. Indicates if the host has kernel memory limit support enabled.
  4638. <p><br /></p>
  4639. > **Deprecated**: This field is deprecated as the kernel 5.4 deprecated
  4640. > `kmem.limit_in_bytes`.
  4641. type: "boolean"
  4642. example: true
  4643. KernelMemoryTCP:
  4644. description: |
  4645. Indicates if the host has kernel memory TCP limit support enabled.
  4646. Kernel memory TCP limits are not supported when using cgroups v2, which
  4647. does not support the corresponding `memory.kmem.tcp.limit_in_bytes` cgroup.
  4648. type: "boolean"
  4649. example: true
  4650. CpuCfsPeriod:
  4651. description: |
  4652. Indicates if CPU CFS(Completely Fair Scheduler) period is supported by
  4653. the host.
  4654. type: "boolean"
  4655. example: true
  4656. CpuCfsQuota:
  4657. description: |
  4658. Indicates if CPU CFS(Completely Fair Scheduler) quota is supported by
  4659. the host.
  4660. type: "boolean"
  4661. example: true
  4662. CPUShares:
  4663. description: |
  4664. Indicates if CPU Shares limiting is supported by the host.
  4665. type: "boolean"
  4666. example: true
  4667. CPUSet:
  4668. description: |
  4669. Indicates if CPUsets (cpuset.cpus, cpuset.mems) are supported by the host.
  4670. See [cpuset(7)](https://www.kernel.org/doc/Documentation/cgroup-v1/cpusets.txt)
  4671. type: "boolean"
  4672. example: true
  4673. PidsLimit:
  4674. description: "Indicates if the host kernel has PID limit support enabled."
  4675. type: "boolean"
  4676. example: true
  4677. OomKillDisable:
  4678. description: "Indicates if OOM killer disable is supported on the host."
  4679. type: "boolean"
  4680. IPv4Forwarding:
  4681. description: "Indicates IPv4 forwarding is enabled."
  4682. type: "boolean"
  4683. example: true
  4684. BridgeNfIptables:
  4685. description: "Indicates if `bridge-nf-call-iptables` is available on the host."
  4686. type: "boolean"
  4687. example: true
  4688. BridgeNfIp6tables:
  4689. description: "Indicates if `bridge-nf-call-ip6tables` is available on the host."
  4690. type: "boolean"
  4691. example: true
  4692. Debug:
  4693. description: |
  4694. Indicates if the daemon is running in debug-mode / with debug-level
  4695. logging enabled.
  4696. type: "boolean"
  4697. example: true
  4698. NFd:
  4699. description: |
  4700. The total number of file Descriptors in use by the daemon process.
  4701. This information is only returned if debug-mode is enabled.
  4702. type: "integer"
  4703. example: 64
  4704. NGoroutines:
  4705. description: |
  4706. The number of goroutines that currently exist.
  4707. This information is only returned if debug-mode is enabled.
  4708. type: "integer"
  4709. example: 174
  4710. SystemTime:
  4711. description: |
  4712. Current system-time in [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt)
  4713. format with nano-seconds.
  4714. type: "string"
  4715. example: "2017-08-08T20:28:29.06202363Z"
  4716. LoggingDriver:
  4717. description: |
  4718. The logging driver to use as a default for new containers.
  4719. type: "string"
  4720. CgroupDriver:
  4721. description: |
  4722. The driver to use for managing cgroups.
  4723. type: "string"
  4724. enum: ["cgroupfs", "systemd", "none"]
  4725. default: "cgroupfs"
  4726. example: "cgroupfs"
  4727. CgroupVersion:
  4728. description: |
  4729. The version of the cgroup.
  4730. type: "string"
  4731. enum: ["1", "2"]
  4732. default: "1"
  4733. example: "1"
  4734. NEventsListener:
  4735. description: "Number of event listeners subscribed."
  4736. type: "integer"
  4737. example: 30
  4738. KernelVersion:
  4739. description: |
  4740. Kernel version of the host.
  4741. On Linux, this information obtained from `uname`. On Windows this
  4742. information is queried from the <kbd>HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion\\</kbd>
  4743. registry value, for example _"10.0 14393 (14393.1198.amd64fre.rs1_release_sec.170427-1353)"_.
  4744. type: "string"
  4745. example: "4.9.38-moby"
  4746. OperatingSystem:
  4747. description: |
  4748. Name of the host's operating system, for example: "Ubuntu 16.04.2 LTS"
  4749. or "Windows Server 2016 Datacenter"
  4750. type: "string"
  4751. example: "Alpine Linux v3.5"
  4752. OSVersion:
  4753. description: |
  4754. Version of the host's operating system
  4755. <p><br /></p>
  4756. > **Note**: The information returned in this field, including its
  4757. > very existence, and the formatting of values, should not be considered
  4758. > stable, and may change without notice.
  4759. type: "string"
  4760. example: "16.04"
  4761. OSType:
  4762. description: |
  4763. Generic type of the operating system of the host, as returned by the
  4764. Go runtime (`GOOS`).
  4765. Currently returned values are "linux" and "windows". A full list of
  4766. possible values can be found in the [Go documentation](https://go.dev/doc/install/source#environment).
  4767. type: "string"
  4768. example: "linux"
  4769. Architecture:
  4770. description: |
  4771. Hardware architecture of the host, as returned by the Go runtime
  4772. (`GOARCH`).
  4773. A full list of possible values can be found in the [Go documentation](https://go.dev/doc/install/source#environment).
  4774. type: "string"
  4775. example: "x86_64"
  4776. NCPU:
  4777. description: |
  4778. The number of logical CPUs usable by the daemon.
  4779. The number of available CPUs is checked by querying the operating
  4780. system when the daemon starts. Changes to operating system CPU
  4781. allocation after the daemon is started are not reflected.
  4782. type: "integer"
  4783. example: 4
  4784. MemTotal:
  4785. description: |
  4786. Total amount of physical memory available on the host, in bytes.
  4787. type: "integer"
  4788. format: "int64"
  4789. example: 2095882240
  4790. IndexServerAddress:
  4791. description: |
  4792. Address / URL of the index server that is used for image search,
  4793. and as a default for user authentication for Docker Hub and Docker Cloud.
  4794. default: "https://index.docker.io/v1/"
  4795. type: "string"
  4796. example: "https://index.docker.io/v1/"
  4797. RegistryConfig:
  4798. $ref: "#/definitions/RegistryServiceConfig"
  4799. GenericResources:
  4800. $ref: "#/definitions/GenericResources"
  4801. HttpProxy:
  4802. description: |
  4803. HTTP-proxy configured for the daemon. This value is obtained from the
  4804. [`HTTP_PROXY`](https://www.gnu.org/software/wget/manual/html_node/Proxies.html) environment variable.
  4805. Credentials ([user info component](https://tools.ietf.org/html/rfc3986#section-3.2.1)) in the proxy URL
  4806. are masked in the API response.
  4807. Containers do not automatically inherit this configuration.
  4808. type: "string"
  4809. example: "http://xxxxx:xxxxx@proxy.corp.example.com:8080"
  4810. HttpsProxy:
  4811. description: |
  4812. HTTPS-proxy configured for the daemon. This value is obtained from the
  4813. [`HTTPS_PROXY`](https://www.gnu.org/software/wget/manual/html_node/Proxies.html) environment variable.
  4814. Credentials ([user info component](https://tools.ietf.org/html/rfc3986#section-3.2.1)) in the proxy URL
  4815. are masked in the API response.
  4816. Containers do not automatically inherit this configuration.
  4817. type: "string"
  4818. example: "https://xxxxx:xxxxx@proxy.corp.example.com:4443"
  4819. NoProxy:
  4820. description: |
  4821. Comma-separated list of domain extensions for which no proxy should be
  4822. used. This value is obtained from the [`NO_PROXY`](https://www.gnu.org/software/wget/manual/html_node/Proxies.html)
  4823. environment variable.
  4824. Containers do not automatically inherit this configuration.
  4825. type: "string"
  4826. example: "*.local, 169.254/16"
  4827. Name:
  4828. description: "Hostname of the host."
  4829. type: "string"
  4830. example: "node5.corp.example.com"
  4831. Labels:
  4832. description: |
  4833. User-defined labels (key/value metadata) as set on the daemon.
  4834. <p><br /></p>
  4835. > **Note**: When part of a Swarm, nodes can both have _daemon_ labels,
  4836. > set through the daemon configuration, and _node_ labels, set from a
  4837. > manager node in the Swarm. Node labels are not included in this
  4838. > field. Node labels can be retrieved using the `/nodes/(id)` endpoint
  4839. > on a manager node in the Swarm.
  4840. type: "array"
  4841. items:
  4842. type: "string"
  4843. example: ["storage=ssd", "production"]
  4844. ExperimentalBuild:
  4845. description: |
  4846. Indicates if experimental features are enabled on the daemon.
  4847. type: "boolean"
  4848. example: true
  4849. ServerVersion:
  4850. description: |
  4851. Version string of the daemon.
  4852. type: "string"
  4853. example: "20.10.25"
  4854. ClusterStore:
  4855. description: |
  4856. URL of the distributed storage backend.
  4857. The storage backend is used for multihost networking (to store
  4858. network and endpoint information) and by the node discovery mechanism.
  4859. <p><br /></p>
  4860. > **Deprecated**: This field is only propagated when using standalone Swarm
  4861. > mode, and overlay networking using an external k/v store. Overlay
  4862. > networks with Swarm mode enabled use the built-in raft store, and
  4863. > this field will be empty.
  4864. type: "string"
  4865. example: "consul://consul.corp.example.com:8600/some/path"
  4866. ClusterAdvertise:
  4867. description: |
  4868. The network endpoint that the Engine advertises for the purpose of
  4869. node discovery. ClusterAdvertise is a `host:port` combination on which
  4870. the daemon is reachable by other hosts.
  4871. <p><br /></p>
  4872. > **Deprecated**: This field is only propagated when using standalone Swarm
  4873. > mode, and overlay networking using an external k/v store. Overlay
  4874. > networks with Swarm mode enabled use the built-in raft store, and
  4875. > this field will be empty.
  4876. type: "string"
  4877. example: "node5.corp.example.com:8000"
  4878. Runtimes:
  4879. description: |
  4880. List of [OCI compliant](https://github.com/opencontainers/runtime-spec)
  4881. runtimes configured on the daemon. Keys hold the "name" used to
  4882. reference the runtime.
  4883. The Docker daemon relies on an OCI compliant runtime (invoked via the
  4884. `containerd` daemon) as its interface to the Linux kernel namespaces,
  4885. cgroups, and SELinux.
  4886. The default runtime is `runc`, and automatically configured. Additional
  4887. runtimes can be configured by the user and will be listed here.
  4888. type: "object"
  4889. additionalProperties:
  4890. $ref: "#/definitions/Runtime"
  4891. default:
  4892. runc:
  4893. path: "runc"
  4894. example:
  4895. runc:
  4896. path: "runc"
  4897. runc-master:
  4898. path: "/go/bin/runc"
  4899. custom:
  4900. path: "/usr/local/bin/my-oci-runtime"
  4901. runtimeArgs: ["--debug", "--systemd-cgroup=false"]
  4902. DefaultRuntime:
  4903. description: |
  4904. Name of the default OCI runtime that is used when starting containers.
  4905. The default can be overridden per-container at create time.
  4906. type: "string"
  4907. default: "runc"
  4908. example: "runc"
  4909. Swarm:
  4910. $ref: "#/definitions/SwarmInfo"
  4911. LiveRestoreEnabled:
  4912. description: |
  4913. Indicates if live restore is enabled.
  4914. If enabled, containers are kept running when the daemon is shutdown
  4915. or upon daemon start if running containers are detected.
  4916. type: "boolean"
  4917. default: false
  4918. example: false
  4919. Isolation:
  4920. description: |
  4921. Represents the isolation technology to use as a default for containers.
  4922. The supported values are platform-specific.
  4923. If no isolation value is specified on daemon start, on Windows client,
  4924. the default is `hyperv`, and on Windows server, the default is `process`.
  4925. This option is currently not used on other platforms.
  4926. default: "default"
  4927. type: "string"
  4928. enum:
  4929. - "default"
  4930. - "hyperv"
  4931. - "process"
  4932. InitBinary:
  4933. description: |
  4934. Name and, optional, path of the `docker-init` binary.
  4935. If the path is omitted, the daemon searches the host's `$PATH` for the
  4936. binary and uses the first result.
  4937. type: "string"
  4938. example: "docker-init"
  4939. ContainerdCommit:
  4940. $ref: "#/definitions/Commit"
  4941. RuncCommit:
  4942. $ref: "#/definitions/Commit"
  4943. InitCommit:
  4944. $ref: "#/definitions/Commit"
  4945. SecurityOptions:
  4946. description: |
  4947. List of security features that are enabled on the daemon, such as
  4948. apparmor, seccomp, SELinux, user-namespaces (userns), and rootless.
  4949. Additional configuration options for each security feature may
  4950. be present, and are included as a comma-separated list of key/value
  4951. pairs.
  4952. type: "array"
  4953. items:
  4954. type: "string"
  4955. example:
  4956. - "name=apparmor"
  4957. - "name=seccomp,profile=default"
  4958. - "name=selinux"
  4959. - "name=userns"
  4960. - "name=rootless"
  4961. ProductLicense:
  4962. description: |
  4963. Reports a summary of the product license on the daemon.
  4964. If a commercial license has been applied to the daemon, information
  4965. such as number of nodes, and expiration are included.
  4966. type: "string"
  4967. example: "Community Engine"
  4968. DefaultAddressPools:
  4969. description: |
  4970. List of custom default address pools for local networks, which can be
  4971. specified in the daemon.json file or dockerd option.
  4972. Example: a Base "10.10.0.0/16" with Size 24 will define the set of 256
  4973. 10.10.[0-255].0/24 address pools.
  4974. type: "array"
  4975. items:
  4976. type: "object"
  4977. properties:
  4978. Base:
  4979. description: "The network address in CIDR format"
  4980. type: "string"
  4981. example: "10.10.0.0/16"
  4982. Size:
  4983. description: "The network pool size"
  4984. type: "integer"
  4985. example: "24"
  4986. Warnings:
  4987. description: |
  4988. List of warnings / informational messages about missing features, or
  4989. issues related to the daemon configuration.
  4990. These messages can be printed by the client as information to the user.
  4991. type: "array"
  4992. items:
  4993. type: "string"
  4994. example:
  4995. - "WARNING: No memory limit support"
  4996. - "WARNING: bridge-nf-call-iptables is disabled"
  4997. - "WARNING: bridge-nf-call-ip6tables is disabled"
  4998. # PluginsInfo is a temp struct holding Plugins name
  4999. # registered with docker daemon. It is used by Info struct
  5000. PluginsInfo:
  5001. description: |
  5002. Available plugins per type.
  5003. <p><br /></p>
  5004. > **Note**: Only unmanaged (V1) plugins are included in this list.
  5005. > V1 plugins are "lazily" loaded, and are not returned in this list
  5006. > if there is no resource using the plugin.
  5007. type: "object"
  5008. properties:
  5009. Volume:
  5010. description: "Names of available volume-drivers, and network-driver plugins."
  5011. type: "array"
  5012. items:
  5013. type: "string"
  5014. example: ["local"]
  5015. Network:
  5016. description: "Names of available network-drivers, and network-driver plugins."
  5017. type: "array"
  5018. items:
  5019. type: "string"
  5020. example: ["bridge", "host", "ipvlan", "macvlan", "null", "overlay"]
  5021. Authorization:
  5022. description: "Names of available authorization plugins."
  5023. type: "array"
  5024. items:
  5025. type: "string"
  5026. example: ["img-authz-plugin", "hbm"]
  5027. Log:
  5028. description: "Names of available logging-drivers, and logging-driver plugins."
  5029. type: "array"
  5030. items:
  5031. type: "string"
  5032. example: ["awslogs", "fluentd", "gcplogs", "gelf", "journald", "json-file", "splunk", "syslog"]
  5033. RegistryServiceConfig:
  5034. description: |
  5035. RegistryServiceConfig stores daemon registry services configuration.
  5036. type: "object"
  5037. x-nullable: true
  5038. properties:
  5039. AllowNondistributableArtifactsCIDRs:
  5040. description: |
  5041. List of IP ranges to which nondistributable artifacts can be pushed,
  5042. using the CIDR syntax [RFC 4632](https://tools.ietf.org/html/4632).
  5043. Some images (for example, Windows base images) contain artifacts
  5044. whose distribution is restricted by license. When these images are
  5045. pushed to a registry, restricted artifacts are not included.
  5046. This configuration override this behavior, and enables the daemon to
  5047. push nondistributable artifacts to all registries whose resolved IP
  5048. address is within the subnet described by the CIDR syntax.
  5049. This option is useful when pushing images containing
  5050. nondistributable artifacts to a registry on an air-gapped network so
  5051. hosts on that network can pull the images without connecting to
  5052. another server.
  5053. > **Warning**: Nondistributable artifacts typically have restrictions
  5054. > on how and where they can be distributed and shared. Only use this
  5055. > feature to push artifacts to private registries and ensure that you
  5056. > are in compliance with any terms that cover redistributing
  5057. > nondistributable artifacts.
  5058. type: "array"
  5059. items:
  5060. type: "string"
  5061. example: ["::1/128", "127.0.0.0/8"]
  5062. AllowNondistributableArtifactsHostnames:
  5063. description: |
  5064. List of registry hostnames to which nondistributable artifacts can be
  5065. pushed, using the format `<hostname>[:<port>]` or `<IP address>[:<port>]`.
  5066. Some images (for example, Windows base images) contain artifacts
  5067. whose distribution is restricted by license. When these images are
  5068. pushed to a registry, restricted artifacts are not included.
  5069. This configuration override this behavior for the specified
  5070. registries.
  5071. This option is useful when pushing images containing
  5072. nondistributable artifacts to a registry on an air-gapped network so
  5073. hosts on that network can pull the images without connecting to
  5074. another server.
  5075. > **Warning**: Nondistributable artifacts typically have restrictions
  5076. > on how and where they can be distributed and shared. Only use this
  5077. > feature to push artifacts to private registries and ensure that you
  5078. > are in compliance with any terms that cover redistributing
  5079. > nondistributable artifacts.
  5080. type: "array"
  5081. items:
  5082. type: "string"
  5083. example: ["registry.internal.corp.example.com:3000", "[2001:db8:a0b:12f0::1]:443"]
  5084. InsecureRegistryCIDRs:
  5085. description: |
  5086. List of IP ranges of insecure registries, using the CIDR syntax
  5087. ([RFC 4632](https://tools.ietf.org/html/4632)). Insecure registries
  5088. accept un-encrypted (HTTP) and/or untrusted (HTTPS with certificates
  5089. from unknown CAs) communication.
  5090. By default, local registries (`127.0.0.0/8`) are configured as
  5091. insecure. All other registries are secure. Communicating with an
  5092. insecure registry is not possible if the daemon assumes that registry
  5093. is secure.
  5094. This configuration override this behavior, insecure communication with
  5095. registries whose resolved IP address is within the subnet described by
  5096. the CIDR syntax.
  5097. Registries can also be marked insecure by hostname. Those registries
  5098. are listed under `IndexConfigs` and have their `Secure` field set to
  5099. `false`.
  5100. > **Warning**: Using this option can be useful when running a local
  5101. > registry, but introduces security vulnerabilities. This option
  5102. > should therefore ONLY be used for testing purposes. For increased
  5103. > security, users should add their CA to their system's list of trusted
  5104. > CAs instead of enabling this option.
  5105. type: "array"
  5106. items:
  5107. type: "string"
  5108. example: ["::1/128", "127.0.0.0/8"]
  5109. IndexConfigs:
  5110. type: "object"
  5111. additionalProperties:
  5112. $ref: "#/definitions/IndexInfo"
  5113. example:
  5114. "127.0.0.1:5000":
  5115. "Name": "127.0.0.1:5000"
  5116. "Mirrors": []
  5117. "Secure": false
  5118. "Official": false
  5119. "[2001:db8:a0b:12f0::1]:80":
  5120. "Name": "[2001:db8:a0b:12f0::1]:80"
  5121. "Mirrors": []
  5122. "Secure": false
  5123. "Official": false
  5124. "docker.io":
  5125. Name: "docker.io"
  5126. Mirrors: ["https://hub-mirror.corp.example.com:5000/"]
  5127. Secure: true
  5128. Official: true
  5129. "registry.internal.corp.example.com:3000":
  5130. Name: "registry.internal.corp.example.com:3000"
  5131. Mirrors: []
  5132. Secure: false
  5133. Official: false
  5134. Mirrors:
  5135. description: |
  5136. List of registry URLs that act as a mirror for the official
  5137. (`docker.io`) registry.
  5138. type: "array"
  5139. items:
  5140. type: "string"
  5141. example:
  5142. - "https://hub-mirror.corp.example.com:5000/"
  5143. - "https://[2001:db8:a0b:12f0::1]/"
  5144. IndexInfo:
  5145. description:
  5146. IndexInfo contains information about a registry.
  5147. type: "object"
  5148. x-nullable: true
  5149. properties:
  5150. Name:
  5151. description: |
  5152. Name of the registry, such as "docker.io".
  5153. type: "string"
  5154. example: "docker.io"
  5155. Mirrors:
  5156. description: |
  5157. List of mirrors, expressed as URIs.
  5158. type: "array"
  5159. items:
  5160. type: "string"
  5161. example:
  5162. - "https://hub-mirror.corp.example.com:5000/"
  5163. - "https://registry-2.docker.io/"
  5164. - "https://registry-3.docker.io/"
  5165. Secure:
  5166. description: |
  5167. Indicates if the registry is part of the list of insecure
  5168. registries.
  5169. If `false`, the registry is insecure. Insecure registries accept
  5170. un-encrypted (HTTP) and/or untrusted (HTTPS with certificates from
  5171. unknown CAs) communication.
  5172. > **Warning**: Insecure registries can be useful when running a local
  5173. > registry. However, because its use creates security vulnerabilities
  5174. > it should ONLY be enabled for testing purposes. For increased
  5175. > security, users should add their CA to their system's list of
  5176. > trusted CAs instead of enabling this option.
  5177. type: "boolean"
  5178. example: true
  5179. Official:
  5180. description: |
  5181. Indicates whether this is an official registry (i.e., Docker Hub / docker.io)
  5182. type: "boolean"
  5183. example: true
  5184. Runtime:
  5185. description: |
  5186. Runtime describes an [OCI compliant](https://github.com/opencontainers/runtime-spec)
  5187. runtime.
  5188. The runtime is invoked by the daemon via the `containerd` daemon. OCI
  5189. runtimes act as an interface to the Linux kernel namespaces, cgroups,
  5190. and SELinux.
  5191. type: "object"
  5192. properties:
  5193. path:
  5194. description: |
  5195. Name and, optional, path, of the OCI executable binary.
  5196. If the path is omitted, the daemon searches the host's `$PATH` for the
  5197. binary and uses the first result.
  5198. type: "string"
  5199. example: "/usr/local/bin/my-oci-runtime"
  5200. runtimeArgs:
  5201. description: |
  5202. List of command-line arguments to pass to the runtime when invoked.
  5203. type: "array"
  5204. x-nullable: true
  5205. items:
  5206. type: "string"
  5207. example: ["--debug", "--systemd-cgroup=false"]
  5208. Commit:
  5209. description: |
  5210. Commit holds the Git-commit (SHA1) that a binary was built from, as
  5211. reported in the version-string of external tools, such as `containerd`,
  5212. or `runC`.
  5213. type: "object"
  5214. properties:
  5215. ID:
  5216. description: "Actual commit ID of external tool."
  5217. type: "string"
  5218. example: "cfb82a876ecc11b5ca0977d1733adbe58599088a"
  5219. Expected:
  5220. description: |
  5221. Commit ID of external tool expected by dockerd as set at build time.
  5222. type: "string"
  5223. example: "2d41c047c83e09a6d61d464906feb2a2f3c52aa4"
  5224. SwarmInfo:
  5225. description: |
  5226. Represents generic information about swarm.
  5227. type: "object"
  5228. properties:
  5229. NodeID:
  5230. description: "Unique identifier of for this node in the swarm."
  5231. type: "string"
  5232. default: ""
  5233. example: "k67qz4598weg5unwwffg6z1m1"
  5234. NodeAddr:
  5235. description: |
  5236. IP address at which this node can be reached by other nodes in the
  5237. swarm.
  5238. type: "string"
  5239. default: ""
  5240. example: "10.0.0.46"
  5241. LocalNodeState:
  5242. $ref: "#/definitions/LocalNodeState"
  5243. ControlAvailable:
  5244. type: "boolean"
  5245. default: false
  5246. example: true
  5247. Error:
  5248. type: "string"
  5249. default: ""
  5250. RemoteManagers:
  5251. description: |
  5252. List of ID's and addresses of other managers in the swarm.
  5253. type: "array"
  5254. default: null
  5255. x-nullable: true
  5256. items:
  5257. $ref: "#/definitions/PeerNode"
  5258. example:
  5259. - NodeID: "71izy0goik036k48jg985xnds"
  5260. Addr: "10.0.0.158:2377"
  5261. - NodeID: "79y6h1o4gv8n120drcprv5nmc"
  5262. Addr: "10.0.0.159:2377"
  5263. - NodeID: "k67qz4598weg5unwwffg6z1m1"
  5264. Addr: "10.0.0.46:2377"
  5265. Nodes:
  5266. description: "Total number of nodes in the swarm."
  5267. type: "integer"
  5268. x-nullable: true
  5269. example: 4
  5270. Managers:
  5271. description: "Total number of managers in the swarm."
  5272. type: "integer"
  5273. x-nullable: true
  5274. example: 3
  5275. Cluster:
  5276. $ref: "#/definitions/ClusterInfo"
  5277. LocalNodeState:
  5278. description: "Current local status of this node."
  5279. type: "string"
  5280. default: ""
  5281. enum:
  5282. - ""
  5283. - "inactive"
  5284. - "pending"
  5285. - "active"
  5286. - "error"
  5287. - "locked"
  5288. example: "active"
  5289. PeerNode:
  5290. description: "Represents a peer-node in the swarm"
  5291. type: "object"
  5292. properties:
  5293. NodeID:
  5294. description: "Unique identifier of for this node in the swarm."
  5295. type: "string"
  5296. Addr:
  5297. description: |
  5298. IP address and ports at which this node can be reached.
  5299. type: "string"
  5300. NetworkAttachmentConfig:
  5301. description: |
  5302. Specifies how a service should be attached to a particular network.
  5303. type: "object"
  5304. properties:
  5305. Target:
  5306. description: |
  5307. The target network for attachment. Must be a network name or ID.
  5308. type: "string"
  5309. Aliases:
  5310. description: |
  5311. Discoverable alternate names for the service on this network.
  5312. type: "array"
  5313. items:
  5314. type: "string"
  5315. DriverOpts:
  5316. description: |
  5317. Driver attachment options for the network target.
  5318. type: "object"
  5319. additionalProperties:
  5320. type: "string"
  5321. EventActor:
  5322. description: |
  5323. Actor describes something that generates events, like a container, network,
  5324. or a volume.
  5325. type: "object"
  5326. properties:
  5327. ID:
  5328. description: "The ID of the object emitting the event"
  5329. type: "string"
  5330. example: "ede54ee1afda366ab42f824e8a5ffd195155d853ceaec74a927f249ea270c743"
  5331. Attributes:
  5332. description: |
  5333. Various key/value attributes of the object, depending on its type.
  5334. type: "object"
  5335. additionalProperties:
  5336. type: "string"
  5337. example:
  5338. com.example.some-label: "some-label-value"
  5339. image: "alpine:latest"
  5340. name: "my-container"
  5341. EventMessage:
  5342. description: |
  5343. EventMessage represents the information an event contains.
  5344. type: "object"
  5345. title: "SystemEventsResponse"
  5346. properties:
  5347. Type:
  5348. description: "The type of object emitting the event"
  5349. type: "string"
  5350. enum: ["builder", "config", "container", "daemon", "image", "network", "node", "plugin", "secret", "service", "volume"]
  5351. example: "container"
  5352. Action:
  5353. description: "The type of event"
  5354. type: "string"
  5355. example: "create"
  5356. Actor:
  5357. $ref: "#/definitions/EventActor"
  5358. scope:
  5359. description: |
  5360. Scope of the event. Engine events are `local` scope. Cluster (Swarm)
  5361. events are `swarm` scope.
  5362. type: "string"
  5363. enum: ["local", "swarm"]
  5364. time:
  5365. description: "Timestamp of event"
  5366. type: "integer"
  5367. format: "int64"
  5368. example: 1629574695
  5369. timeNano:
  5370. description: "Timestamp of event, with nanosecond accuracy"
  5371. type: "integer"
  5372. format: "int64"
  5373. example: 1629574695515050031
  5374. OCIDescriptor:
  5375. type: "object"
  5376. x-go-name: Descriptor
  5377. description: |
  5378. A descriptor struct containing digest, media type, and size, as defined in
  5379. the [OCI Content Descriptors Specification](https://github.com/opencontainers/image-spec/blob/v1.0.1/descriptor.md).
  5380. properties:
  5381. mediaType:
  5382. description: |
  5383. The media type of the object this schema refers to.
  5384. type: "string"
  5385. example: "application/vnd.docker.distribution.manifest.v2+json"
  5386. digest:
  5387. description: |
  5388. The digest of the targeted content.
  5389. type: "string"
  5390. example: "sha256:c0537ff6a5218ef531ece93d4984efc99bbf3f7497c0a7726c88e2bb7584dc96"
  5391. size:
  5392. description: |
  5393. The size in bytes of the blob.
  5394. type: "integer"
  5395. format: "int64"
  5396. example: 3987495
  5397. # TODO Not yet including these fields for now, as they are nil / omitted in our response.
  5398. # urls:
  5399. # description: |
  5400. # List of URLs from which this object MAY be downloaded.
  5401. # type: "array"
  5402. # items:
  5403. # type: "string"
  5404. # format: "uri"
  5405. # annotations:
  5406. # description: |
  5407. # Arbitrary metadata relating to the targeted content.
  5408. # type: "object"
  5409. # additionalProperties:
  5410. # type: "string"
  5411. # platform:
  5412. # $ref: "#/definitions/OCIPlatform"
  5413. OCIPlatform:
  5414. type: "object"
  5415. x-go-name: Platform
  5416. description: |
  5417. Describes the platform which the image in the manifest runs on, as defined
  5418. in the [OCI Image Index Specification](https://github.com/opencontainers/image-spec/blob/v1.0.1/image-index.md).
  5419. properties:
  5420. architecture:
  5421. description: |
  5422. The CPU architecture, for example `amd64` or `ppc64`.
  5423. type: "string"
  5424. example: "arm"
  5425. os:
  5426. description: |
  5427. The operating system, for example `linux` or `windows`.
  5428. type: "string"
  5429. example: "windows"
  5430. os.version:
  5431. description: |
  5432. Optional field specifying the operating system version, for example on
  5433. Windows `10.0.19041.1165`.
  5434. type: "string"
  5435. example: "10.0.19041.1165"
  5436. os.features:
  5437. description: |
  5438. Optional field specifying an array of strings, each listing a required
  5439. OS feature (for example on Windows `win32k`).
  5440. type: "array"
  5441. items:
  5442. type: "string"
  5443. example:
  5444. - "win32k"
  5445. variant:
  5446. description: |
  5447. Optional field specifying a variant of the CPU, for example `v7` to
  5448. specify ARMv7 when architecture is `arm`.
  5449. type: "string"
  5450. example: "v7"
  5451. DistributionInspect:
  5452. type: "object"
  5453. x-go-name: DistributionInspect
  5454. title: "DistributionInspectResponse"
  5455. required: [Descriptor, Platforms]
  5456. description: |
  5457. Describes the result obtained from contacting the registry to retrieve
  5458. image metadata.
  5459. properties:
  5460. Descriptor:
  5461. $ref: "#/definitions/OCIDescriptor"
  5462. Platforms:
  5463. type: "array"
  5464. description: |
  5465. An array containing all platforms supported by the image.
  5466. items:
  5467. $ref: "#/definitions/OCIPlatform"
  5468. paths:
  5469. /containers/json:
  5470. get:
  5471. summary: "List containers"
  5472. description: |
  5473. Returns a list of containers. For details on the format, see the
  5474. [inspect endpoint](#operation/ContainerInspect).
  5475. Note that it uses a different, smaller representation of a container
  5476. than inspecting a single container. For example, the list of linked
  5477. containers is not propagated .
  5478. operationId: "ContainerList"
  5479. produces:
  5480. - "application/json"
  5481. parameters:
  5482. - name: "all"
  5483. in: "query"
  5484. description: |
  5485. Return all containers. By default, only running containers are shown.
  5486. type: "boolean"
  5487. default: false
  5488. - name: "limit"
  5489. in: "query"
  5490. description: |
  5491. Return this number of most recently created containers, including
  5492. non-running ones.
  5493. type: "integer"
  5494. - name: "size"
  5495. in: "query"
  5496. description: |
  5497. Return the size of container as fields `SizeRw` and `SizeRootFs`.
  5498. type: "boolean"
  5499. default: false
  5500. - name: "filters"
  5501. in: "query"
  5502. description: |
  5503. Filters to process on the container list, encoded as JSON (a
  5504. `map[string][]string`). For example, `{"status": ["paused"]}` will
  5505. only return paused containers.
  5506. Available filters:
  5507. - `ancestor`=(`<image-name>[:<tag>]`, `<image id>`, or `<image@digest>`)
  5508. - `before`=(`<container id>` or `<container name>`)
  5509. - `expose`=(`<port>[/<proto>]`|`<startport-endport>/[<proto>]`)
  5510. - `exited=<int>` containers with exit code of `<int>`
  5511. - `health`=(`starting`|`healthy`|`unhealthy`|`none`)
  5512. - `id=<ID>` a container's ID
  5513. - `isolation=`(`default`|`process`|`hyperv`) (Windows daemon only)
  5514. - `is-task=`(`true`|`false`)
  5515. - `label=key` or `label="key=value"` of a container label
  5516. - `name=<name>` a container's name
  5517. - `network`=(`<network id>` or `<network name>`)
  5518. - `publish`=(`<port>[/<proto>]`|`<startport-endport>/[<proto>]`)
  5519. - `since`=(`<container id>` or `<container name>`)
  5520. - `status=`(`created`|`restarting`|`running`|`removing`|`paused`|`exited`|`dead`)
  5521. - `volume`=(`<volume name>` or `<mount point destination>`)
  5522. type: "string"
  5523. responses:
  5524. 200:
  5525. description: "no error"
  5526. schema:
  5527. type: "array"
  5528. items:
  5529. $ref: "#/definitions/ContainerSummary"
  5530. examples:
  5531. application/json:
  5532. - Id: "8dfafdbc3a40"
  5533. Names:
  5534. - "/boring_feynman"
  5535. Image: "ubuntu:latest"
  5536. ImageID: "d74508fb6632491cea586a1fd7d748dfc5274cd6fdfedee309ecdcbc2bf5cb82"
  5537. Command: "echo 1"
  5538. Created: 1367854155
  5539. State: "Exited"
  5540. Status: "Exit 0"
  5541. Ports:
  5542. - PrivatePort: 2222
  5543. PublicPort: 3333
  5544. Type: "tcp"
  5545. Labels:
  5546. com.example.vendor: "Acme"
  5547. com.example.license: "GPL"
  5548. com.example.version: "1.0"
  5549. SizeRw: 12288
  5550. SizeRootFs: 0
  5551. HostConfig:
  5552. NetworkMode: "default"
  5553. NetworkSettings:
  5554. Networks:
  5555. bridge:
  5556. NetworkID: "7ea29fc1412292a2d7bba362f9253545fecdfa8ce9a6e37dd10ba8bee7129812"
  5557. EndpointID: "2cdc4edb1ded3631c81f57966563e5c8525b81121bb3706a9a9a3ae102711f3f"
  5558. Gateway: "172.17.0.1"
  5559. IPAddress: "172.17.0.2"
  5560. IPPrefixLen: 16
  5561. IPv6Gateway: ""
  5562. GlobalIPv6Address: ""
  5563. GlobalIPv6PrefixLen: 0
  5564. MacAddress: "02:42:ac:11:00:02"
  5565. Mounts:
  5566. - Name: "fac362...80535"
  5567. Source: "/data"
  5568. Destination: "/data"
  5569. Driver: "local"
  5570. Mode: "ro,Z"
  5571. RW: false
  5572. Propagation: ""
  5573. - Id: "9cd87474be90"
  5574. Names:
  5575. - "/coolName"
  5576. Image: "ubuntu:latest"
  5577. ImageID: "d74508fb6632491cea586a1fd7d748dfc5274cd6fdfedee309ecdcbc2bf5cb82"
  5578. Command: "echo 222222"
  5579. Created: 1367854155
  5580. State: "Exited"
  5581. Status: "Exit 0"
  5582. Ports: []
  5583. Labels: {}
  5584. SizeRw: 12288
  5585. SizeRootFs: 0
  5586. HostConfig:
  5587. NetworkMode: "default"
  5588. NetworkSettings:
  5589. Networks:
  5590. bridge:
  5591. NetworkID: "7ea29fc1412292a2d7bba362f9253545fecdfa8ce9a6e37dd10ba8bee7129812"
  5592. EndpointID: "88eaed7b37b38c2a3f0c4bc796494fdf51b270c2d22656412a2ca5d559a64d7a"
  5593. Gateway: "172.17.0.1"
  5594. IPAddress: "172.17.0.8"
  5595. IPPrefixLen: 16
  5596. IPv6Gateway: ""
  5597. GlobalIPv6Address: ""
  5598. GlobalIPv6PrefixLen: 0
  5599. MacAddress: "02:42:ac:11:00:08"
  5600. Mounts: []
  5601. - Id: "3176a2479c92"
  5602. Names:
  5603. - "/sleepy_dog"
  5604. Image: "ubuntu:latest"
  5605. ImageID: "d74508fb6632491cea586a1fd7d748dfc5274cd6fdfedee309ecdcbc2bf5cb82"
  5606. Command: "echo 3333333333333333"
  5607. Created: 1367854154
  5608. State: "Exited"
  5609. Status: "Exit 0"
  5610. Ports: []
  5611. Labels: {}
  5612. SizeRw: 12288
  5613. SizeRootFs: 0
  5614. HostConfig:
  5615. NetworkMode: "default"
  5616. NetworkSettings:
  5617. Networks:
  5618. bridge:
  5619. NetworkID: "7ea29fc1412292a2d7bba362f9253545fecdfa8ce9a6e37dd10ba8bee7129812"
  5620. EndpointID: "8b27c041c30326d59cd6e6f510d4f8d1d570a228466f956edf7815508f78e30d"
  5621. Gateway: "172.17.0.1"
  5622. IPAddress: "172.17.0.6"
  5623. IPPrefixLen: 16
  5624. IPv6Gateway: ""
  5625. GlobalIPv6Address: ""
  5626. GlobalIPv6PrefixLen: 0
  5627. MacAddress: "02:42:ac:11:00:06"
  5628. Mounts: []
  5629. - Id: "4cb07b47f9fb"
  5630. Names:
  5631. - "/running_cat"
  5632. Image: "ubuntu:latest"
  5633. ImageID: "d74508fb6632491cea586a1fd7d748dfc5274cd6fdfedee309ecdcbc2bf5cb82"
  5634. Command: "echo 444444444444444444444444444444444"
  5635. Created: 1367854152
  5636. State: "Exited"
  5637. Status: "Exit 0"
  5638. Ports: []
  5639. Labels: {}
  5640. SizeRw: 12288
  5641. SizeRootFs: 0
  5642. HostConfig:
  5643. NetworkMode: "default"
  5644. NetworkSettings:
  5645. Networks:
  5646. bridge:
  5647. NetworkID: "7ea29fc1412292a2d7bba362f9253545fecdfa8ce9a6e37dd10ba8bee7129812"
  5648. EndpointID: "d91c7b2f0644403d7ef3095985ea0e2370325cd2332ff3a3225c4247328e66e9"
  5649. Gateway: "172.17.0.1"
  5650. IPAddress: "172.17.0.5"
  5651. IPPrefixLen: 16
  5652. IPv6Gateway: ""
  5653. GlobalIPv6Address: ""
  5654. GlobalIPv6PrefixLen: 0
  5655. MacAddress: "02:42:ac:11:00:05"
  5656. Mounts: []
  5657. 400:
  5658. description: "bad parameter"
  5659. schema:
  5660. $ref: "#/definitions/ErrorResponse"
  5661. 500:
  5662. description: "server error"
  5663. schema:
  5664. $ref: "#/definitions/ErrorResponse"
  5665. tags: ["Container"]
  5666. /containers/create:
  5667. post:
  5668. summary: "Create a container"
  5669. operationId: "ContainerCreate"
  5670. consumes:
  5671. - "application/json"
  5672. - "application/octet-stream"
  5673. produces:
  5674. - "application/json"
  5675. parameters:
  5676. - name: "name"
  5677. in: "query"
  5678. description: |
  5679. Assign the specified name to the container. Must match
  5680. `/?[a-zA-Z0-9][a-zA-Z0-9_.-]+`.
  5681. type: "string"
  5682. pattern: "^/?[a-zA-Z0-9][a-zA-Z0-9_.-]+$"
  5683. - name: "platform"
  5684. in: "query"
  5685. description: |
  5686. Platform in the format `os[/arch[/variant]]` used for image lookup.
  5687. When specified, the daemon checks if the requested image is present
  5688. in the local image cache with the given OS and Architecture, and
  5689. otherwise returns a `404` status.
  5690. If the option is not set, the host's native OS and Architecture are
  5691. used to look up the image in the image cache. However, if no platform
  5692. is passed and the given image does exist in the local image cache,
  5693. but its OS or architecture does not match, the container is created
  5694. with the available image, and a warning is added to the `Warnings`
  5695. field in the response, for example;
  5696. WARNING: The requested image's platform (linux/arm64/v8) does not
  5697. match the detected host platform (linux/amd64) and no
  5698. specific platform was requested
  5699. type: "string"
  5700. default: ""
  5701. - name: "body"
  5702. in: "body"
  5703. description: "Container to create"
  5704. schema:
  5705. allOf:
  5706. - $ref: "#/definitions/ContainerConfig"
  5707. - type: "object"
  5708. properties:
  5709. HostConfig:
  5710. $ref: "#/definitions/HostConfig"
  5711. NetworkingConfig:
  5712. $ref: "#/definitions/NetworkingConfig"
  5713. example:
  5714. Hostname: ""
  5715. Domainname: ""
  5716. User: ""
  5717. AttachStdin: false
  5718. AttachStdout: true
  5719. AttachStderr: true
  5720. Tty: false
  5721. OpenStdin: false
  5722. StdinOnce: false
  5723. Env:
  5724. - "FOO=bar"
  5725. - "BAZ=quux"
  5726. Cmd:
  5727. - "date"
  5728. Entrypoint: ""
  5729. Image: "ubuntu"
  5730. Labels:
  5731. com.example.vendor: "Acme"
  5732. com.example.license: "GPL"
  5733. com.example.version: "1.0"
  5734. Volumes:
  5735. /volumes/data: {}
  5736. WorkingDir: ""
  5737. NetworkDisabled: false
  5738. MacAddress: "12:34:56:78:9a:bc"
  5739. ExposedPorts:
  5740. 22/tcp: {}
  5741. StopSignal: "SIGTERM"
  5742. StopTimeout: 10
  5743. HostConfig:
  5744. Binds:
  5745. - "/tmp:/tmp"
  5746. Links:
  5747. - "redis3:redis"
  5748. Memory: 0
  5749. MemorySwap: 0
  5750. MemoryReservation: 0
  5751. KernelMemory: 0
  5752. NanoCpus: 500000
  5753. CpuPercent: 80
  5754. CpuShares: 512
  5755. CpuPeriod: 100000
  5756. CpuRealtimePeriod: 1000000
  5757. CpuRealtimeRuntime: 10000
  5758. CpuQuota: 50000
  5759. CpusetCpus: "0,1"
  5760. CpusetMems: "0,1"
  5761. MaximumIOps: 0
  5762. MaximumIOBps: 0
  5763. BlkioWeight: 300
  5764. BlkioWeightDevice:
  5765. - {}
  5766. BlkioDeviceReadBps:
  5767. - {}
  5768. BlkioDeviceReadIOps:
  5769. - {}
  5770. BlkioDeviceWriteBps:
  5771. - {}
  5772. BlkioDeviceWriteIOps:
  5773. - {}
  5774. DeviceRequests:
  5775. - Driver: "nvidia"
  5776. Count: -1
  5777. DeviceIDs": ["0", "1", "GPU-fef8089b-4820-abfc-e83e-94318197576e"]
  5778. Capabilities: [["gpu", "nvidia", "compute"]]
  5779. Options:
  5780. property1: "string"
  5781. property2: "string"
  5782. MemorySwappiness: 60
  5783. OomKillDisable: false
  5784. OomScoreAdj: 500
  5785. PidMode: ""
  5786. PidsLimit: 0
  5787. PortBindings:
  5788. 22/tcp:
  5789. - HostPort: "11022"
  5790. PublishAllPorts: false
  5791. Privileged: false
  5792. ReadonlyRootfs: false
  5793. Dns:
  5794. - "8.8.8.8"
  5795. DnsOptions:
  5796. - ""
  5797. DnsSearch:
  5798. - ""
  5799. VolumesFrom:
  5800. - "parent"
  5801. - "other:ro"
  5802. CapAdd:
  5803. - "NET_ADMIN"
  5804. CapDrop:
  5805. - "MKNOD"
  5806. GroupAdd:
  5807. - "newgroup"
  5808. RestartPolicy:
  5809. Name: ""
  5810. MaximumRetryCount: 0
  5811. AutoRemove: true
  5812. NetworkMode: "bridge"
  5813. Devices: []
  5814. Ulimits:
  5815. - {}
  5816. LogConfig:
  5817. Type: "json-file"
  5818. Config: {}
  5819. SecurityOpt: []
  5820. StorageOpt: {}
  5821. CgroupParent: ""
  5822. VolumeDriver: ""
  5823. ShmSize: 67108864
  5824. NetworkingConfig:
  5825. EndpointsConfig:
  5826. isolated_nw:
  5827. IPAMConfig:
  5828. IPv4Address: "172.20.30.33"
  5829. IPv6Address: "2001:db8:abcd::3033"
  5830. LinkLocalIPs:
  5831. - "169.254.34.68"
  5832. - "fe80::3468"
  5833. Links:
  5834. - "container_1"
  5835. - "container_2"
  5836. Aliases:
  5837. - "server_x"
  5838. - "server_y"
  5839. required: true
  5840. responses:
  5841. 201:
  5842. description: "Container created successfully"
  5843. schema:
  5844. type: "object"
  5845. title: "ContainerCreateResponse"
  5846. description: "OK response to ContainerCreate operation"
  5847. required: [Id, Warnings]
  5848. properties:
  5849. Id:
  5850. description: "The ID of the created container"
  5851. type: "string"
  5852. x-nullable: false
  5853. Warnings:
  5854. description: "Warnings encountered when creating the container"
  5855. type: "array"
  5856. x-nullable: false
  5857. items:
  5858. type: "string"
  5859. examples:
  5860. application/json:
  5861. Id: "e90e34656806"
  5862. Warnings: []
  5863. 400:
  5864. description: "bad parameter"
  5865. schema:
  5866. $ref: "#/definitions/ErrorResponse"
  5867. 404:
  5868. description: "no such image"
  5869. schema:
  5870. $ref: "#/definitions/ErrorResponse"
  5871. examples:
  5872. application/json:
  5873. message: "No such image: c2ada9df5af8"
  5874. 409:
  5875. description: "conflict"
  5876. schema:
  5877. $ref: "#/definitions/ErrorResponse"
  5878. 500:
  5879. description: "server error"
  5880. schema:
  5881. $ref: "#/definitions/ErrorResponse"
  5882. tags: ["Container"]
  5883. /containers/{id}/json:
  5884. get:
  5885. summary: "Inspect a container"
  5886. description: "Return low-level information about a container."
  5887. operationId: "ContainerInspect"
  5888. produces:
  5889. - "application/json"
  5890. responses:
  5891. 200:
  5892. description: "no error"
  5893. schema:
  5894. type: "object"
  5895. title: "ContainerInspectResponse"
  5896. properties:
  5897. Id:
  5898. description: "The ID of the container"
  5899. type: "string"
  5900. Created:
  5901. description: "The time the container was created"
  5902. type: "string"
  5903. Path:
  5904. description: "The path to the command being run"
  5905. type: "string"
  5906. Args:
  5907. description: "The arguments to the command being run"
  5908. type: "array"
  5909. items:
  5910. type: "string"
  5911. State:
  5912. $ref: "#/definitions/ContainerState"
  5913. Image:
  5914. description: "The container's image ID"
  5915. type: "string"
  5916. ResolvConfPath:
  5917. type: "string"
  5918. HostnamePath:
  5919. type: "string"
  5920. HostsPath:
  5921. type: "string"
  5922. LogPath:
  5923. type: "string"
  5924. Name:
  5925. type: "string"
  5926. RestartCount:
  5927. type: "integer"
  5928. Driver:
  5929. type: "string"
  5930. Platform:
  5931. type: "string"
  5932. MountLabel:
  5933. type: "string"
  5934. ProcessLabel:
  5935. type: "string"
  5936. AppArmorProfile:
  5937. type: "string"
  5938. ExecIDs:
  5939. description: "IDs of exec instances that are running in the container."
  5940. type: "array"
  5941. items:
  5942. type: "string"
  5943. x-nullable: true
  5944. HostConfig:
  5945. $ref: "#/definitions/HostConfig"
  5946. GraphDriver:
  5947. $ref: "#/definitions/GraphDriverData"
  5948. SizeRw:
  5949. description: |
  5950. The size of files that have been created or changed by this
  5951. container.
  5952. type: "integer"
  5953. format: "int64"
  5954. SizeRootFs:
  5955. description: "The total size of all the files in this container."
  5956. type: "integer"
  5957. format: "int64"
  5958. Mounts:
  5959. type: "array"
  5960. items:
  5961. $ref: "#/definitions/MountPoint"
  5962. Config:
  5963. $ref: "#/definitions/ContainerConfig"
  5964. NetworkSettings:
  5965. $ref: "#/definitions/NetworkSettings"
  5966. examples:
  5967. application/json:
  5968. AppArmorProfile: ""
  5969. Args:
  5970. - "-c"
  5971. - "exit 9"
  5972. Config:
  5973. AttachStderr: true
  5974. AttachStdin: false
  5975. AttachStdout: true
  5976. Cmd:
  5977. - "/bin/sh"
  5978. - "-c"
  5979. - "exit 9"
  5980. Domainname: ""
  5981. Env:
  5982. - "PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
  5983. Healthcheck:
  5984. Test: ["CMD-SHELL", "exit 0"]
  5985. Hostname: "ba033ac44011"
  5986. Image: "ubuntu"
  5987. Labels:
  5988. com.example.vendor: "Acme"
  5989. com.example.license: "GPL"
  5990. com.example.version: "1.0"
  5991. MacAddress: ""
  5992. NetworkDisabled: false
  5993. OpenStdin: false
  5994. StdinOnce: false
  5995. Tty: false
  5996. User: ""
  5997. Volumes:
  5998. /volumes/data: {}
  5999. WorkingDir: ""
  6000. StopSignal: "SIGTERM"
  6001. StopTimeout: 10
  6002. Created: "2015-01-06T15:47:31.485331387Z"
  6003. Driver: "overlay2"
  6004. ExecIDs:
  6005. - "b35395de42bc8abd327f9dd65d913b9ba28c74d2f0734eeeae84fa1c616a0fca"
  6006. - "3fc1232e5cd20c8de182ed81178503dc6437f4e7ef12b52cc5e8de020652f1c4"
  6007. HostConfig:
  6008. MaximumIOps: 0
  6009. MaximumIOBps: 0
  6010. BlkioWeight: 0
  6011. BlkioWeightDevice:
  6012. - {}
  6013. BlkioDeviceReadBps:
  6014. - {}
  6015. BlkioDeviceWriteBps:
  6016. - {}
  6017. BlkioDeviceReadIOps:
  6018. - {}
  6019. BlkioDeviceWriteIOps:
  6020. - {}
  6021. ContainerIDFile: ""
  6022. CpusetCpus: ""
  6023. CpusetMems: ""
  6024. CpuPercent: 80
  6025. CpuShares: 0
  6026. CpuPeriod: 100000
  6027. CpuRealtimePeriod: 1000000
  6028. CpuRealtimeRuntime: 10000
  6029. Devices: []
  6030. DeviceRequests:
  6031. - Driver: "nvidia"
  6032. Count: -1
  6033. DeviceIDs": ["0", "1", "GPU-fef8089b-4820-abfc-e83e-94318197576e"]
  6034. Capabilities: [["gpu", "nvidia", "compute"]]
  6035. Options:
  6036. property1: "string"
  6037. property2: "string"
  6038. IpcMode: ""
  6039. Memory: 0
  6040. MemorySwap: 0
  6041. MemoryReservation: 0
  6042. KernelMemory: 0
  6043. OomKillDisable: false
  6044. OomScoreAdj: 500
  6045. NetworkMode: "bridge"
  6046. PidMode: ""
  6047. PortBindings: {}
  6048. Privileged: false
  6049. ReadonlyRootfs: false
  6050. PublishAllPorts: false
  6051. RestartPolicy:
  6052. MaximumRetryCount: 2
  6053. Name: "on-failure"
  6054. LogConfig:
  6055. Type: "json-file"
  6056. Sysctls:
  6057. net.ipv4.ip_forward: "1"
  6058. Ulimits:
  6059. - {}
  6060. VolumeDriver: ""
  6061. ShmSize: 67108864
  6062. HostnamePath: "/var/lib/docker/containers/ba033ac4401106a3b513bc9d639eee123ad78ca3616b921167cd74b20e25ed39/hostname"
  6063. HostsPath: "/var/lib/docker/containers/ba033ac4401106a3b513bc9d639eee123ad78ca3616b921167cd74b20e25ed39/hosts"
  6064. LogPath: "/var/lib/docker/containers/1eb5fabf5a03807136561b3c00adcd2992b535d624d5e18b6cdc6a6844d9767b/1eb5fabf5a03807136561b3c00adcd2992b535d624d5e18b6cdc6a6844d9767b-json.log"
  6065. Id: "ba033ac4401106a3b513bc9d639eee123ad78ca3616b921167cd74b20e25ed39"
  6066. Image: "04c5d3b7b0656168630d3ba35d8889bd0e9caafcaeb3004d2bfbc47e7c5d35d2"
  6067. MountLabel: ""
  6068. Name: "/boring_euclid"
  6069. NetworkSettings:
  6070. Bridge: ""
  6071. SandboxID: ""
  6072. HairpinMode: false
  6073. LinkLocalIPv6Address: ""
  6074. LinkLocalIPv6PrefixLen: 0
  6075. SandboxKey: ""
  6076. EndpointID: ""
  6077. Gateway: ""
  6078. GlobalIPv6Address: ""
  6079. GlobalIPv6PrefixLen: 0
  6080. IPAddress: ""
  6081. IPPrefixLen: 0
  6082. IPv6Gateway: ""
  6083. MacAddress: ""
  6084. Networks:
  6085. bridge:
  6086. NetworkID: "7ea29fc1412292a2d7bba362f9253545fecdfa8ce9a6e37dd10ba8bee7129812"
  6087. EndpointID: "7587b82f0dada3656fda26588aee72630c6fab1536d36e394b2bfbcf898c971d"
  6088. Gateway: "172.17.0.1"
  6089. IPAddress: "172.17.0.2"
  6090. IPPrefixLen: 16
  6091. IPv6Gateway: ""
  6092. GlobalIPv6Address: ""
  6093. GlobalIPv6PrefixLen: 0
  6094. MacAddress: "02:42:ac:12:00:02"
  6095. Path: "/bin/sh"
  6096. ProcessLabel: ""
  6097. ResolvConfPath: "/var/lib/docker/containers/ba033ac4401106a3b513bc9d639eee123ad78ca3616b921167cd74b20e25ed39/resolv.conf"
  6098. RestartCount: 1
  6099. State:
  6100. Error: ""
  6101. ExitCode: 9
  6102. FinishedAt: "2015-01-06T15:47:32.080254511Z"
  6103. Health:
  6104. Status: "healthy"
  6105. FailingStreak: 0
  6106. Log:
  6107. - Start: "2019-12-22T10:59:05.6385933Z"
  6108. End: "2019-12-22T10:59:05.8078452Z"
  6109. ExitCode: 0
  6110. Output: ""
  6111. OOMKilled: false
  6112. Dead: false
  6113. Paused: false
  6114. Pid: 0
  6115. Restarting: false
  6116. Running: true
  6117. StartedAt: "2015-01-06T15:47:32.072697474Z"
  6118. Status: "running"
  6119. Mounts:
  6120. - Name: "fac362...80535"
  6121. Source: "/data"
  6122. Destination: "/data"
  6123. Driver: "local"
  6124. Mode: "ro,Z"
  6125. RW: false
  6126. Propagation: ""
  6127. 404:
  6128. description: "no such container"
  6129. schema:
  6130. $ref: "#/definitions/ErrorResponse"
  6131. examples:
  6132. application/json:
  6133. message: "No such container: c2ada9df5af8"
  6134. 500:
  6135. description: "server error"
  6136. schema:
  6137. $ref: "#/definitions/ErrorResponse"
  6138. parameters:
  6139. - name: "id"
  6140. in: "path"
  6141. required: true
  6142. description: "ID or name of the container"
  6143. type: "string"
  6144. - name: "size"
  6145. in: "query"
  6146. type: "boolean"
  6147. default: false
  6148. description: "Return the size of container as fields `SizeRw` and `SizeRootFs`"
  6149. tags: ["Container"]
  6150. /containers/{id}/top:
  6151. get:
  6152. summary: "List processes running inside a container"
  6153. description: |
  6154. On Unix systems, this is done by running the `ps` command. This endpoint
  6155. is not supported on Windows.
  6156. operationId: "ContainerTop"
  6157. responses:
  6158. 200:
  6159. description: "no error"
  6160. schema:
  6161. type: "object"
  6162. title: "ContainerTopResponse"
  6163. description: "OK response to ContainerTop operation"
  6164. properties:
  6165. Titles:
  6166. description: "The ps column titles"
  6167. type: "array"
  6168. items:
  6169. type: "string"
  6170. Processes:
  6171. description: |
  6172. Each process running in the container, where each is process
  6173. is an array of values corresponding to the titles.
  6174. type: "array"
  6175. items:
  6176. type: "array"
  6177. items:
  6178. type: "string"
  6179. examples:
  6180. application/json:
  6181. Titles:
  6182. - "UID"
  6183. - "PID"
  6184. - "PPID"
  6185. - "C"
  6186. - "STIME"
  6187. - "TTY"
  6188. - "TIME"
  6189. - "CMD"
  6190. Processes:
  6191. -
  6192. - "root"
  6193. - "13642"
  6194. - "882"
  6195. - "0"
  6196. - "17:03"
  6197. - "pts/0"
  6198. - "00:00:00"
  6199. - "/bin/bash"
  6200. -
  6201. - "root"
  6202. - "13735"
  6203. - "13642"
  6204. - "0"
  6205. - "17:06"
  6206. - "pts/0"
  6207. - "00:00:00"
  6208. - "sleep 10"
  6209. 404:
  6210. description: "no such container"
  6211. schema:
  6212. $ref: "#/definitions/ErrorResponse"
  6213. examples:
  6214. application/json:
  6215. message: "No such container: c2ada9df5af8"
  6216. 500:
  6217. description: "server error"
  6218. schema:
  6219. $ref: "#/definitions/ErrorResponse"
  6220. parameters:
  6221. - name: "id"
  6222. in: "path"
  6223. required: true
  6224. description: "ID or name of the container"
  6225. type: "string"
  6226. - name: "ps_args"
  6227. in: "query"
  6228. description: "The arguments to pass to `ps`. For example, `aux`"
  6229. type: "string"
  6230. default: "-ef"
  6231. tags: ["Container"]
  6232. /containers/{id}/logs:
  6233. get:
  6234. summary: "Get container logs"
  6235. description: |
  6236. Get `stdout` and `stderr` logs from a container.
  6237. Note: This endpoint works only for containers with the `json-file` or
  6238. `journald` logging driver.
  6239. operationId: "ContainerLogs"
  6240. responses:
  6241. 200:
  6242. description: |
  6243. logs returned as a stream in response body.
  6244. For the stream format, [see the documentation for the attach endpoint](#operation/ContainerAttach).
  6245. Note that unlike the attach endpoint, the logs endpoint does not
  6246. upgrade the connection and does not set Content-Type.
  6247. schema:
  6248. type: "string"
  6249. format: "binary"
  6250. 404:
  6251. description: "no such container"
  6252. schema:
  6253. $ref: "#/definitions/ErrorResponse"
  6254. examples:
  6255. application/json:
  6256. message: "No such container: c2ada9df5af8"
  6257. 500:
  6258. description: "server error"
  6259. schema:
  6260. $ref: "#/definitions/ErrorResponse"
  6261. parameters:
  6262. - name: "id"
  6263. in: "path"
  6264. required: true
  6265. description: "ID or name of the container"
  6266. type: "string"
  6267. - name: "follow"
  6268. in: "query"
  6269. description: "Keep connection after returning logs."
  6270. type: "boolean"
  6271. default: false
  6272. - name: "stdout"
  6273. in: "query"
  6274. description: "Return logs from `stdout`"
  6275. type: "boolean"
  6276. default: false
  6277. - name: "stderr"
  6278. in: "query"
  6279. description: "Return logs from `stderr`"
  6280. type: "boolean"
  6281. default: false
  6282. - name: "since"
  6283. in: "query"
  6284. description: "Only return logs since this time, as a UNIX timestamp"
  6285. type: "integer"
  6286. default: 0
  6287. - name: "until"
  6288. in: "query"
  6289. description: "Only return logs before this time, as a UNIX timestamp"
  6290. type: "integer"
  6291. default: 0
  6292. - name: "timestamps"
  6293. in: "query"
  6294. description: "Add timestamps to every log line"
  6295. type: "boolean"
  6296. default: false
  6297. - name: "tail"
  6298. in: "query"
  6299. description: |
  6300. Only return this number of log lines from the end of the logs.
  6301. Specify as an integer or `all` to output all log lines.
  6302. type: "string"
  6303. default: "all"
  6304. tags: ["Container"]
  6305. /containers/{id}/changes:
  6306. get:
  6307. summary: "Get changes on a container’s filesystem"
  6308. description: |
  6309. Returns which files in a container's filesystem have been added, deleted,
  6310. or modified. The `Kind` of modification can be one of:
  6311. - `0`: Modified
  6312. - `1`: Added
  6313. - `2`: Deleted
  6314. operationId: "ContainerChanges"
  6315. produces: ["application/json"]
  6316. responses:
  6317. 200:
  6318. description: "The list of changes"
  6319. schema:
  6320. type: "array"
  6321. items:
  6322. type: "object"
  6323. x-go-name: "ContainerChangeResponseItem"
  6324. title: "ContainerChangeResponseItem"
  6325. description: "change item in response to ContainerChanges operation"
  6326. required: [Path, Kind]
  6327. properties:
  6328. Path:
  6329. description: "Path to file that has changed"
  6330. type: "string"
  6331. x-nullable: false
  6332. Kind:
  6333. description: "Kind of change"
  6334. type: "integer"
  6335. format: "uint8"
  6336. enum: [0, 1, 2]
  6337. x-nullable: false
  6338. examples:
  6339. application/json:
  6340. - Path: "/dev"
  6341. Kind: 0
  6342. - Path: "/dev/kmsg"
  6343. Kind: 1
  6344. - Path: "/test"
  6345. Kind: 1
  6346. 404:
  6347. description: "no such container"
  6348. schema:
  6349. $ref: "#/definitions/ErrorResponse"
  6350. examples:
  6351. application/json:
  6352. message: "No such container: c2ada9df5af8"
  6353. 500:
  6354. description: "server error"
  6355. schema:
  6356. $ref: "#/definitions/ErrorResponse"
  6357. parameters:
  6358. - name: "id"
  6359. in: "path"
  6360. required: true
  6361. description: "ID or name of the container"
  6362. type: "string"
  6363. tags: ["Container"]
  6364. /containers/{id}/export:
  6365. get:
  6366. summary: "Export a container"
  6367. description: "Export the contents of a container as a tarball."
  6368. operationId: "ContainerExport"
  6369. produces:
  6370. - "application/octet-stream"
  6371. responses:
  6372. 200:
  6373. description: "no error"
  6374. 404:
  6375. description: "no such container"
  6376. schema:
  6377. $ref: "#/definitions/ErrorResponse"
  6378. examples:
  6379. application/json:
  6380. message: "No such container: c2ada9df5af8"
  6381. 500:
  6382. description: "server error"
  6383. schema:
  6384. $ref: "#/definitions/ErrorResponse"
  6385. parameters:
  6386. - name: "id"
  6387. in: "path"
  6388. required: true
  6389. description: "ID or name of the container"
  6390. type: "string"
  6391. tags: ["Container"]
  6392. /containers/{id}/stats:
  6393. get:
  6394. summary: "Get container stats based on resource usage"
  6395. description: |
  6396. This endpoint returns a live stream of a container’s resource usage
  6397. statistics.
  6398. The `precpu_stats` is the CPU statistic of the *previous* read, and is
  6399. used to calculate the CPU usage percentage. It is not an exact copy
  6400. of the `cpu_stats` field.
  6401. If either `precpu_stats.online_cpus` or `cpu_stats.online_cpus` is
  6402. nil then for compatibility with older daemons the length of the
  6403. corresponding `cpu_usage.percpu_usage` array should be used.
  6404. On a cgroup v2 host, the following fields are not set
  6405. * `blkio_stats`: all fields other than `io_service_bytes_recursive`
  6406. * `cpu_stats`: `cpu_usage.percpu_usage`
  6407. * `memory_stats`: `max_usage` and `failcnt`
  6408. Also, `memory_stats.stats` fields are incompatible with cgroup v1.
  6409. To calculate the values shown by the `stats` command of the docker cli tool
  6410. the following formulas can be used:
  6411. * used_memory = `memory_stats.usage - memory_stats.stats.cache`
  6412. * available_memory = `memory_stats.limit`
  6413. * Memory usage % = `(used_memory / available_memory) * 100.0`
  6414. * cpu_delta = `cpu_stats.cpu_usage.total_usage - precpu_stats.cpu_usage.total_usage`
  6415. * system_cpu_delta = `cpu_stats.system_cpu_usage - precpu_stats.system_cpu_usage`
  6416. * number_cpus = `lenght(cpu_stats.cpu_usage.percpu_usage)` or `cpu_stats.online_cpus`
  6417. * CPU usage % = `(cpu_delta / system_cpu_delta) * number_cpus * 100.0`
  6418. operationId: "ContainerStats"
  6419. produces: ["application/json"]
  6420. responses:
  6421. 200:
  6422. description: "no error"
  6423. schema:
  6424. type: "object"
  6425. examples:
  6426. application/json:
  6427. read: "2015-01-08T22:57:31.547920715Z"
  6428. pids_stats:
  6429. current: 3
  6430. networks:
  6431. eth0:
  6432. rx_bytes: 5338
  6433. rx_dropped: 0
  6434. rx_errors: 0
  6435. rx_packets: 36
  6436. tx_bytes: 648
  6437. tx_dropped: 0
  6438. tx_errors: 0
  6439. tx_packets: 8
  6440. eth5:
  6441. rx_bytes: 4641
  6442. rx_dropped: 0
  6443. rx_errors: 0
  6444. rx_packets: 26
  6445. tx_bytes: 690
  6446. tx_dropped: 0
  6447. tx_errors: 0
  6448. tx_packets: 9
  6449. memory_stats:
  6450. stats:
  6451. total_pgmajfault: 0
  6452. cache: 0
  6453. mapped_file: 0
  6454. total_inactive_file: 0
  6455. pgpgout: 414
  6456. rss: 6537216
  6457. total_mapped_file: 0
  6458. writeback: 0
  6459. unevictable: 0
  6460. pgpgin: 477
  6461. total_unevictable: 0
  6462. pgmajfault: 0
  6463. total_rss: 6537216
  6464. total_rss_huge: 6291456
  6465. total_writeback: 0
  6466. total_inactive_anon: 0
  6467. rss_huge: 6291456
  6468. hierarchical_memory_limit: 67108864
  6469. total_pgfault: 964
  6470. total_active_file: 0
  6471. active_anon: 6537216
  6472. total_active_anon: 6537216
  6473. total_pgpgout: 414
  6474. total_cache: 0
  6475. inactive_anon: 0
  6476. active_file: 0
  6477. pgfault: 964
  6478. inactive_file: 0
  6479. total_pgpgin: 477
  6480. max_usage: 6651904
  6481. usage: 6537216
  6482. failcnt: 0
  6483. limit: 67108864
  6484. blkio_stats: {}
  6485. cpu_stats:
  6486. cpu_usage:
  6487. percpu_usage:
  6488. - 8646879
  6489. - 24472255
  6490. - 36438778
  6491. - 30657443
  6492. usage_in_usermode: 50000000
  6493. total_usage: 100215355
  6494. usage_in_kernelmode: 30000000
  6495. system_cpu_usage: 739306590000000
  6496. online_cpus: 4
  6497. throttling_data:
  6498. periods: 0
  6499. throttled_periods: 0
  6500. throttled_time: 0
  6501. precpu_stats:
  6502. cpu_usage:
  6503. percpu_usage:
  6504. - 8646879
  6505. - 24350896
  6506. - 36438778
  6507. - 30657443
  6508. usage_in_usermode: 50000000
  6509. total_usage: 100093996
  6510. usage_in_kernelmode: 30000000
  6511. system_cpu_usage: 9492140000000
  6512. online_cpus: 4
  6513. throttling_data:
  6514. periods: 0
  6515. throttled_periods: 0
  6516. throttled_time: 0
  6517. 404:
  6518. description: "no such container"
  6519. schema:
  6520. $ref: "#/definitions/ErrorResponse"
  6521. examples:
  6522. application/json:
  6523. message: "No such container: c2ada9df5af8"
  6524. 500:
  6525. description: "server error"
  6526. schema:
  6527. $ref: "#/definitions/ErrorResponse"
  6528. parameters:
  6529. - name: "id"
  6530. in: "path"
  6531. required: true
  6532. description: "ID or name of the container"
  6533. type: "string"
  6534. - name: "stream"
  6535. in: "query"
  6536. description: |
  6537. Stream the output. If false, the stats will be output once and then
  6538. it will disconnect.
  6539. type: "boolean"
  6540. default: true
  6541. - name: "one-shot"
  6542. in: "query"
  6543. description: |
  6544. Only get a single stat instead of waiting for 2 cycles. Must be used
  6545. with `stream=false`.
  6546. type: "boolean"
  6547. default: false
  6548. tags: ["Container"]
  6549. /containers/{id}/resize:
  6550. post:
  6551. summary: "Resize a container TTY"
  6552. description: "Resize the TTY for a container."
  6553. operationId: "ContainerResize"
  6554. consumes:
  6555. - "application/octet-stream"
  6556. produces:
  6557. - "text/plain"
  6558. responses:
  6559. 200:
  6560. description: "no error"
  6561. 404:
  6562. description: "no such container"
  6563. schema:
  6564. $ref: "#/definitions/ErrorResponse"
  6565. examples:
  6566. application/json:
  6567. message: "No such container: c2ada9df5af8"
  6568. 500:
  6569. description: "cannot resize container"
  6570. schema:
  6571. $ref: "#/definitions/ErrorResponse"
  6572. parameters:
  6573. - name: "id"
  6574. in: "path"
  6575. required: true
  6576. description: "ID or name of the container"
  6577. type: "string"
  6578. - name: "h"
  6579. in: "query"
  6580. description: "Height of the TTY session in characters"
  6581. type: "integer"
  6582. - name: "w"
  6583. in: "query"
  6584. description: "Width of the TTY session in characters"
  6585. type: "integer"
  6586. tags: ["Container"]
  6587. /containers/{id}/start:
  6588. post:
  6589. summary: "Start a container"
  6590. operationId: "ContainerStart"
  6591. responses:
  6592. 204:
  6593. description: "no error"
  6594. 304:
  6595. description: "container already started"
  6596. 404:
  6597. description: "no such container"
  6598. schema:
  6599. $ref: "#/definitions/ErrorResponse"
  6600. examples:
  6601. application/json:
  6602. message: "No such container: c2ada9df5af8"
  6603. 500:
  6604. description: "server error"
  6605. schema:
  6606. $ref: "#/definitions/ErrorResponse"
  6607. parameters:
  6608. - name: "id"
  6609. in: "path"
  6610. required: true
  6611. description: "ID or name of the container"
  6612. type: "string"
  6613. - name: "detachKeys"
  6614. in: "query"
  6615. description: |
  6616. Override the key sequence for detaching a container. Format is a
  6617. single character `[a-Z]` or `ctrl-<value>` where `<value>` is one
  6618. of: `a-z`, `@`, `^`, `[`, `,` or `_`.
  6619. type: "string"
  6620. tags: ["Container"]
  6621. /containers/{id}/stop:
  6622. post:
  6623. summary: "Stop a container"
  6624. operationId: "ContainerStop"
  6625. responses:
  6626. 204:
  6627. description: "no error"
  6628. 304:
  6629. description: "container already stopped"
  6630. 404:
  6631. description: "no such container"
  6632. schema:
  6633. $ref: "#/definitions/ErrorResponse"
  6634. examples:
  6635. application/json:
  6636. message: "No such container: c2ada9df5af8"
  6637. 500:
  6638. description: "server error"
  6639. schema:
  6640. $ref: "#/definitions/ErrorResponse"
  6641. parameters:
  6642. - name: "id"
  6643. in: "path"
  6644. required: true
  6645. description: "ID or name of the container"
  6646. type: "string"
  6647. - name: "t"
  6648. in: "query"
  6649. description: "Number of seconds to wait before killing the container"
  6650. type: "integer"
  6651. tags: ["Container"]
  6652. /containers/{id}/restart:
  6653. post:
  6654. summary: "Restart a container"
  6655. operationId: "ContainerRestart"
  6656. responses:
  6657. 204:
  6658. description: "no error"
  6659. 404:
  6660. description: "no such container"
  6661. schema:
  6662. $ref: "#/definitions/ErrorResponse"
  6663. examples:
  6664. application/json:
  6665. message: "No such container: c2ada9df5af8"
  6666. 500:
  6667. description: "server error"
  6668. schema:
  6669. $ref: "#/definitions/ErrorResponse"
  6670. parameters:
  6671. - name: "id"
  6672. in: "path"
  6673. required: true
  6674. description: "ID or name of the container"
  6675. type: "string"
  6676. - name: "t"
  6677. in: "query"
  6678. description: "Number of seconds to wait before killing the container"
  6679. type: "integer"
  6680. tags: ["Container"]
  6681. /containers/{id}/kill:
  6682. post:
  6683. summary: "Kill a container"
  6684. description: |
  6685. Send a POSIX signal to a container, defaulting to killing to the
  6686. container.
  6687. operationId: "ContainerKill"
  6688. responses:
  6689. 204:
  6690. description: "no error"
  6691. 404:
  6692. description: "no such container"
  6693. schema:
  6694. $ref: "#/definitions/ErrorResponse"
  6695. examples:
  6696. application/json:
  6697. message: "No such container: c2ada9df5af8"
  6698. 409:
  6699. description: "container is not running"
  6700. schema:
  6701. $ref: "#/definitions/ErrorResponse"
  6702. examples:
  6703. application/json:
  6704. message: "Container d37cde0fe4ad63c3a7252023b2f9800282894247d145cb5933ddf6e52cc03a28 is not running"
  6705. 500:
  6706. description: "server error"
  6707. schema:
  6708. $ref: "#/definitions/ErrorResponse"
  6709. parameters:
  6710. - name: "id"
  6711. in: "path"
  6712. required: true
  6713. description: "ID or name of the container"
  6714. type: "string"
  6715. - name: "signal"
  6716. in: "query"
  6717. description: |
  6718. Signal to send to the container as an integer or string (e.g. `SIGINT`).
  6719. type: "string"
  6720. default: "SIGKILL"
  6721. tags: ["Container"]
  6722. /containers/{id}/update:
  6723. post:
  6724. summary: "Update a container"
  6725. description: |
  6726. Change various configuration options of a container without having to
  6727. recreate it.
  6728. operationId: "ContainerUpdate"
  6729. consumes: ["application/json"]
  6730. produces: ["application/json"]
  6731. responses:
  6732. 200:
  6733. description: "The container has been updated."
  6734. schema:
  6735. type: "object"
  6736. title: "ContainerUpdateResponse"
  6737. description: "OK response to ContainerUpdate operation"
  6738. properties:
  6739. Warnings:
  6740. type: "array"
  6741. items:
  6742. type: "string"
  6743. 404:
  6744. description: "no such container"
  6745. schema:
  6746. $ref: "#/definitions/ErrorResponse"
  6747. examples:
  6748. application/json:
  6749. message: "No such container: c2ada9df5af8"
  6750. 500:
  6751. description: "server error"
  6752. schema:
  6753. $ref: "#/definitions/ErrorResponse"
  6754. parameters:
  6755. - name: "id"
  6756. in: "path"
  6757. required: true
  6758. description: "ID or name of the container"
  6759. type: "string"
  6760. - name: "update"
  6761. in: "body"
  6762. required: true
  6763. schema:
  6764. allOf:
  6765. - $ref: "#/definitions/Resources"
  6766. - type: "object"
  6767. properties:
  6768. RestartPolicy:
  6769. $ref: "#/definitions/RestartPolicy"
  6770. example:
  6771. BlkioWeight: 300
  6772. CpuShares: 512
  6773. CpuPeriod: 100000
  6774. CpuQuota: 50000
  6775. CpuRealtimePeriod: 1000000
  6776. CpuRealtimeRuntime: 10000
  6777. CpusetCpus: "0,1"
  6778. CpusetMems: "0"
  6779. Memory: 314572800
  6780. MemorySwap: 514288000
  6781. MemoryReservation: 209715200
  6782. KernelMemory: 52428800
  6783. RestartPolicy:
  6784. MaximumRetryCount: 4
  6785. Name: "on-failure"
  6786. tags: ["Container"]
  6787. /containers/{id}/rename:
  6788. post:
  6789. summary: "Rename a container"
  6790. operationId: "ContainerRename"
  6791. responses:
  6792. 204:
  6793. description: "no error"
  6794. 404:
  6795. description: "no such container"
  6796. schema:
  6797. $ref: "#/definitions/ErrorResponse"
  6798. examples:
  6799. application/json:
  6800. message: "No such container: c2ada9df5af8"
  6801. 409:
  6802. description: "name already in use"
  6803. schema:
  6804. $ref: "#/definitions/ErrorResponse"
  6805. 500:
  6806. description: "server error"
  6807. schema:
  6808. $ref: "#/definitions/ErrorResponse"
  6809. parameters:
  6810. - name: "id"
  6811. in: "path"
  6812. required: true
  6813. description: "ID or name of the container"
  6814. type: "string"
  6815. - name: "name"
  6816. in: "query"
  6817. required: true
  6818. description: "New name for the container"
  6819. type: "string"
  6820. tags: ["Container"]
  6821. /containers/{id}/pause:
  6822. post:
  6823. summary: "Pause a container"
  6824. description: |
  6825. Use the freezer cgroup to suspend all processes in a container.
  6826. Traditionally, when suspending a process the `SIGSTOP` signal is used,
  6827. which is observable by the process being suspended. With the freezer
  6828. cgroup the process is unaware, and unable to capture, that it is being
  6829. suspended, and subsequently resumed.
  6830. operationId: "ContainerPause"
  6831. responses:
  6832. 204:
  6833. description: "no error"
  6834. 404:
  6835. description: "no such container"
  6836. schema:
  6837. $ref: "#/definitions/ErrorResponse"
  6838. examples:
  6839. application/json:
  6840. message: "No such container: c2ada9df5af8"
  6841. 500:
  6842. description: "server error"
  6843. schema:
  6844. $ref: "#/definitions/ErrorResponse"
  6845. parameters:
  6846. - name: "id"
  6847. in: "path"
  6848. required: true
  6849. description: "ID or name of the container"
  6850. type: "string"
  6851. tags: ["Container"]
  6852. /containers/{id}/unpause:
  6853. post:
  6854. summary: "Unpause a container"
  6855. description: "Resume a container which has been paused."
  6856. operationId: "ContainerUnpause"
  6857. responses:
  6858. 204:
  6859. description: "no error"
  6860. 404:
  6861. description: "no such container"
  6862. schema:
  6863. $ref: "#/definitions/ErrorResponse"
  6864. examples:
  6865. application/json:
  6866. message: "No such container: c2ada9df5af8"
  6867. 500:
  6868. description: "server error"
  6869. schema:
  6870. $ref: "#/definitions/ErrorResponse"
  6871. parameters:
  6872. - name: "id"
  6873. in: "path"
  6874. required: true
  6875. description: "ID or name of the container"
  6876. type: "string"
  6877. tags: ["Container"]
  6878. /containers/{id}/attach:
  6879. post:
  6880. summary: "Attach to a container"
  6881. description: |
  6882. Attach to a container to read its output or send it input. You can attach
  6883. to the same container multiple times and you can reattach to containers
  6884. that have been detached.
  6885. Either the `stream` or `logs` parameter must be `true` for this endpoint
  6886. to do anything.
  6887. See the [documentation for the `docker attach` command](https://docs.docker.com/engine/reference/commandline/attach/)
  6888. for more details.
  6889. ### Hijacking
  6890. This endpoint hijacks the HTTP connection to transport `stdin`, `stdout`,
  6891. and `stderr` on the same socket.
  6892. This is the response from the daemon for an attach request:
  6893. ```
  6894. HTTP/1.1 200 OK
  6895. Content-Type: application/vnd.docker.raw-stream
  6896. [STREAM]
  6897. ```
  6898. After the headers and two new lines, the TCP connection can now be used
  6899. for raw, bidirectional communication between the client and server.
  6900. To hint potential proxies about connection hijacking, the Docker client
  6901. can also optionally send connection upgrade headers.
  6902. For example, the client sends this request to upgrade the connection:
  6903. ```
  6904. POST /containers/16253994b7c4/attach?stream=1&stdout=1 HTTP/1.1
  6905. Upgrade: tcp
  6906. Connection: Upgrade
  6907. ```
  6908. The Docker daemon will respond with a `101 UPGRADED` response, and will
  6909. similarly follow with the raw stream:
  6910. ```
  6911. HTTP/1.1 101 UPGRADED
  6912. Content-Type: application/vnd.docker.raw-stream
  6913. Connection: Upgrade
  6914. Upgrade: tcp
  6915. [STREAM]
  6916. ```
  6917. ### Stream format
  6918. When the TTY setting is disabled in [`POST /containers/create`](#operation/ContainerCreate),
  6919. the stream over the hijacked connected is multiplexed to separate out
  6920. `stdout` and `stderr`. The stream consists of a series of frames, each
  6921. containing a header and a payload.
  6922. The header contains the information which the stream writes (`stdout` or
  6923. `stderr`). It also contains the size of the associated frame encoded in
  6924. the last four bytes (`uint32`).
  6925. It is encoded on the first eight bytes like this:
  6926. ```go
  6927. header := [8]byte{STREAM_TYPE, 0, 0, 0, SIZE1, SIZE2, SIZE3, SIZE4}
  6928. ```
  6929. `STREAM_TYPE` can be:
  6930. - 0: `stdin` (is written on `stdout`)
  6931. - 1: `stdout`
  6932. - 2: `stderr`
  6933. `SIZE1, SIZE2, SIZE3, SIZE4` are the four bytes of the `uint32` size
  6934. encoded as big endian.
  6935. Following the header is the payload, which is the specified number of
  6936. bytes of `STREAM_TYPE`.
  6937. The simplest way to implement this protocol is the following:
  6938. 1. Read 8 bytes.
  6939. 2. Choose `stdout` or `stderr` depending on the first byte.
  6940. 3. Extract the frame size from the last four bytes.
  6941. 4. Read the extracted size and output it on the correct output.
  6942. 5. Goto 1.
  6943. ### Stream format when using a TTY
  6944. When the TTY setting is enabled in [`POST /containers/create`](#operation/ContainerCreate),
  6945. the stream is not multiplexed. The data exchanged over the hijacked
  6946. connection is simply the raw data from the process PTY and client's
  6947. `stdin`.
  6948. operationId: "ContainerAttach"
  6949. produces:
  6950. - "application/vnd.docker.raw-stream"
  6951. responses:
  6952. 101:
  6953. description: "no error, hints proxy about hijacking"
  6954. 200:
  6955. description: "no error, no upgrade header found"
  6956. 400:
  6957. description: "bad parameter"
  6958. schema:
  6959. $ref: "#/definitions/ErrorResponse"
  6960. 404:
  6961. description: "no such container"
  6962. schema:
  6963. $ref: "#/definitions/ErrorResponse"
  6964. examples:
  6965. application/json:
  6966. message: "No such container: c2ada9df5af8"
  6967. 500:
  6968. description: "server error"
  6969. schema:
  6970. $ref: "#/definitions/ErrorResponse"
  6971. parameters:
  6972. - name: "id"
  6973. in: "path"
  6974. required: true
  6975. description: "ID or name of the container"
  6976. type: "string"
  6977. - name: "detachKeys"
  6978. in: "query"
  6979. description: |
  6980. Override the key sequence for detaching a container.Format is a single
  6981. character `[a-Z]` or `ctrl-<value>` where `<value>` is one of: `a-z`,
  6982. `@`, `^`, `[`, `,` or `_`.
  6983. type: "string"
  6984. - name: "logs"
  6985. in: "query"
  6986. description: |
  6987. Replay previous logs from the container.
  6988. This is useful for attaching to a container that has started and you
  6989. want to output everything since the container started.
  6990. If `stream` is also enabled, once all the previous output has been
  6991. returned, it will seamlessly transition into streaming current
  6992. output.
  6993. type: "boolean"
  6994. default: false
  6995. - name: "stream"
  6996. in: "query"
  6997. description: |
  6998. Stream attached streams from the time the request was made onwards.
  6999. type: "boolean"
  7000. default: false
  7001. - name: "stdin"
  7002. in: "query"
  7003. description: "Attach to `stdin`"
  7004. type: "boolean"
  7005. default: false
  7006. - name: "stdout"
  7007. in: "query"
  7008. description: "Attach to `stdout`"
  7009. type: "boolean"
  7010. default: false
  7011. - name: "stderr"
  7012. in: "query"
  7013. description: "Attach to `stderr`"
  7014. type: "boolean"
  7015. default: false
  7016. tags: ["Container"]
  7017. /containers/{id}/attach/ws:
  7018. get:
  7019. summary: "Attach to a container via a websocket"
  7020. operationId: "ContainerAttachWebsocket"
  7021. responses:
  7022. 101:
  7023. description: "no error, hints proxy about hijacking"
  7024. 200:
  7025. description: "no error, no upgrade header found"
  7026. 400:
  7027. description: "bad parameter"
  7028. schema:
  7029. $ref: "#/definitions/ErrorResponse"
  7030. 404:
  7031. description: "no such container"
  7032. schema:
  7033. $ref: "#/definitions/ErrorResponse"
  7034. examples:
  7035. application/json:
  7036. message: "No such container: c2ada9df5af8"
  7037. 500:
  7038. description: "server error"
  7039. schema:
  7040. $ref: "#/definitions/ErrorResponse"
  7041. parameters:
  7042. - name: "id"
  7043. in: "path"
  7044. required: true
  7045. description: "ID or name of the container"
  7046. type: "string"
  7047. - name: "detachKeys"
  7048. in: "query"
  7049. description: |
  7050. Override the key sequence for detaching a container.Format is a single
  7051. character `[a-Z]` or `ctrl-<value>` where `<value>` is one of: `a-z`,
  7052. `@`, `^`, `[`, `,`, or `_`.
  7053. type: "string"
  7054. - name: "logs"
  7055. in: "query"
  7056. description: "Return logs"
  7057. type: "boolean"
  7058. default: false
  7059. - name: "stream"
  7060. in: "query"
  7061. description: "Return stream"
  7062. type: "boolean"
  7063. default: false
  7064. tags: ["Container"]
  7065. /containers/{id}/wait:
  7066. post:
  7067. summary: "Wait for a container"
  7068. description: "Block until a container stops, then returns the exit code."
  7069. operationId: "ContainerWait"
  7070. produces: ["application/json"]
  7071. responses:
  7072. 200:
  7073. description: "The container has exit."
  7074. schema:
  7075. $ref: "#/definitions/ContainerWaitResponse"
  7076. 400:
  7077. description: "bad parameter"
  7078. schema:
  7079. $ref: "#/definitions/ErrorResponse"
  7080. 404:
  7081. description: "no such container"
  7082. schema:
  7083. $ref: "#/definitions/ErrorResponse"
  7084. examples:
  7085. application/json:
  7086. message: "No such container: c2ada9df5af8"
  7087. 500:
  7088. description: "server error"
  7089. schema:
  7090. $ref: "#/definitions/ErrorResponse"
  7091. parameters:
  7092. - name: "id"
  7093. in: "path"
  7094. required: true
  7095. description: "ID or name of the container"
  7096. type: "string"
  7097. - name: "condition"
  7098. in: "query"
  7099. description: |
  7100. Wait until a container state reaches the given condition.
  7101. Defaults to `not-running` if omitted or empty.
  7102. type: "string"
  7103. enum:
  7104. - "not-running"
  7105. - "next-exit"
  7106. - "removed"
  7107. default: "not-running"
  7108. tags: ["Container"]
  7109. /containers/{id}:
  7110. delete:
  7111. summary: "Remove a container"
  7112. operationId: "ContainerDelete"
  7113. responses:
  7114. 204:
  7115. description: "no error"
  7116. 400:
  7117. description: "bad parameter"
  7118. schema:
  7119. $ref: "#/definitions/ErrorResponse"
  7120. 404:
  7121. description: "no such container"
  7122. schema:
  7123. $ref: "#/definitions/ErrorResponse"
  7124. examples:
  7125. application/json:
  7126. message: "No such container: c2ada9df5af8"
  7127. 409:
  7128. description: "conflict"
  7129. schema:
  7130. $ref: "#/definitions/ErrorResponse"
  7131. examples:
  7132. application/json:
  7133. message: |
  7134. You cannot remove a running container: c2ada9df5af8. Stop the
  7135. container before attempting removal or force remove
  7136. 500:
  7137. description: "server error"
  7138. schema:
  7139. $ref: "#/definitions/ErrorResponse"
  7140. parameters:
  7141. - name: "id"
  7142. in: "path"
  7143. required: true
  7144. description: "ID or name of the container"
  7145. type: "string"
  7146. - name: "v"
  7147. in: "query"
  7148. description: "Remove anonymous volumes associated with the container."
  7149. type: "boolean"
  7150. default: false
  7151. - name: "force"
  7152. in: "query"
  7153. description: "If the container is running, kill it before removing it."
  7154. type: "boolean"
  7155. default: false
  7156. - name: "link"
  7157. in: "query"
  7158. description: "Remove the specified link associated with the container."
  7159. type: "boolean"
  7160. default: false
  7161. tags: ["Container"]
  7162. /containers/{id}/archive:
  7163. head:
  7164. summary: "Get information about files in a container"
  7165. description: |
  7166. A response header `X-Docker-Container-Path-Stat` is returned, containing
  7167. a base64 - encoded JSON object with some filesystem header information
  7168. about the path.
  7169. operationId: "ContainerArchiveInfo"
  7170. responses:
  7171. 200:
  7172. description: "no error"
  7173. headers:
  7174. X-Docker-Container-Path-Stat:
  7175. type: "string"
  7176. description: |
  7177. A base64 - encoded JSON object with some filesystem header
  7178. information about the path
  7179. 400:
  7180. description: "Bad parameter"
  7181. schema:
  7182. $ref: "#/definitions/ErrorResponse"
  7183. 404:
  7184. description: "Container or path does not exist"
  7185. schema:
  7186. $ref: "#/definitions/ErrorResponse"
  7187. examples:
  7188. application/json:
  7189. message: "No such container: c2ada9df5af8"
  7190. 500:
  7191. description: "Server error"
  7192. schema:
  7193. $ref: "#/definitions/ErrorResponse"
  7194. parameters:
  7195. - name: "id"
  7196. in: "path"
  7197. required: true
  7198. description: "ID or name of the container"
  7199. type: "string"
  7200. - name: "path"
  7201. in: "query"
  7202. required: true
  7203. description: "Resource in the container’s filesystem to archive."
  7204. type: "string"
  7205. tags: ["Container"]
  7206. get:
  7207. summary: "Get an archive of a filesystem resource in a container"
  7208. description: "Get a tar archive of a resource in the filesystem of container id."
  7209. operationId: "ContainerArchive"
  7210. produces: ["application/x-tar"]
  7211. responses:
  7212. 200:
  7213. description: "no error"
  7214. 400:
  7215. description: "Bad parameter"
  7216. schema:
  7217. $ref: "#/definitions/ErrorResponse"
  7218. 404:
  7219. description: "Container or path does not exist"
  7220. schema:
  7221. $ref: "#/definitions/ErrorResponse"
  7222. examples:
  7223. application/json:
  7224. message: "No such container: c2ada9df5af8"
  7225. 500:
  7226. description: "server error"
  7227. schema:
  7228. $ref: "#/definitions/ErrorResponse"
  7229. parameters:
  7230. - name: "id"
  7231. in: "path"
  7232. required: true
  7233. description: "ID or name of the container"
  7234. type: "string"
  7235. - name: "path"
  7236. in: "query"
  7237. required: true
  7238. description: "Resource in the container’s filesystem to archive."
  7239. type: "string"
  7240. tags: ["Container"]
  7241. put:
  7242. summary: "Extract an archive of files or folders to a directory in a container"
  7243. description: |
  7244. Upload a tar archive to be extracted to a path in the filesystem of container id.
  7245. `path` parameter is asserted to be a directory. If it exists as a file, 400 error
  7246. will be returned with message "not a directory".
  7247. operationId: "PutContainerArchive"
  7248. consumes: ["application/x-tar", "application/octet-stream"]
  7249. responses:
  7250. 200:
  7251. description: "The content was extracted successfully"
  7252. 400:
  7253. description: "Bad parameter"
  7254. schema:
  7255. $ref: "#/definitions/ErrorResponse"
  7256. examples:
  7257. application/json:
  7258. message: "not a directory"
  7259. 403:
  7260. description: "Permission denied, the volume or container rootfs is marked as read-only."
  7261. schema:
  7262. $ref: "#/definitions/ErrorResponse"
  7263. 404:
  7264. description: "No such container or path does not exist inside the container"
  7265. schema:
  7266. $ref: "#/definitions/ErrorResponse"
  7267. examples:
  7268. application/json:
  7269. message: "No such container: c2ada9df5af8"
  7270. 500:
  7271. description: "Server error"
  7272. schema:
  7273. $ref: "#/definitions/ErrorResponse"
  7274. parameters:
  7275. - name: "id"
  7276. in: "path"
  7277. required: true
  7278. description: "ID or name of the container"
  7279. type: "string"
  7280. - name: "path"
  7281. in: "query"
  7282. required: true
  7283. description: "Path to a directory in the container to extract the archive’s contents into. "
  7284. type: "string"
  7285. - name: "noOverwriteDirNonDir"
  7286. in: "query"
  7287. description: |
  7288. If `1`, `true`, or `True` then it will be an error if unpacking the
  7289. given content would cause an existing directory to be replaced with
  7290. a non-directory and vice versa.
  7291. type: "string"
  7292. - name: "copyUIDGID"
  7293. in: "query"
  7294. description: |
  7295. If `1`, `true`, then it will copy UID/GID maps to the dest file or
  7296. dir
  7297. type: "string"
  7298. - name: "inputStream"
  7299. in: "body"
  7300. required: true
  7301. description: |
  7302. The input stream must be a tar archive compressed with one of the
  7303. following algorithms: `identity` (no compression), `gzip`, `bzip2`,
  7304. or `xz`.
  7305. schema:
  7306. type: "string"
  7307. format: "binary"
  7308. tags: ["Container"]
  7309. /containers/prune:
  7310. post:
  7311. summary: "Delete stopped containers"
  7312. produces:
  7313. - "application/json"
  7314. operationId: "ContainerPrune"
  7315. parameters:
  7316. - name: "filters"
  7317. in: "query"
  7318. description: |
  7319. Filters to process on the prune list, encoded as JSON (a `map[string][]string`).
  7320. Available filters:
  7321. - `until=<timestamp>` Prune containers created before this timestamp. The `<timestamp>` can be Unix timestamps, date formatted timestamps, or Go duration strings (e.g. `10m`, `1h30m`) computed relative to the daemon machine’s time.
  7322. - `label` (`label=<key>`, `label=<key>=<value>`, `label!=<key>`, or `label!=<key>=<value>`) Prune containers with (or without, in case `label!=...` is used) the specified labels.
  7323. type: "string"
  7324. responses:
  7325. 200:
  7326. description: "No error"
  7327. schema:
  7328. type: "object"
  7329. title: "ContainerPruneResponse"
  7330. properties:
  7331. ContainersDeleted:
  7332. description: "Container IDs that were deleted"
  7333. type: "array"
  7334. items:
  7335. type: "string"
  7336. SpaceReclaimed:
  7337. description: "Disk space reclaimed in bytes"
  7338. type: "integer"
  7339. format: "int64"
  7340. 500:
  7341. description: "Server error"
  7342. schema:
  7343. $ref: "#/definitions/ErrorResponse"
  7344. tags: ["Container"]
  7345. /images/json:
  7346. get:
  7347. summary: "List Images"
  7348. description: "Returns a list of images on the server. Note that it uses a different, smaller representation of an image than inspecting a single image."
  7349. operationId: "ImageList"
  7350. produces:
  7351. - "application/json"
  7352. responses:
  7353. 200:
  7354. description: "Summary image data for the images matching the query"
  7355. schema:
  7356. type: "array"
  7357. items:
  7358. $ref: "#/definitions/ImageSummary"
  7359. 500:
  7360. description: "server error"
  7361. schema:
  7362. $ref: "#/definitions/ErrorResponse"
  7363. parameters:
  7364. - name: "all"
  7365. in: "query"
  7366. description: "Show all images. Only images from a final layer (no children) are shown by default."
  7367. type: "boolean"
  7368. default: false
  7369. - name: "filters"
  7370. in: "query"
  7371. description: |
  7372. A JSON encoded value of the filters (a `map[string][]string`) to
  7373. process on the images list.
  7374. Available filters:
  7375. - `before`=(`<image-name>[:<tag>]`, `<image id>` or `<image@digest>`)
  7376. - `dangling=true`
  7377. - `label=key` or `label="key=value"` of an image label
  7378. - `reference`=(`<image-name>[:<tag>]`)
  7379. - `since`=(`<image-name>[:<tag>]`, `<image id>` or `<image@digest>`)
  7380. type: "string"
  7381. - name: "digests"
  7382. in: "query"
  7383. description: "Show digest information as a `RepoDigests` field on each image."
  7384. type: "boolean"
  7385. default: false
  7386. tags: ["Image"]
  7387. /build:
  7388. post:
  7389. summary: "Build an image"
  7390. description: |
  7391. Build an image from a tar archive with a `Dockerfile` in it.
  7392. The `Dockerfile` specifies how the image is built from the tar archive. It is typically in the archive's root, but can be at a different path or have a different name by specifying the `dockerfile` parameter. [See the `Dockerfile` reference for more information](https://docs.docker.com/engine/reference/builder/).
  7393. The Docker daemon performs a preliminary validation of the `Dockerfile` before starting the build, and returns an error if the syntax is incorrect. After that, each instruction is run one-by-one until the ID of the new image is output.
  7394. The build is canceled if the client drops the connection by quitting or being killed.
  7395. operationId: "ImageBuild"
  7396. consumes:
  7397. - "application/octet-stream"
  7398. produces:
  7399. - "application/json"
  7400. parameters:
  7401. - name: "inputStream"
  7402. in: "body"
  7403. description: "A tar archive compressed with one of the following algorithms: identity (no compression), gzip, bzip2, xz."
  7404. schema:
  7405. type: "string"
  7406. format: "binary"
  7407. - name: "dockerfile"
  7408. in: "query"
  7409. description: "Path within the build context to the `Dockerfile`. This is ignored if `remote` is specified and points to an external `Dockerfile`."
  7410. type: "string"
  7411. default: "Dockerfile"
  7412. - name: "t"
  7413. in: "query"
  7414. description: "A name and optional tag to apply to the image in the `name:tag` format. If you omit the tag the default `latest` value is assumed. You can provide several `t` parameters."
  7415. type: "string"
  7416. - name: "extrahosts"
  7417. in: "query"
  7418. description: "Extra hosts to add to /etc/hosts"
  7419. type: "string"
  7420. - name: "remote"
  7421. in: "query"
  7422. description: "A Git repository URI or HTTP/HTTPS context URI. If the URI points to a single text file, the file’s contents are placed into a file called `Dockerfile` and the image is built from that file. If the URI points to a tarball, the file is downloaded by the daemon and the contents therein used as the context for the build. If the URI points to a tarball and the `dockerfile` parameter is also specified, there must be a file with the corresponding path inside the tarball."
  7423. type: "string"
  7424. - name: "q"
  7425. in: "query"
  7426. description: "Suppress verbose build output."
  7427. type: "boolean"
  7428. default: false
  7429. - name: "nocache"
  7430. in: "query"
  7431. description: "Do not use the cache when building the image."
  7432. type: "boolean"
  7433. default: false
  7434. - name: "cachefrom"
  7435. in: "query"
  7436. description: "JSON array of images used for build cache resolution."
  7437. type: "string"
  7438. - name: "pull"
  7439. in: "query"
  7440. description: "Attempt to pull the image even if an older image exists locally."
  7441. type: "string"
  7442. - name: "rm"
  7443. in: "query"
  7444. description: "Remove intermediate containers after a successful build."
  7445. type: "boolean"
  7446. default: true
  7447. - name: "forcerm"
  7448. in: "query"
  7449. description: "Always remove intermediate containers, even upon failure."
  7450. type: "boolean"
  7451. default: false
  7452. - name: "memory"
  7453. in: "query"
  7454. description: "Set memory limit for build."
  7455. type: "integer"
  7456. - name: "memswap"
  7457. in: "query"
  7458. description: "Total memory (memory + swap). Set as `-1` to disable swap."
  7459. type: "integer"
  7460. - name: "cpushares"
  7461. in: "query"
  7462. description: "CPU shares (relative weight)."
  7463. type: "integer"
  7464. - name: "cpusetcpus"
  7465. in: "query"
  7466. description: "CPUs in which to allow execution (e.g., `0-3`, `0,1`)."
  7467. type: "string"
  7468. - name: "cpuperiod"
  7469. in: "query"
  7470. description: "The length of a CPU period in microseconds."
  7471. type: "integer"
  7472. - name: "cpuquota"
  7473. in: "query"
  7474. description: "Microseconds of CPU time that the container can get in a CPU period."
  7475. type: "integer"
  7476. - name: "buildargs"
  7477. in: "query"
  7478. description: >
  7479. JSON map of string pairs for build-time variables. Users pass these values at build-time. Docker
  7480. uses the buildargs as the environment context for commands run via the `Dockerfile` RUN
  7481. instruction, or for variable expansion in other `Dockerfile` instructions. This is not meant for
  7482. passing secret values.
  7483. For example, the build arg `FOO=bar` would become `{"FOO":"bar"}` in JSON. This would result in the
  7484. query parameter `buildargs={"FOO":"bar"}`. Note that `{"FOO":"bar"}` should be URI component encoded.
  7485. [Read more about the buildargs instruction.](https://docs.docker.com/engine/reference/builder/#arg)
  7486. type: "string"
  7487. - name: "shmsize"
  7488. in: "query"
  7489. description: "Size of `/dev/shm` in bytes. The size must be greater than 0. If omitted the system uses 64MB."
  7490. type: "integer"
  7491. - name: "squash"
  7492. in: "query"
  7493. description: "Squash the resulting images layers into a single layer. *(Experimental release only.)*"
  7494. type: "boolean"
  7495. - name: "labels"
  7496. in: "query"
  7497. description: "Arbitrary key/value labels to set on the image, as a JSON map of string pairs."
  7498. type: "string"
  7499. - name: "networkmode"
  7500. in: "query"
  7501. description: |
  7502. Sets the networking mode for the run commands during build. Supported
  7503. standard values are: `bridge`, `host`, `none`, and `container:<name|id>`.
  7504. Any other value is taken as a custom network's name or ID to which this
  7505. container should connect to.
  7506. type: "string"
  7507. - name: "Content-type"
  7508. in: "header"
  7509. type: "string"
  7510. enum:
  7511. - "application/x-tar"
  7512. default: "application/x-tar"
  7513. - name: "X-Registry-Config"
  7514. in: "header"
  7515. description: |
  7516. This is a base64-encoded JSON object with auth configurations for multiple registries that a build may refer to.
  7517. The key is a registry URL, and the value is an auth configuration object, [as described in the authentication section](#section/Authentication). For example:
  7518. ```
  7519. {
  7520. "docker.example.com": {
  7521. "username": "janedoe",
  7522. "password": "hunter2"
  7523. },
  7524. "https://index.docker.io/v1/": {
  7525. "username": "mobydock",
  7526. "password": "conta1n3rize14"
  7527. }
  7528. }
  7529. ```
  7530. Only the registry domain name (and port if not the default 443) are required. However, for legacy reasons, the Docker Hub registry must be specified with both a `https://` prefix and a `/v1/` suffix even though Docker will prefer to use the v2 registry API.
  7531. type: "string"
  7532. - name: "platform"
  7533. in: "query"
  7534. description: "Platform in the format os[/arch[/variant]]"
  7535. type: "string"
  7536. default: ""
  7537. - name: "target"
  7538. in: "query"
  7539. description: "Target build stage"
  7540. type: "string"
  7541. default: ""
  7542. - name: "outputs"
  7543. in: "query"
  7544. description: "BuildKit output configuration"
  7545. type: "string"
  7546. default: ""
  7547. - name: "version"
  7548. in: "query"
  7549. type: "string"
  7550. default: "1"
  7551. enum: ["1", "2"]
  7552. description: |
  7553. Version of the builder backend to use.
  7554. - `1` is the first generation classic (deprecated) builder in the Docker daemon (default)
  7555. - `2` is [BuildKit](https://github.com/moby/buildkit)
  7556. responses:
  7557. 200:
  7558. description: "no error"
  7559. 400:
  7560. description: "Bad parameter"
  7561. schema:
  7562. $ref: "#/definitions/ErrorResponse"
  7563. 500:
  7564. description: "server error"
  7565. schema:
  7566. $ref: "#/definitions/ErrorResponse"
  7567. tags: ["Image"]
  7568. /build/prune:
  7569. post:
  7570. summary: "Delete builder cache"
  7571. produces:
  7572. - "application/json"
  7573. operationId: "BuildPrune"
  7574. parameters:
  7575. - name: "keep-storage"
  7576. in: "query"
  7577. description: "Amount of disk space in bytes to keep for cache"
  7578. type: "integer"
  7579. format: "int64"
  7580. - name: "all"
  7581. in: "query"
  7582. type: "boolean"
  7583. description: "Remove all types of build cache"
  7584. - name: "filters"
  7585. in: "query"
  7586. type: "string"
  7587. description: |
  7588. A JSON encoded value of the filters (a `map[string][]string`) to
  7589. process on the list of build cache objects.
  7590. Available filters:
  7591. - `until=<duration>`: duration relative to daemon's time, during which build cache was not used, in Go's duration format (e.g., '24h')
  7592. - `id=<id>`
  7593. - `parent=<id>`
  7594. - `type=<string>`
  7595. - `description=<string>`
  7596. - `inuse`
  7597. - `shared`
  7598. - `private`
  7599. responses:
  7600. 200:
  7601. description: "No error"
  7602. schema:
  7603. type: "object"
  7604. title: "BuildPruneResponse"
  7605. properties:
  7606. CachesDeleted:
  7607. type: "array"
  7608. items:
  7609. description: "ID of build cache object"
  7610. type: "string"
  7611. SpaceReclaimed:
  7612. description: "Disk space reclaimed in bytes"
  7613. type: "integer"
  7614. format: "int64"
  7615. 500:
  7616. description: "Server error"
  7617. schema:
  7618. $ref: "#/definitions/ErrorResponse"
  7619. tags: ["Image"]
  7620. /images/create:
  7621. post:
  7622. summary: "Create an image"
  7623. description: "Create an image by either pulling it from a registry or importing it."
  7624. operationId: "ImageCreate"
  7625. consumes:
  7626. - "text/plain"
  7627. - "application/octet-stream"
  7628. produces:
  7629. - "application/json"
  7630. responses:
  7631. 200:
  7632. description: "no error"
  7633. 404:
  7634. description: "repository does not exist or no read access"
  7635. schema:
  7636. $ref: "#/definitions/ErrorResponse"
  7637. 500:
  7638. description: "server error"
  7639. schema:
  7640. $ref: "#/definitions/ErrorResponse"
  7641. parameters:
  7642. - name: "fromImage"
  7643. in: "query"
  7644. description: "Name of the image to pull. The name may include a tag or digest. This parameter may only be used when pulling an image. The pull is cancelled if the HTTP connection is closed."
  7645. type: "string"
  7646. - name: "fromSrc"
  7647. in: "query"
  7648. description: "Source to import. The value may be a URL from which the image can be retrieved or `-` to read the image from the request body. This parameter may only be used when importing an image."
  7649. type: "string"
  7650. - name: "repo"
  7651. in: "query"
  7652. description: "Repository name given to an image when it is imported. The repo may include a tag. This parameter may only be used when importing an image."
  7653. type: "string"
  7654. - name: "tag"
  7655. in: "query"
  7656. description: "Tag or digest. If empty when pulling an image, this causes all tags for the given image to be pulled."
  7657. type: "string"
  7658. - name: "message"
  7659. in: "query"
  7660. description: "Set commit message for imported image."
  7661. type: "string"
  7662. - name: "inputImage"
  7663. in: "body"
  7664. description: "Image content if the value `-` has been specified in fromSrc query parameter"
  7665. schema:
  7666. type: "string"
  7667. required: false
  7668. - name: "X-Registry-Auth"
  7669. in: "header"
  7670. description: |
  7671. A base64url-encoded auth configuration.
  7672. Refer to the [authentication section](#section/Authentication) for
  7673. details.
  7674. type: "string"
  7675. - name: "changes"
  7676. in: "query"
  7677. description: |
  7678. Apply `Dockerfile` instructions to the image that is created,
  7679. for example: `changes=ENV DEBUG=true`.
  7680. Note that `ENV DEBUG=true` should be URI component encoded.
  7681. Supported `Dockerfile` instructions:
  7682. `CMD`|`ENTRYPOINT`|`ENV`|`EXPOSE`|`ONBUILD`|`USER`|`VOLUME`|`WORKDIR`
  7683. type: "array"
  7684. items:
  7685. type: "string"
  7686. - name: "platform"
  7687. in: "query"
  7688. description: "Platform in the format os[/arch[/variant]]"
  7689. type: "string"
  7690. default: ""
  7691. tags: ["Image"]
  7692. /images/{name}/json:
  7693. get:
  7694. summary: "Inspect an image"
  7695. description: "Return low-level information about an image."
  7696. operationId: "ImageInspect"
  7697. produces:
  7698. - "application/json"
  7699. responses:
  7700. 200:
  7701. description: "No error"
  7702. schema:
  7703. $ref: "#/definitions/ImageInspect"
  7704. 404:
  7705. description: "No such image"
  7706. schema:
  7707. $ref: "#/definitions/ErrorResponse"
  7708. examples:
  7709. application/json:
  7710. message: "No such image: someimage (tag: latest)"
  7711. 500:
  7712. description: "Server error"
  7713. schema:
  7714. $ref: "#/definitions/ErrorResponse"
  7715. parameters:
  7716. - name: "name"
  7717. in: "path"
  7718. description: "Image name or id"
  7719. type: "string"
  7720. required: true
  7721. tags: ["Image"]
  7722. /images/{name}/history:
  7723. get:
  7724. summary: "Get the history of an image"
  7725. description: "Return parent layers of an image."
  7726. operationId: "ImageHistory"
  7727. produces: ["application/json"]
  7728. responses:
  7729. 200:
  7730. description: "List of image layers"
  7731. schema:
  7732. type: "array"
  7733. items:
  7734. type: "object"
  7735. x-go-name: HistoryResponseItem
  7736. title: "HistoryResponseItem"
  7737. description: "individual image layer information in response to ImageHistory operation"
  7738. required: [Id, Created, CreatedBy, Tags, Size, Comment]
  7739. properties:
  7740. Id:
  7741. type: "string"
  7742. x-nullable: false
  7743. Created:
  7744. type: "integer"
  7745. format: "int64"
  7746. x-nullable: false
  7747. CreatedBy:
  7748. type: "string"
  7749. x-nullable: false
  7750. Tags:
  7751. type: "array"
  7752. items:
  7753. type: "string"
  7754. Size:
  7755. type: "integer"
  7756. format: "int64"
  7757. x-nullable: false
  7758. Comment:
  7759. type: "string"
  7760. x-nullable: false
  7761. examples:
  7762. application/json:
  7763. - Id: "3db9c44f45209632d6050b35958829c3a2aa256d81b9a7be45b362ff85c54710"
  7764. Created: 1398108230
  7765. CreatedBy: "/bin/sh -c #(nop) ADD file:eb15dbd63394e063b805a3c32ca7bf0266ef64676d5a6fab4801f2e81e2a5148 in /"
  7766. Tags:
  7767. - "ubuntu:lucid"
  7768. - "ubuntu:10.04"
  7769. Size: 182964289
  7770. Comment: ""
  7771. - Id: "6cfa4d1f33fb861d4d114f43b25abd0ac737509268065cdfd69d544a59c85ab8"
  7772. Created: 1398108222
  7773. CreatedBy: "/bin/sh -c #(nop) MAINTAINER Tianon Gravi <admwiggin@gmail.com> - mkimage-debootstrap.sh -i iproute,iputils-ping,ubuntu-minimal -t lucid.tar.xz lucid http://archive.ubuntu.com/ubuntu/"
  7774. Tags: []
  7775. Size: 0
  7776. Comment: ""
  7777. - Id: "511136ea3c5a64f264b78b5433614aec563103b4d4702f3ba7d4d2698e22c158"
  7778. Created: 1371157430
  7779. CreatedBy: ""
  7780. Tags:
  7781. - "scratch12:latest"
  7782. - "scratch:latest"
  7783. Size: 0
  7784. Comment: "Imported from -"
  7785. 404:
  7786. description: "No such image"
  7787. schema:
  7788. $ref: "#/definitions/ErrorResponse"
  7789. 500:
  7790. description: "Server error"
  7791. schema:
  7792. $ref: "#/definitions/ErrorResponse"
  7793. parameters:
  7794. - name: "name"
  7795. in: "path"
  7796. description: "Image name or ID"
  7797. type: "string"
  7798. required: true
  7799. tags: ["Image"]
  7800. /images/{name}/push:
  7801. post:
  7802. summary: "Push an image"
  7803. description: |
  7804. Push an image to a registry.
  7805. If you wish to push an image on to a private registry, that image must
  7806. already have a tag which references the registry. For example,
  7807. `registry.example.com/myimage:latest`.
  7808. The push is cancelled if the HTTP connection is closed.
  7809. operationId: "ImagePush"
  7810. consumes:
  7811. - "application/octet-stream"
  7812. responses:
  7813. 200:
  7814. description: "No error"
  7815. 404:
  7816. description: "No such image"
  7817. schema:
  7818. $ref: "#/definitions/ErrorResponse"
  7819. 500:
  7820. description: "Server error"
  7821. schema:
  7822. $ref: "#/definitions/ErrorResponse"
  7823. parameters:
  7824. - name: "name"
  7825. in: "path"
  7826. description: "Image name or ID."
  7827. type: "string"
  7828. required: true
  7829. - name: "tag"
  7830. in: "query"
  7831. description: "The tag to associate with the image on the registry."
  7832. type: "string"
  7833. - name: "X-Registry-Auth"
  7834. in: "header"
  7835. description: |
  7836. A base64url-encoded auth configuration.
  7837. Refer to the [authentication section](#section/Authentication) for
  7838. details.
  7839. type: "string"
  7840. required: true
  7841. tags: ["Image"]
  7842. /images/{name}/tag:
  7843. post:
  7844. summary: "Tag an image"
  7845. description: "Tag an image so that it becomes part of a repository."
  7846. operationId: "ImageTag"
  7847. responses:
  7848. 201:
  7849. description: "No error"
  7850. 400:
  7851. description: "Bad parameter"
  7852. schema:
  7853. $ref: "#/definitions/ErrorResponse"
  7854. 404:
  7855. description: "No such image"
  7856. schema:
  7857. $ref: "#/definitions/ErrorResponse"
  7858. 409:
  7859. description: "Conflict"
  7860. schema:
  7861. $ref: "#/definitions/ErrorResponse"
  7862. 500:
  7863. description: "Server error"
  7864. schema:
  7865. $ref: "#/definitions/ErrorResponse"
  7866. parameters:
  7867. - name: "name"
  7868. in: "path"
  7869. description: "Image name or ID to tag."
  7870. type: "string"
  7871. required: true
  7872. - name: "repo"
  7873. in: "query"
  7874. description: "The repository to tag in. For example, `someuser/someimage`."
  7875. type: "string"
  7876. - name: "tag"
  7877. in: "query"
  7878. description: "The name of the new tag."
  7879. type: "string"
  7880. tags: ["Image"]
  7881. /images/{name}:
  7882. delete:
  7883. summary: "Remove an image"
  7884. description: |
  7885. Remove an image, along with any untagged parent images that were
  7886. referenced by that image.
  7887. Images can't be removed if they have descendant images, are being
  7888. used by a running container or are being used by a build.
  7889. operationId: "ImageDelete"
  7890. produces: ["application/json"]
  7891. responses:
  7892. 200:
  7893. description: "The image was deleted successfully"
  7894. schema:
  7895. type: "array"
  7896. items:
  7897. $ref: "#/definitions/ImageDeleteResponseItem"
  7898. examples:
  7899. application/json:
  7900. - Untagged: "3e2f21a89f"
  7901. - Deleted: "3e2f21a89f"
  7902. - Deleted: "53b4f83ac9"
  7903. 404:
  7904. description: "No such image"
  7905. schema:
  7906. $ref: "#/definitions/ErrorResponse"
  7907. 409:
  7908. description: "Conflict"
  7909. schema:
  7910. $ref: "#/definitions/ErrorResponse"
  7911. 500:
  7912. description: "Server error"
  7913. schema:
  7914. $ref: "#/definitions/ErrorResponse"
  7915. parameters:
  7916. - name: "name"
  7917. in: "path"
  7918. description: "Image name or ID"
  7919. type: "string"
  7920. required: true
  7921. - name: "force"
  7922. in: "query"
  7923. description: "Remove the image even if it is being used by stopped containers or has other tags"
  7924. type: "boolean"
  7925. default: false
  7926. - name: "noprune"
  7927. in: "query"
  7928. description: "Do not delete untagged parent images"
  7929. type: "boolean"
  7930. default: false
  7931. tags: ["Image"]
  7932. /images/search:
  7933. get:
  7934. summary: "Search images"
  7935. description: "Search for an image on Docker Hub."
  7936. operationId: "ImageSearch"
  7937. produces:
  7938. - "application/json"
  7939. responses:
  7940. 200:
  7941. description: "No error"
  7942. schema:
  7943. type: "array"
  7944. items:
  7945. type: "object"
  7946. title: "ImageSearchResponseItem"
  7947. properties:
  7948. description:
  7949. type: "string"
  7950. is_official:
  7951. type: "boolean"
  7952. is_automated:
  7953. type: "boolean"
  7954. name:
  7955. type: "string"
  7956. star_count:
  7957. type: "integer"
  7958. examples:
  7959. application/json:
  7960. - description: ""
  7961. is_official: false
  7962. is_automated: false
  7963. name: "wma55/u1210sshd"
  7964. star_count: 0
  7965. - description: ""
  7966. is_official: false
  7967. is_automated: false
  7968. name: "jdswinbank/sshd"
  7969. star_count: 0
  7970. - description: ""
  7971. is_official: false
  7972. is_automated: false
  7973. name: "vgauthier/sshd"
  7974. star_count: 0
  7975. 500:
  7976. description: "Server error"
  7977. schema:
  7978. $ref: "#/definitions/ErrorResponse"
  7979. parameters:
  7980. - name: "term"
  7981. in: "query"
  7982. description: "Term to search"
  7983. type: "string"
  7984. required: true
  7985. - name: "limit"
  7986. in: "query"
  7987. description: "Maximum number of results to return"
  7988. type: "integer"
  7989. - name: "filters"
  7990. in: "query"
  7991. description: |
  7992. A JSON encoded value of the filters (a `map[string][]string`) to process on the images list. Available filters:
  7993. - `is-automated=(true|false)`
  7994. - `is-official=(true|false)`
  7995. - `stars=<number>` Matches images that has at least 'number' stars.
  7996. type: "string"
  7997. tags: ["Image"]
  7998. /images/prune:
  7999. post:
  8000. summary: "Delete unused images"
  8001. produces:
  8002. - "application/json"
  8003. operationId: "ImagePrune"
  8004. parameters:
  8005. - name: "filters"
  8006. in: "query"
  8007. description: |
  8008. Filters to process on the prune list, encoded as JSON (a `map[string][]string`). Available filters:
  8009. - `dangling=<boolean>` When set to `true` (or `1`), prune only
  8010. unused *and* untagged images. When set to `false`
  8011. (or `0`), all unused images are pruned.
  8012. - `until=<string>` Prune images created before this timestamp. The `<timestamp>` can be Unix timestamps, date formatted timestamps, or Go duration strings (e.g. `10m`, `1h30m`) computed relative to the daemon machine’s time.
  8013. - `label` (`label=<key>`, `label=<key>=<value>`, `label!=<key>`, or `label!=<key>=<value>`) Prune images with (or without, in case `label!=...` is used) the specified labels.
  8014. type: "string"
  8015. responses:
  8016. 200:
  8017. description: "No error"
  8018. schema:
  8019. type: "object"
  8020. title: "ImagePruneResponse"
  8021. properties:
  8022. ImagesDeleted:
  8023. description: "Images that were deleted"
  8024. type: "array"
  8025. items:
  8026. $ref: "#/definitions/ImageDeleteResponseItem"
  8027. SpaceReclaimed:
  8028. description: "Disk space reclaimed in bytes"
  8029. type: "integer"
  8030. format: "int64"
  8031. 500:
  8032. description: "Server error"
  8033. schema:
  8034. $ref: "#/definitions/ErrorResponse"
  8035. tags: ["Image"]
  8036. /auth:
  8037. post:
  8038. summary: "Check auth configuration"
  8039. description: |
  8040. Validate credentials for a registry and, if available, get an identity
  8041. token for accessing the registry without password.
  8042. operationId: "SystemAuth"
  8043. consumes: ["application/json"]
  8044. produces: ["application/json"]
  8045. responses:
  8046. 200:
  8047. description: "An identity token was generated successfully."
  8048. schema:
  8049. type: "object"
  8050. title: "SystemAuthResponse"
  8051. required: [Status]
  8052. properties:
  8053. Status:
  8054. description: "The status of the authentication"
  8055. type: "string"
  8056. x-nullable: false
  8057. IdentityToken:
  8058. description: "An opaque token used to authenticate a user after a successful login"
  8059. type: "string"
  8060. x-nullable: false
  8061. examples:
  8062. application/json:
  8063. Status: "Login Succeeded"
  8064. IdentityToken: "9cbaf023786cd7..."
  8065. 204:
  8066. description: "No error"
  8067. 401:
  8068. description: "Auth error"
  8069. schema:
  8070. $ref: "#/definitions/ErrorResponse"
  8071. 500:
  8072. description: "Server error"
  8073. schema:
  8074. $ref: "#/definitions/ErrorResponse"
  8075. parameters:
  8076. - name: "authConfig"
  8077. in: "body"
  8078. description: "Authentication to check"
  8079. schema:
  8080. $ref: "#/definitions/AuthConfig"
  8081. tags: ["System"]
  8082. /info:
  8083. get:
  8084. summary: "Get system information"
  8085. operationId: "SystemInfo"
  8086. produces:
  8087. - "application/json"
  8088. responses:
  8089. 200:
  8090. description: "No error"
  8091. schema:
  8092. $ref: "#/definitions/SystemInfo"
  8093. 500:
  8094. description: "Server error"
  8095. schema:
  8096. $ref: "#/definitions/ErrorResponse"
  8097. tags: ["System"]
  8098. /version:
  8099. get:
  8100. summary: "Get version"
  8101. description: "Returns the version of Docker that is running and various information about the system that Docker is running on."
  8102. operationId: "SystemVersion"
  8103. produces: ["application/json"]
  8104. responses:
  8105. 200:
  8106. description: "no error"
  8107. schema:
  8108. $ref: "#/definitions/SystemVersion"
  8109. 500:
  8110. description: "server error"
  8111. schema:
  8112. $ref: "#/definitions/ErrorResponse"
  8113. tags: ["System"]
  8114. /_ping:
  8115. get:
  8116. summary: "Ping"
  8117. description: "This is a dummy endpoint you can use to test if the server is accessible."
  8118. operationId: "SystemPing"
  8119. produces: ["text/plain"]
  8120. responses:
  8121. 200:
  8122. description: "no error"
  8123. schema:
  8124. type: "string"
  8125. example: "OK"
  8126. headers:
  8127. API-Version:
  8128. type: "string"
  8129. description: "Max API Version the server supports"
  8130. Builder-Version:
  8131. type: "string"
  8132. description: "Default version of docker image builder"
  8133. Docker-Experimental:
  8134. type: "boolean"
  8135. description: "If the server is running with experimental mode enabled"
  8136. Cache-Control:
  8137. type: "string"
  8138. default: "no-cache, no-store, must-revalidate"
  8139. Pragma:
  8140. type: "string"
  8141. default: "no-cache"
  8142. 500:
  8143. description: "server error"
  8144. schema:
  8145. $ref: "#/definitions/ErrorResponse"
  8146. headers:
  8147. Cache-Control:
  8148. type: "string"
  8149. default: "no-cache, no-store, must-revalidate"
  8150. Pragma:
  8151. type: "string"
  8152. default: "no-cache"
  8153. tags: ["System"]
  8154. head:
  8155. summary: "Ping"
  8156. description: "This is a dummy endpoint you can use to test if the server is accessible."
  8157. operationId: "SystemPingHead"
  8158. produces: ["text/plain"]
  8159. responses:
  8160. 200:
  8161. description: "no error"
  8162. schema:
  8163. type: "string"
  8164. example: "(empty)"
  8165. headers:
  8166. API-Version:
  8167. type: "string"
  8168. description: "Max API Version the server supports"
  8169. Builder-Version:
  8170. type: "string"
  8171. description: "Default version of docker image builder"
  8172. Docker-Experimental:
  8173. type: "boolean"
  8174. description: "If the server is running with experimental mode enabled"
  8175. Cache-Control:
  8176. type: "string"
  8177. default: "no-cache, no-store, must-revalidate"
  8178. Pragma:
  8179. type: "string"
  8180. default: "no-cache"
  8181. 500:
  8182. description: "server error"
  8183. schema:
  8184. $ref: "#/definitions/ErrorResponse"
  8185. tags: ["System"]
  8186. /commit:
  8187. post:
  8188. summary: "Create a new image from a container"
  8189. operationId: "ImageCommit"
  8190. consumes:
  8191. - "application/json"
  8192. produces:
  8193. - "application/json"
  8194. responses:
  8195. 201:
  8196. description: "no error"
  8197. schema:
  8198. $ref: "#/definitions/IdResponse"
  8199. 404:
  8200. description: "no such container"
  8201. schema:
  8202. $ref: "#/definitions/ErrorResponse"
  8203. examples:
  8204. application/json:
  8205. message: "No such container: c2ada9df5af8"
  8206. 500:
  8207. description: "server error"
  8208. schema:
  8209. $ref: "#/definitions/ErrorResponse"
  8210. parameters:
  8211. - name: "containerConfig"
  8212. in: "body"
  8213. description: "The container configuration"
  8214. schema:
  8215. $ref: "#/definitions/ContainerConfig"
  8216. - name: "container"
  8217. in: "query"
  8218. description: "The ID or name of the container to commit"
  8219. type: "string"
  8220. - name: "repo"
  8221. in: "query"
  8222. description: "Repository name for the created image"
  8223. type: "string"
  8224. - name: "tag"
  8225. in: "query"
  8226. description: "Tag name for the create image"
  8227. type: "string"
  8228. - name: "comment"
  8229. in: "query"
  8230. description: "Commit message"
  8231. type: "string"
  8232. - name: "author"
  8233. in: "query"
  8234. description: "Author of the image (e.g., `John Hannibal Smith <hannibal@a-team.com>`)"
  8235. type: "string"
  8236. - name: "pause"
  8237. in: "query"
  8238. description: "Whether to pause the container before committing"
  8239. type: "boolean"
  8240. default: true
  8241. - name: "changes"
  8242. in: "query"
  8243. description: "`Dockerfile` instructions to apply while committing"
  8244. type: "string"
  8245. tags: ["Image"]
  8246. /events:
  8247. get:
  8248. summary: "Monitor events"
  8249. description: |
  8250. Stream real-time events from the server.
  8251. Various objects within Docker report events when something happens to them.
  8252. Containers report these events: `attach`, `commit`, `copy`, `create`, `destroy`, `detach`, `die`, `exec_create`, `exec_detach`, `exec_start`, `exec_die`, `export`, `health_status`, `kill`, `oom`, `pause`, `rename`, `resize`, `restart`, `start`, `stop`, `top`, `unpause`, `update`, and `prune`
  8253. Images report these events: `delete`, `import`, `load`, `pull`, `push`, `save`, `tag`, `untag`, and `prune`
  8254. Volumes report these events: `create`, `mount`, `unmount`, `destroy`, and `prune`
  8255. Networks report these events: `create`, `connect`, `disconnect`, `destroy`, `update`, `remove`, and `prune`
  8256. The Docker daemon reports these events: `reload`
  8257. Services report these events: `create`, `update`, and `remove`
  8258. Nodes report these events: `create`, `update`, and `remove`
  8259. Secrets report these events: `create`, `update`, and `remove`
  8260. Configs report these events: `create`, `update`, and `remove`
  8261. The Builder reports `prune` events
  8262. operationId: "SystemEvents"
  8263. produces:
  8264. - "application/json"
  8265. responses:
  8266. 200:
  8267. description: "no error"
  8268. schema:
  8269. $ref: "#/definitions/EventMessage"
  8270. 400:
  8271. description: "bad parameter"
  8272. schema:
  8273. $ref: "#/definitions/ErrorResponse"
  8274. 500:
  8275. description: "server error"
  8276. schema:
  8277. $ref: "#/definitions/ErrorResponse"
  8278. parameters:
  8279. - name: "since"
  8280. in: "query"
  8281. description: "Show events created since this timestamp then stream new events."
  8282. type: "string"
  8283. - name: "until"
  8284. in: "query"
  8285. description: "Show events created until this timestamp then stop streaming."
  8286. type: "string"
  8287. - name: "filters"
  8288. in: "query"
  8289. description: |
  8290. A JSON encoded value of filters (a `map[string][]string`) to process on the event list. Available filters:
  8291. - `config=<string>` config name or ID
  8292. - `container=<string>` container name or ID
  8293. - `daemon=<string>` daemon name or ID
  8294. - `event=<string>` event type
  8295. - `image=<string>` image name or ID
  8296. - `label=<string>` image or container label
  8297. - `network=<string>` network name or ID
  8298. - `node=<string>` node ID
  8299. - `plugin`=<string> plugin name or ID
  8300. - `scope`=<string> local or swarm
  8301. - `secret=<string>` secret name or ID
  8302. - `service=<string>` service name or ID
  8303. - `type=<string>` object to filter by, one of `container`, `image`, `volume`, `network`, `daemon`, `plugin`, `node`, `service`, `secret` or `config`
  8304. - `volume=<string>` volume name
  8305. type: "string"
  8306. tags: ["System"]
  8307. /system/df:
  8308. get:
  8309. summary: "Get data usage information"
  8310. operationId: "SystemDataUsage"
  8311. responses:
  8312. 200:
  8313. description: "no error"
  8314. schema:
  8315. type: "object"
  8316. title: "SystemDataUsageResponse"
  8317. properties:
  8318. LayersSize:
  8319. type: "integer"
  8320. format: "int64"
  8321. Images:
  8322. type: "array"
  8323. items:
  8324. $ref: "#/definitions/ImageSummary"
  8325. Containers:
  8326. type: "array"
  8327. items:
  8328. $ref: "#/definitions/ContainerSummary"
  8329. Volumes:
  8330. type: "array"
  8331. items:
  8332. $ref: "#/definitions/Volume"
  8333. BuildCache:
  8334. type: "array"
  8335. items:
  8336. $ref: "#/definitions/BuildCache"
  8337. example:
  8338. LayersSize: 1092588
  8339. Images:
  8340. -
  8341. Id: "sha256:2b8fd9751c4c0f5dd266fcae00707e67a2545ef34f9a29354585f93dac906749"
  8342. ParentId: ""
  8343. RepoTags:
  8344. - "busybox:latest"
  8345. RepoDigests:
  8346. - "busybox@sha256:a59906e33509d14c036c8678d687bd4eec81ed7c4b8ce907b888c607f6a1e0e6"
  8347. Created: 1466724217
  8348. Size: 1092588
  8349. SharedSize: 0
  8350. VirtualSize: 1092588
  8351. Labels: {}
  8352. Containers: 1
  8353. Containers:
  8354. -
  8355. Id: "e575172ed11dc01bfce087fb27bee502db149e1a0fad7c296ad300bbff178148"
  8356. Names:
  8357. - "/top"
  8358. Image: "busybox"
  8359. ImageID: "sha256:2b8fd9751c4c0f5dd266fcae00707e67a2545ef34f9a29354585f93dac906749"
  8360. Command: "top"
  8361. Created: 1472592424
  8362. Ports: []
  8363. SizeRootFs: 1092588
  8364. Labels: {}
  8365. State: "exited"
  8366. Status: "Exited (0) 56 minutes ago"
  8367. HostConfig:
  8368. NetworkMode: "default"
  8369. NetworkSettings:
  8370. Networks:
  8371. bridge:
  8372. IPAMConfig: null
  8373. Links: null
  8374. Aliases: null
  8375. NetworkID: "d687bc59335f0e5c9ee8193e5612e8aee000c8c62ea170cfb99c098f95899d92"
  8376. EndpointID: "8ed5115aeaad9abb174f68dcf135b49f11daf597678315231a32ca28441dec6a"
  8377. Gateway: "172.18.0.1"
  8378. IPAddress: "172.18.0.2"
  8379. IPPrefixLen: 16
  8380. IPv6Gateway: ""
  8381. GlobalIPv6Address: ""
  8382. GlobalIPv6PrefixLen: 0
  8383. MacAddress: "02:42:ac:12:00:02"
  8384. Mounts: []
  8385. Volumes:
  8386. -
  8387. Name: "my-volume"
  8388. Driver: "local"
  8389. Mountpoint: "/var/lib/docker/volumes/my-volume/_data"
  8390. Labels: null
  8391. Scope: "local"
  8392. Options: null
  8393. UsageData:
  8394. Size: 10920104
  8395. RefCount: 2
  8396. BuildCache:
  8397. -
  8398. ID: "hw53o5aio51xtltp5xjp8v7fx"
  8399. Parent: ""
  8400. Type: "regular"
  8401. Description: "pulled from docker.io/library/debian@sha256:234cb88d3020898631af0ccbbcca9a66ae7306ecd30c9720690858c1b007d2a0"
  8402. InUse: false
  8403. Shared: true
  8404. Size: 0
  8405. CreatedAt: "2021-06-28T13:31:01.474619385Z"
  8406. LastUsedAt: "2021-07-07T22:02:32.738075951Z"
  8407. UsageCount: 26
  8408. -
  8409. ID: "ndlpt0hhvkqcdfkputsk4cq9c"
  8410. Parent: "ndlpt0hhvkqcdfkputsk4cq9c"
  8411. Type: "regular"
  8412. Description: "mount / from exec /bin/sh -c echo 'Binary::apt::APT::Keep-Downloaded-Packages \"true\";' > /etc/apt/apt.conf.d/keep-cache"
  8413. InUse: false
  8414. Shared: true
  8415. Size: 51
  8416. CreatedAt: "2021-06-28T13:31:03.002625487Z"
  8417. LastUsedAt: "2021-07-07T22:02:32.773909517Z"
  8418. UsageCount: 26
  8419. 500:
  8420. description: "server error"
  8421. schema:
  8422. $ref: "#/definitions/ErrorResponse"
  8423. tags: ["System"]
  8424. /images/{name}/get:
  8425. get:
  8426. summary: "Export an image"
  8427. description: |
  8428. Get a tarball containing all images and metadata for a repository.
  8429. If `name` is a specific name and tag (e.g. `ubuntu:latest`), then only that image (and its parents) are returned. If `name` is an image ID, similarly only that image (and its parents) are returned, but with the exclusion of the `repositories` file in the tarball, as there were no image names referenced.
  8430. ### Image tarball format
  8431. An image tarball contains one directory per image layer (named using its long ID), each containing these files:
  8432. - `VERSION`: currently `1.0` - the file format version
  8433. - `json`: detailed layer information, similar to `docker inspect layer_id`
  8434. - `layer.tar`: A tarfile containing the filesystem changes in this layer
  8435. The `layer.tar` file contains `aufs` style `.wh..wh.aufs` files and directories for storing attribute changes and deletions.
  8436. If the tarball defines a repository, the tarball should also include a `repositories` file at the root that contains a list of repository and tag names mapped to layer IDs.
  8437. ```json
  8438. {
  8439. "hello-world": {
  8440. "latest": "565a9d68a73f6706862bfe8409a7f659776d4d60a8d096eb4a3cbce6999cc2a1"
  8441. }
  8442. }
  8443. ```
  8444. operationId: "ImageGet"
  8445. produces:
  8446. - "application/x-tar"
  8447. responses:
  8448. 200:
  8449. description: "no error"
  8450. schema:
  8451. type: "string"
  8452. format: "binary"
  8453. 500:
  8454. description: "server error"
  8455. schema:
  8456. $ref: "#/definitions/ErrorResponse"
  8457. parameters:
  8458. - name: "name"
  8459. in: "path"
  8460. description: "Image name or ID"
  8461. type: "string"
  8462. required: true
  8463. tags: ["Image"]
  8464. /images/get:
  8465. get:
  8466. summary: "Export several images"
  8467. description: |
  8468. Get a tarball containing all images and metadata for several image
  8469. repositories.
  8470. For each value of the `names` parameter: if it is a specific name and
  8471. tag (e.g. `ubuntu:latest`), then only that image (and its parents) are
  8472. returned; if it is an image ID, similarly only that image (and its parents)
  8473. are returned and there would be no names referenced in the 'repositories'
  8474. file for this image ID.
  8475. For details on the format, see the [export image endpoint](#operation/ImageGet).
  8476. operationId: "ImageGetAll"
  8477. produces:
  8478. - "application/x-tar"
  8479. responses:
  8480. 200:
  8481. description: "no error"
  8482. schema:
  8483. type: "string"
  8484. format: "binary"
  8485. 500:
  8486. description: "server error"
  8487. schema:
  8488. $ref: "#/definitions/ErrorResponse"
  8489. parameters:
  8490. - name: "names"
  8491. in: "query"
  8492. description: "Image names to filter by"
  8493. type: "array"
  8494. items:
  8495. type: "string"
  8496. tags: ["Image"]
  8497. /images/load:
  8498. post:
  8499. summary: "Import images"
  8500. description: |
  8501. Load a set of images and tags into a repository.
  8502. For details on the format, see the [export image endpoint](#operation/ImageGet).
  8503. operationId: "ImageLoad"
  8504. consumes:
  8505. - "application/x-tar"
  8506. produces:
  8507. - "application/json"
  8508. responses:
  8509. 200:
  8510. description: "no error"
  8511. 500:
  8512. description: "server error"
  8513. schema:
  8514. $ref: "#/definitions/ErrorResponse"
  8515. parameters:
  8516. - name: "imagesTarball"
  8517. in: "body"
  8518. description: "Tar archive containing images"
  8519. schema:
  8520. type: "string"
  8521. format: "binary"
  8522. - name: "quiet"
  8523. in: "query"
  8524. description: "Suppress progress details during load."
  8525. type: "boolean"
  8526. default: false
  8527. tags: ["Image"]
  8528. /containers/{id}/exec:
  8529. post:
  8530. summary: "Create an exec instance"
  8531. description: "Run a command inside a running container."
  8532. operationId: "ContainerExec"
  8533. consumes:
  8534. - "application/json"
  8535. produces:
  8536. - "application/json"
  8537. responses:
  8538. 201:
  8539. description: "no error"
  8540. schema:
  8541. $ref: "#/definitions/IdResponse"
  8542. 404:
  8543. description: "no such container"
  8544. schema:
  8545. $ref: "#/definitions/ErrorResponse"
  8546. examples:
  8547. application/json:
  8548. message: "No such container: c2ada9df5af8"
  8549. 409:
  8550. description: "container is paused"
  8551. schema:
  8552. $ref: "#/definitions/ErrorResponse"
  8553. 500:
  8554. description: "Server error"
  8555. schema:
  8556. $ref: "#/definitions/ErrorResponse"
  8557. parameters:
  8558. - name: "execConfig"
  8559. in: "body"
  8560. description: "Exec configuration"
  8561. schema:
  8562. type: "object"
  8563. title: "ExecConfig"
  8564. properties:
  8565. AttachStdin:
  8566. type: "boolean"
  8567. description: "Attach to `stdin` of the exec command."
  8568. AttachStdout:
  8569. type: "boolean"
  8570. description: "Attach to `stdout` of the exec command."
  8571. AttachStderr:
  8572. type: "boolean"
  8573. description: "Attach to `stderr` of the exec command."
  8574. DetachKeys:
  8575. type: "string"
  8576. description: |
  8577. Override the key sequence for detaching a container. Format is
  8578. a single character `[a-Z]` or `ctrl-<value>` where `<value>`
  8579. is one of: `a-z`, `@`, `^`, `[`, `,` or `_`.
  8580. Tty:
  8581. type: "boolean"
  8582. description: "Allocate a pseudo-TTY."
  8583. Env:
  8584. description: |
  8585. A list of environment variables in the form `["VAR=value", ...]`.
  8586. type: "array"
  8587. items:
  8588. type: "string"
  8589. Cmd:
  8590. type: "array"
  8591. description: "Command to run, as a string or array of strings."
  8592. items:
  8593. type: "string"
  8594. Privileged:
  8595. type: "boolean"
  8596. description: "Runs the exec process with extended privileges."
  8597. default: false
  8598. User:
  8599. type: "string"
  8600. description: |
  8601. The user, and optionally, group to run the exec process inside
  8602. the container. Format is one of: `user`, `user:group`, `uid`,
  8603. or `uid:gid`.
  8604. WorkingDir:
  8605. type: "string"
  8606. description: |
  8607. The working directory for the exec process inside the container.
  8608. example:
  8609. AttachStdin: false
  8610. AttachStdout: true
  8611. AttachStderr: true
  8612. DetachKeys: "ctrl-p,ctrl-q"
  8613. Tty: false
  8614. Cmd:
  8615. - "date"
  8616. Env:
  8617. - "FOO=bar"
  8618. - "BAZ=quux"
  8619. required: true
  8620. - name: "id"
  8621. in: "path"
  8622. description: "ID or name of container"
  8623. type: "string"
  8624. required: true
  8625. tags: ["Exec"]
  8626. /exec/{id}/start:
  8627. post:
  8628. summary: "Start an exec instance"
  8629. description: |
  8630. Starts a previously set up exec instance. If detach is true, this endpoint
  8631. returns immediately after starting the command. Otherwise, it sets up an
  8632. interactive session with the command.
  8633. operationId: "ExecStart"
  8634. consumes:
  8635. - "application/json"
  8636. produces:
  8637. - "application/vnd.docker.raw-stream"
  8638. responses:
  8639. 200:
  8640. description: "No error"
  8641. 404:
  8642. description: "No such exec instance"
  8643. schema:
  8644. $ref: "#/definitions/ErrorResponse"
  8645. 409:
  8646. description: "Container is stopped or paused"
  8647. schema:
  8648. $ref: "#/definitions/ErrorResponse"
  8649. parameters:
  8650. - name: "execStartConfig"
  8651. in: "body"
  8652. schema:
  8653. type: "object"
  8654. title: "ExecStartConfig"
  8655. properties:
  8656. Detach:
  8657. type: "boolean"
  8658. description: "Detach from the command."
  8659. Tty:
  8660. type: "boolean"
  8661. description: "Allocate a pseudo-TTY."
  8662. example:
  8663. Detach: false
  8664. Tty: false
  8665. - name: "id"
  8666. in: "path"
  8667. description: "Exec instance ID"
  8668. required: true
  8669. type: "string"
  8670. tags: ["Exec"]
  8671. /exec/{id}/resize:
  8672. post:
  8673. summary: "Resize an exec instance"
  8674. description: |
  8675. Resize the TTY session used by an exec instance. This endpoint only works
  8676. if `tty` was specified as part of creating and starting the exec instance.
  8677. operationId: "ExecResize"
  8678. responses:
  8679. 200:
  8680. description: "No error"
  8681. 400:
  8682. description: "bad parameter"
  8683. schema:
  8684. $ref: "#/definitions/ErrorResponse"
  8685. 404:
  8686. description: "No such exec instance"
  8687. schema:
  8688. $ref: "#/definitions/ErrorResponse"
  8689. 500:
  8690. description: "Server error"
  8691. schema:
  8692. $ref: "#/definitions/ErrorResponse"
  8693. parameters:
  8694. - name: "id"
  8695. in: "path"
  8696. description: "Exec instance ID"
  8697. required: true
  8698. type: "string"
  8699. - name: "h"
  8700. in: "query"
  8701. description: "Height of the TTY session in characters"
  8702. type: "integer"
  8703. - name: "w"
  8704. in: "query"
  8705. description: "Width of the TTY session in characters"
  8706. type: "integer"
  8707. tags: ["Exec"]
  8708. /exec/{id}/json:
  8709. get:
  8710. summary: "Inspect an exec instance"
  8711. description: "Return low-level information about an exec instance."
  8712. operationId: "ExecInspect"
  8713. produces:
  8714. - "application/json"
  8715. responses:
  8716. 200:
  8717. description: "No error"
  8718. schema:
  8719. type: "object"
  8720. title: "ExecInspectResponse"
  8721. properties:
  8722. CanRemove:
  8723. type: "boolean"
  8724. DetachKeys:
  8725. type: "string"
  8726. ID:
  8727. type: "string"
  8728. Running:
  8729. type: "boolean"
  8730. ExitCode:
  8731. type: "integer"
  8732. ProcessConfig:
  8733. $ref: "#/definitions/ProcessConfig"
  8734. OpenStdin:
  8735. type: "boolean"
  8736. OpenStderr:
  8737. type: "boolean"
  8738. OpenStdout:
  8739. type: "boolean"
  8740. ContainerID:
  8741. type: "string"
  8742. Pid:
  8743. type: "integer"
  8744. description: "The system process ID for the exec process."
  8745. examples:
  8746. application/json:
  8747. CanRemove: false
  8748. ContainerID: "b53ee82b53a40c7dca428523e34f741f3abc51d9f297a14ff874bf761b995126"
  8749. DetachKeys: ""
  8750. ExitCode: 2
  8751. ID: "f33bbfb39f5b142420f4759b2348913bd4a8d1a6d7fd56499cb41a1bb91d7b3b"
  8752. OpenStderr: true
  8753. OpenStdin: true
  8754. OpenStdout: true
  8755. ProcessConfig:
  8756. arguments:
  8757. - "-c"
  8758. - "exit 2"
  8759. entrypoint: "sh"
  8760. privileged: false
  8761. tty: true
  8762. user: "1000"
  8763. Running: false
  8764. Pid: 42000
  8765. 404:
  8766. description: "No such exec instance"
  8767. schema:
  8768. $ref: "#/definitions/ErrorResponse"
  8769. 500:
  8770. description: "Server error"
  8771. schema:
  8772. $ref: "#/definitions/ErrorResponse"
  8773. parameters:
  8774. - name: "id"
  8775. in: "path"
  8776. description: "Exec instance ID"
  8777. required: true
  8778. type: "string"
  8779. tags: ["Exec"]
  8780. /volumes:
  8781. get:
  8782. summary: "List volumes"
  8783. operationId: "VolumeList"
  8784. produces: ["application/json"]
  8785. responses:
  8786. 200:
  8787. description: "Summary volume data that matches the query"
  8788. schema:
  8789. $ref: "#/definitions/VolumeListResponse"
  8790. 500:
  8791. description: "Server error"
  8792. schema:
  8793. $ref: "#/definitions/ErrorResponse"
  8794. parameters:
  8795. - name: "filters"
  8796. in: "query"
  8797. description: |
  8798. JSON encoded value of the filters (a `map[string][]string`) to
  8799. process on the volumes list. Available filters:
  8800. - `dangling=<boolean>` When set to `true` (or `1`), returns all
  8801. volumes that are not in use by a container. When set to `false`
  8802. (or `0`), only volumes that are in use by one or more
  8803. containers are returned.
  8804. - `driver=<volume-driver-name>` Matches volumes based on their driver.
  8805. - `label=<key>` or `label=<key>:<value>` Matches volumes based on
  8806. the presence of a `label` alone or a `label` and a value.
  8807. - `name=<volume-name>` Matches all or part of a volume name.
  8808. type: "string"
  8809. format: "json"
  8810. tags: ["Volume"]
  8811. /volumes/create:
  8812. post:
  8813. summary: "Create a volume"
  8814. operationId: "VolumeCreate"
  8815. consumes: ["application/json"]
  8816. produces: ["application/json"]
  8817. responses:
  8818. 201:
  8819. description: "The volume was created successfully"
  8820. schema:
  8821. $ref: "#/definitions/Volume"
  8822. 500:
  8823. description: "Server error"
  8824. schema:
  8825. $ref: "#/definitions/ErrorResponse"
  8826. parameters:
  8827. - name: "volumeConfig"
  8828. in: "body"
  8829. required: true
  8830. description: "Volume configuration"
  8831. schema:
  8832. $ref: "#/definitions/VolumeCreateOptions"
  8833. tags: ["Volume"]
  8834. /volumes/{name}:
  8835. get:
  8836. summary: "Inspect a volume"
  8837. operationId: "VolumeInspect"
  8838. produces: ["application/json"]
  8839. responses:
  8840. 200:
  8841. description: "No error"
  8842. schema:
  8843. $ref: "#/definitions/Volume"
  8844. 404:
  8845. description: "No such volume"
  8846. schema:
  8847. $ref: "#/definitions/ErrorResponse"
  8848. 500:
  8849. description: "Server error"
  8850. schema:
  8851. $ref: "#/definitions/ErrorResponse"
  8852. parameters:
  8853. - name: "name"
  8854. in: "path"
  8855. required: true
  8856. description: "Volume name or ID"
  8857. type: "string"
  8858. tags: ["Volume"]
  8859. delete:
  8860. summary: "Remove a volume"
  8861. description: "Instruct the driver to remove the volume."
  8862. operationId: "VolumeDelete"
  8863. responses:
  8864. 204:
  8865. description: "The volume was removed"
  8866. 404:
  8867. description: "No such volume or volume driver"
  8868. schema:
  8869. $ref: "#/definitions/ErrorResponse"
  8870. 409:
  8871. description: "Volume is in use and cannot be removed"
  8872. schema:
  8873. $ref: "#/definitions/ErrorResponse"
  8874. 500:
  8875. description: "Server error"
  8876. schema:
  8877. $ref: "#/definitions/ErrorResponse"
  8878. parameters:
  8879. - name: "name"
  8880. in: "path"
  8881. required: true
  8882. description: "Volume name or ID"
  8883. type: "string"
  8884. - name: "force"
  8885. in: "query"
  8886. description: "Force the removal of the volume"
  8887. type: "boolean"
  8888. default: false
  8889. tags: ["Volume"]
  8890. /volumes/prune:
  8891. post:
  8892. summary: "Delete unused volumes"
  8893. produces:
  8894. - "application/json"
  8895. operationId: "VolumePrune"
  8896. parameters:
  8897. - name: "filters"
  8898. in: "query"
  8899. description: |
  8900. Filters to process on the prune list, encoded as JSON (a `map[string][]string`).
  8901. Available filters:
  8902. - `label` (`label=<key>`, `label=<key>=<value>`, `label!=<key>`, or `label!=<key>=<value>`) Prune volumes with (or without, in case `label!=...` is used) the specified labels.
  8903. type: "string"
  8904. responses:
  8905. 200:
  8906. description: "No error"
  8907. schema:
  8908. type: "object"
  8909. title: "VolumePruneResponse"
  8910. properties:
  8911. VolumesDeleted:
  8912. description: "Volumes that were deleted"
  8913. type: "array"
  8914. items:
  8915. type: "string"
  8916. SpaceReclaimed:
  8917. description: "Disk space reclaimed in bytes"
  8918. type: "integer"
  8919. format: "int64"
  8920. 500:
  8921. description: "Server error"
  8922. schema:
  8923. $ref: "#/definitions/ErrorResponse"
  8924. tags: ["Volume"]
  8925. /networks:
  8926. get:
  8927. summary: "List networks"
  8928. description: |
  8929. Returns a list of networks. For details on the format, see the
  8930. [network inspect endpoint](#operation/NetworkInspect).
  8931. Note that it uses a different, smaller representation of a network than
  8932. inspecting a single network. For example, the list of containers attached
  8933. to the network is not propagated in API versions 1.28 and up.
  8934. operationId: "NetworkList"
  8935. produces:
  8936. - "application/json"
  8937. responses:
  8938. 200:
  8939. description: "No error"
  8940. schema:
  8941. type: "array"
  8942. items:
  8943. $ref: "#/definitions/Network"
  8944. examples:
  8945. application/json:
  8946. - Name: "bridge"
  8947. Id: "f2de39df4171b0dc801e8002d1d999b77256983dfc63041c0f34030aa3977566"
  8948. Created: "2016-10-19T06:21:00.416543526Z"
  8949. Scope: "local"
  8950. Driver: "bridge"
  8951. EnableIPv6: false
  8952. Internal: false
  8953. Attachable: false
  8954. Ingress: false
  8955. IPAM:
  8956. Driver: "default"
  8957. Config:
  8958. -
  8959. Subnet: "172.17.0.0/16"
  8960. Options:
  8961. com.docker.network.bridge.default_bridge: "true"
  8962. com.docker.network.bridge.enable_icc: "true"
  8963. com.docker.network.bridge.enable_ip_masquerade: "true"
  8964. com.docker.network.bridge.host_binding_ipv4: "0.0.0.0"
  8965. com.docker.network.bridge.name: "docker0"
  8966. com.docker.network.driver.mtu: "1500"
  8967. - Name: "none"
  8968. Id: "e086a3893b05ab69242d3c44e49483a3bbbd3a26b46baa8f61ab797c1088d794"
  8969. Created: "0001-01-01T00:00:00Z"
  8970. Scope: "local"
  8971. Driver: "null"
  8972. EnableIPv6: false
  8973. Internal: false
  8974. Attachable: false
  8975. Ingress: false
  8976. IPAM:
  8977. Driver: "default"
  8978. Config: []
  8979. Containers: {}
  8980. Options: {}
  8981. - Name: "host"
  8982. Id: "13e871235c677f196c4e1ecebb9dc733b9b2d2ab589e30c539efeda84a24215e"
  8983. Created: "0001-01-01T00:00:00Z"
  8984. Scope: "local"
  8985. Driver: "host"
  8986. EnableIPv6: false
  8987. Internal: false
  8988. Attachable: false
  8989. Ingress: false
  8990. IPAM:
  8991. Driver: "default"
  8992. Config: []
  8993. Containers: {}
  8994. Options: {}
  8995. 500:
  8996. description: "Server error"
  8997. schema:
  8998. $ref: "#/definitions/ErrorResponse"
  8999. parameters:
  9000. - name: "filters"
  9001. in: "query"
  9002. description: |
  9003. JSON encoded value of the filters (a `map[string][]string`) to process
  9004. on the networks list.
  9005. Available filters:
  9006. - `dangling=<boolean>` When set to `true` (or `1`), returns all
  9007. networks that are not in use by a container. When set to `false`
  9008. (or `0`), only networks that are in use by one or more
  9009. containers are returned.
  9010. - `driver=<driver-name>` Matches a network's driver.
  9011. - `id=<network-id>` Matches all or part of a network ID.
  9012. - `label=<key>` or `label=<key>=<value>` of a network label.
  9013. - `name=<network-name>` Matches all or part of a network name.
  9014. - `scope=["swarm"|"global"|"local"]` Filters networks by scope (`swarm`, `global`, or `local`).
  9015. - `type=["custom"|"builtin"]` Filters networks by type. The `custom` keyword returns all user-defined networks.
  9016. type: "string"
  9017. tags: ["Network"]
  9018. /networks/{id}:
  9019. get:
  9020. summary: "Inspect a network"
  9021. operationId: "NetworkInspect"
  9022. produces:
  9023. - "application/json"
  9024. responses:
  9025. 200:
  9026. description: "No error"
  9027. schema:
  9028. $ref: "#/definitions/Network"
  9029. 404:
  9030. description: "Network not found"
  9031. schema:
  9032. $ref: "#/definitions/ErrorResponse"
  9033. 500:
  9034. description: "Server error"
  9035. schema:
  9036. $ref: "#/definitions/ErrorResponse"
  9037. parameters:
  9038. - name: "id"
  9039. in: "path"
  9040. description: "Network ID or name"
  9041. required: true
  9042. type: "string"
  9043. - name: "verbose"
  9044. in: "query"
  9045. description: "Detailed inspect output for troubleshooting"
  9046. type: "boolean"
  9047. default: false
  9048. - name: "scope"
  9049. in: "query"
  9050. description: "Filter the network by scope (swarm, global, or local)"
  9051. type: "string"
  9052. tags: ["Network"]
  9053. delete:
  9054. summary: "Remove a network"
  9055. operationId: "NetworkDelete"
  9056. responses:
  9057. 204:
  9058. description: "No error"
  9059. 403:
  9060. description: "operation not supported for pre-defined networks"
  9061. schema:
  9062. $ref: "#/definitions/ErrorResponse"
  9063. 404:
  9064. description: "no such network"
  9065. schema:
  9066. $ref: "#/definitions/ErrorResponse"
  9067. 500:
  9068. description: "Server error"
  9069. schema:
  9070. $ref: "#/definitions/ErrorResponse"
  9071. parameters:
  9072. - name: "id"
  9073. in: "path"
  9074. description: "Network ID or name"
  9075. required: true
  9076. type: "string"
  9077. tags: ["Network"]
  9078. /networks/create:
  9079. post:
  9080. summary: "Create a network"
  9081. operationId: "NetworkCreate"
  9082. consumes:
  9083. - "application/json"
  9084. produces:
  9085. - "application/json"
  9086. responses:
  9087. 201:
  9088. description: "No error"
  9089. schema:
  9090. type: "object"
  9091. title: "NetworkCreateResponse"
  9092. properties:
  9093. Id:
  9094. description: "The ID of the created network."
  9095. type: "string"
  9096. Warning:
  9097. type: "string"
  9098. example:
  9099. Id: "22be93d5babb089c5aab8dbc369042fad48ff791584ca2da2100db837a1c7c30"
  9100. Warning: ""
  9101. 400:
  9102. description: "bad parameter"
  9103. schema:
  9104. $ref: "#/definitions/ErrorResponse"
  9105. 403:
  9106. description: "operation not supported for pre-defined networks"
  9107. schema:
  9108. $ref: "#/definitions/ErrorResponse"
  9109. 404:
  9110. description: "plugin not found"
  9111. schema:
  9112. $ref: "#/definitions/ErrorResponse"
  9113. 500:
  9114. description: "Server error"
  9115. schema:
  9116. $ref: "#/definitions/ErrorResponse"
  9117. parameters:
  9118. - name: "networkConfig"
  9119. in: "body"
  9120. description: "Network configuration"
  9121. required: true
  9122. schema:
  9123. type: "object"
  9124. title: "NetworkCreateRequest"
  9125. required: ["Name"]
  9126. properties:
  9127. Name:
  9128. description: "The network's name."
  9129. type: "string"
  9130. CheckDuplicate:
  9131. description: |
  9132. Check for networks with duplicate names. Since Network is
  9133. primarily keyed based on a random ID and not on the name, and
  9134. network name is strictly a user-friendly alias to the network
  9135. which is uniquely identified using ID, there is no guaranteed
  9136. way to check for duplicates. CheckDuplicate is there to provide
  9137. a best effort checking of any networks which has the same name
  9138. but it is not guaranteed to catch all name collisions.
  9139. type: "boolean"
  9140. Driver:
  9141. description: "Name of the network driver plugin to use."
  9142. type: "string"
  9143. default: "bridge"
  9144. Internal:
  9145. description: "Restrict external access to the network."
  9146. type: "boolean"
  9147. Attachable:
  9148. description: |
  9149. Globally scoped network is manually attachable by regular
  9150. containers from workers in swarm mode.
  9151. type: "boolean"
  9152. Ingress:
  9153. description: |
  9154. Ingress network is the network which provides the routing-mesh
  9155. in swarm mode.
  9156. type: "boolean"
  9157. IPAM:
  9158. description: "Optional custom IP scheme for the network."
  9159. $ref: "#/definitions/IPAM"
  9160. EnableIPv6:
  9161. description: "Enable IPv6 on the network."
  9162. type: "boolean"
  9163. Options:
  9164. description: "Network specific options to be used by the drivers."
  9165. type: "object"
  9166. additionalProperties:
  9167. type: "string"
  9168. Labels:
  9169. description: "User-defined key/value metadata."
  9170. type: "object"
  9171. additionalProperties:
  9172. type: "string"
  9173. example:
  9174. Name: "isolated_nw"
  9175. CheckDuplicate: false
  9176. Driver: "bridge"
  9177. EnableIPv6: true
  9178. IPAM:
  9179. Driver: "default"
  9180. Config:
  9181. - Subnet: "172.20.0.0/16"
  9182. IPRange: "172.20.10.0/24"
  9183. Gateway: "172.20.10.11"
  9184. - Subnet: "2001:db8:abcd::/64"
  9185. Gateway: "2001:db8:abcd::1011"
  9186. Options:
  9187. foo: "bar"
  9188. Internal: true
  9189. Attachable: false
  9190. Ingress: false
  9191. Options:
  9192. com.docker.network.bridge.default_bridge: "true"
  9193. com.docker.network.bridge.enable_icc: "true"
  9194. com.docker.network.bridge.enable_ip_masquerade: "true"
  9195. com.docker.network.bridge.host_binding_ipv4: "0.0.0.0"
  9196. com.docker.network.bridge.name: "docker0"
  9197. com.docker.network.driver.mtu: "1500"
  9198. Labels:
  9199. com.example.some-label: "some-value"
  9200. com.example.some-other-label: "some-other-value"
  9201. tags: ["Network"]
  9202. /networks/{id}/connect:
  9203. post:
  9204. summary: "Connect a container to a network"
  9205. operationId: "NetworkConnect"
  9206. consumes:
  9207. - "application/json"
  9208. responses:
  9209. 200:
  9210. description: "No error"
  9211. 403:
  9212. description: "Operation not supported for swarm scoped networks"
  9213. schema:
  9214. $ref: "#/definitions/ErrorResponse"
  9215. 404:
  9216. description: "Network or container not found"
  9217. schema:
  9218. $ref: "#/definitions/ErrorResponse"
  9219. 500:
  9220. description: "Server error"
  9221. schema:
  9222. $ref: "#/definitions/ErrorResponse"
  9223. parameters:
  9224. - name: "id"
  9225. in: "path"
  9226. description: "Network ID or name"
  9227. required: true
  9228. type: "string"
  9229. - name: "container"
  9230. in: "body"
  9231. required: true
  9232. schema:
  9233. type: "object"
  9234. title: "NetworkDisconnectRequest"
  9235. properties:
  9236. Container:
  9237. type: "string"
  9238. description: "The ID or name of the container to connect to the network."
  9239. EndpointConfig:
  9240. $ref: "#/definitions/EndpointSettings"
  9241. example:
  9242. Container: "3613f73ba0e4"
  9243. EndpointConfig:
  9244. IPAMConfig:
  9245. IPv4Address: "172.24.56.89"
  9246. IPv6Address: "2001:db8::5689"
  9247. tags: ["Network"]
  9248. /networks/{id}/disconnect:
  9249. post:
  9250. summary: "Disconnect a container from a network"
  9251. operationId: "NetworkDisconnect"
  9252. consumes:
  9253. - "application/json"
  9254. responses:
  9255. 200:
  9256. description: "No error"
  9257. 403:
  9258. description: "Operation not supported for swarm scoped networks"
  9259. schema:
  9260. $ref: "#/definitions/ErrorResponse"
  9261. 404:
  9262. description: "Network or container not found"
  9263. schema:
  9264. $ref: "#/definitions/ErrorResponse"
  9265. 500:
  9266. description: "Server error"
  9267. schema:
  9268. $ref: "#/definitions/ErrorResponse"
  9269. parameters:
  9270. - name: "id"
  9271. in: "path"
  9272. description: "Network ID or name"
  9273. required: true
  9274. type: "string"
  9275. - name: "container"
  9276. in: "body"
  9277. required: true
  9278. schema:
  9279. type: "object"
  9280. title: "NetworkConnectRequest"
  9281. properties:
  9282. Container:
  9283. type: "string"
  9284. description: |
  9285. The ID or name of the container to disconnect from the network.
  9286. Force:
  9287. type: "boolean"
  9288. description: |
  9289. Force the container to disconnect from the network.
  9290. tags: ["Network"]
  9291. /networks/prune:
  9292. post:
  9293. summary: "Delete unused networks"
  9294. produces:
  9295. - "application/json"
  9296. operationId: "NetworkPrune"
  9297. parameters:
  9298. - name: "filters"
  9299. in: "query"
  9300. description: |
  9301. Filters to process on the prune list, encoded as JSON (a `map[string][]string`).
  9302. Available filters:
  9303. - `until=<timestamp>` Prune networks created before this timestamp. The `<timestamp>` can be Unix timestamps, date formatted timestamps, or Go duration strings (e.g. `10m`, `1h30m`) computed relative to the daemon machine’s time.
  9304. - `label` (`label=<key>`, `label=<key>=<value>`, `label!=<key>`, or `label!=<key>=<value>`) Prune networks with (or without, in case `label!=...` is used) the specified labels.
  9305. type: "string"
  9306. responses:
  9307. 200:
  9308. description: "No error"
  9309. schema:
  9310. type: "object"
  9311. title: "NetworkPruneResponse"
  9312. properties:
  9313. NetworksDeleted:
  9314. description: "Networks that were deleted"
  9315. type: "array"
  9316. items:
  9317. type: "string"
  9318. 500:
  9319. description: "Server error"
  9320. schema:
  9321. $ref: "#/definitions/ErrorResponse"
  9322. tags: ["Network"]
  9323. /plugins:
  9324. get:
  9325. summary: "List plugins"
  9326. operationId: "PluginList"
  9327. description: "Returns information about installed plugins."
  9328. produces: ["application/json"]
  9329. responses:
  9330. 200:
  9331. description: "No error"
  9332. schema:
  9333. type: "array"
  9334. items:
  9335. $ref: "#/definitions/Plugin"
  9336. 500:
  9337. description: "Server error"
  9338. schema:
  9339. $ref: "#/definitions/ErrorResponse"
  9340. parameters:
  9341. - name: "filters"
  9342. in: "query"
  9343. type: "string"
  9344. description: |
  9345. A JSON encoded value of the filters (a `map[string][]string`) to
  9346. process on the plugin list.
  9347. Available filters:
  9348. - `capability=<capability name>`
  9349. - `enable=<true>|<false>`
  9350. tags: ["Plugin"]
  9351. /plugins/privileges:
  9352. get:
  9353. summary: "Get plugin privileges"
  9354. operationId: "GetPluginPrivileges"
  9355. responses:
  9356. 200:
  9357. description: "no error"
  9358. schema:
  9359. type: "array"
  9360. items:
  9361. $ref: "#/definitions/PluginPrivilege"
  9362. example:
  9363. - Name: "network"
  9364. Description: ""
  9365. Value:
  9366. - "host"
  9367. - Name: "mount"
  9368. Description: ""
  9369. Value:
  9370. - "/data"
  9371. - Name: "device"
  9372. Description: ""
  9373. Value:
  9374. - "/dev/cpu_dma_latency"
  9375. 500:
  9376. description: "server error"
  9377. schema:
  9378. $ref: "#/definitions/ErrorResponse"
  9379. parameters:
  9380. - name: "remote"
  9381. in: "query"
  9382. description: |
  9383. The name of the plugin. The `:latest` tag is optional, and is the
  9384. default if omitted.
  9385. required: true
  9386. type: "string"
  9387. tags:
  9388. - "Plugin"
  9389. /plugins/pull:
  9390. post:
  9391. summary: "Install a plugin"
  9392. operationId: "PluginPull"
  9393. description: |
  9394. Pulls and installs a plugin. After the plugin is installed, it can be
  9395. enabled using the [`POST /plugins/{name}/enable` endpoint](#operation/PostPluginsEnable).
  9396. produces:
  9397. - "application/json"
  9398. responses:
  9399. 204:
  9400. description: "no error"
  9401. 500:
  9402. description: "server error"
  9403. schema:
  9404. $ref: "#/definitions/ErrorResponse"
  9405. parameters:
  9406. - name: "remote"
  9407. in: "query"
  9408. description: |
  9409. Remote reference for plugin to install.
  9410. The `:latest` tag is optional, and is used as the default if omitted.
  9411. required: true
  9412. type: "string"
  9413. - name: "name"
  9414. in: "query"
  9415. description: |
  9416. Local name for the pulled plugin.
  9417. The `:latest` tag is optional, and is used as the default if omitted.
  9418. required: false
  9419. type: "string"
  9420. - name: "X-Registry-Auth"
  9421. in: "header"
  9422. description: |
  9423. A base64url-encoded auth configuration to use when pulling a plugin
  9424. from a registry.
  9425. Refer to the [authentication section](#section/Authentication) for
  9426. details.
  9427. type: "string"
  9428. - name: "body"
  9429. in: "body"
  9430. schema:
  9431. type: "array"
  9432. items:
  9433. $ref: "#/definitions/PluginPrivilege"
  9434. example:
  9435. - Name: "network"
  9436. Description: ""
  9437. Value:
  9438. - "host"
  9439. - Name: "mount"
  9440. Description: ""
  9441. Value:
  9442. - "/data"
  9443. - Name: "device"
  9444. Description: ""
  9445. Value:
  9446. - "/dev/cpu_dma_latency"
  9447. tags: ["Plugin"]
  9448. /plugins/{name}/json:
  9449. get:
  9450. summary: "Inspect a plugin"
  9451. operationId: "PluginInspect"
  9452. responses:
  9453. 200:
  9454. description: "no error"
  9455. schema:
  9456. $ref: "#/definitions/Plugin"
  9457. 404:
  9458. description: "plugin is not installed"
  9459. schema:
  9460. $ref: "#/definitions/ErrorResponse"
  9461. 500:
  9462. description: "server error"
  9463. schema:
  9464. $ref: "#/definitions/ErrorResponse"
  9465. parameters:
  9466. - name: "name"
  9467. in: "path"
  9468. description: |
  9469. The name of the plugin. The `:latest` tag is optional, and is the
  9470. default if omitted.
  9471. required: true
  9472. type: "string"
  9473. tags: ["Plugin"]
  9474. /plugins/{name}:
  9475. delete:
  9476. summary: "Remove a plugin"
  9477. operationId: "PluginDelete"
  9478. responses:
  9479. 200:
  9480. description: "no error"
  9481. schema:
  9482. $ref: "#/definitions/Plugin"
  9483. 404:
  9484. description: "plugin is not installed"
  9485. schema:
  9486. $ref: "#/definitions/ErrorResponse"
  9487. 500:
  9488. description: "server error"
  9489. schema:
  9490. $ref: "#/definitions/ErrorResponse"
  9491. parameters:
  9492. - name: "name"
  9493. in: "path"
  9494. description: |
  9495. The name of the plugin. The `:latest` tag is optional, and is the
  9496. default if omitted.
  9497. required: true
  9498. type: "string"
  9499. - name: "force"
  9500. in: "query"
  9501. description: |
  9502. Disable the plugin before removing. This may result in issues if the
  9503. plugin is in use by a container.
  9504. type: "boolean"
  9505. default: false
  9506. tags: ["Plugin"]
  9507. /plugins/{name}/enable:
  9508. post:
  9509. summary: "Enable a plugin"
  9510. operationId: "PluginEnable"
  9511. responses:
  9512. 200:
  9513. description: "no error"
  9514. 404:
  9515. description: "plugin is not installed"
  9516. schema:
  9517. $ref: "#/definitions/ErrorResponse"
  9518. 500:
  9519. description: "server error"
  9520. schema:
  9521. $ref: "#/definitions/ErrorResponse"
  9522. parameters:
  9523. - name: "name"
  9524. in: "path"
  9525. description: |
  9526. The name of the plugin. The `:latest` tag is optional, and is the
  9527. default if omitted.
  9528. required: true
  9529. type: "string"
  9530. - name: "timeout"
  9531. in: "query"
  9532. description: "Set the HTTP client timeout (in seconds)"
  9533. type: "integer"
  9534. default: 0
  9535. tags: ["Plugin"]
  9536. /plugins/{name}/disable:
  9537. post:
  9538. summary: "Disable a plugin"
  9539. operationId: "PluginDisable"
  9540. responses:
  9541. 200:
  9542. description: "no error"
  9543. 404:
  9544. description: "plugin is not installed"
  9545. schema:
  9546. $ref: "#/definitions/ErrorResponse"
  9547. 500:
  9548. description: "server error"
  9549. schema:
  9550. $ref: "#/definitions/ErrorResponse"
  9551. parameters:
  9552. - name: "name"
  9553. in: "path"
  9554. description: |
  9555. The name of the plugin. The `:latest` tag is optional, and is the
  9556. default if omitted.
  9557. required: true
  9558. type: "string"
  9559. - name: "force"
  9560. in: "query"
  9561. description: |
  9562. Force disable a plugin even if still in use.
  9563. required: false
  9564. type: "boolean"
  9565. tags: ["Plugin"]
  9566. /plugins/{name}/upgrade:
  9567. post:
  9568. summary: "Upgrade a plugin"
  9569. operationId: "PluginUpgrade"
  9570. responses:
  9571. 204:
  9572. description: "no error"
  9573. 404:
  9574. description: "plugin not installed"
  9575. schema:
  9576. $ref: "#/definitions/ErrorResponse"
  9577. 500:
  9578. description: "server error"
  9579. schema:
  9580. $ref: "#/definitions/ErrorResponse"
  9581. parameters:
  9582. - name: "name"
  9583. in: "path"
  9584. description: |
  9585. The name of the plugin. The `:latest` tag is optional, and is the
  9586. default if omitted.
  9587. required: true
  9588. type: "string"
  9589. - name: "remote"
  9590. in: "query"
  9591. description: |
  9592. Remote reference to upgrade to.
  9593. The `:latest` tag is optional, and is used as the default if omitted.
  9594. required: true
  9595. type: "string"
  9596. - name: "X-Registry-Auth"
  9597. in: "header"
  9598. description: |
  9599. A base64url-encoded auth configuration to use when pulling a plugin
  9600. from a registry.
  9601. Refer to the [authentication section](#section/Authentication) for
  9602. details.
  9603. type: "string"
  9604. - name: "body"
  9605. in: "body"
  9606. schema:
  9607. type: "array"
  9608. items:
  9609. $ref: "#/definitions/PluginPrivilege"
  9610. example:
  9611. - Name: "network"
  9612. Description: ""
  9613. Value:
  9614. - "host"
  9615. - Name: "mount"
  9616. Description: ""
  9617. Value:
  9618. - "/data"
  9619. - Name: "device"
  9620. Description: ""
  9621. Value:
  9622. - "/dev/cpu_dma_latency"
  9623. tags: ["Plugin"]
  9624. /plugins/create:
  9625. post:
  9626. summary: "Create a plugin"
  9627. operationId: "PluginCreate"
  9628. consumes:
  9629. - "application/x-tar"
  9630. responses:
  9631. 204:
  9632. description: "no error"
  9633. 500:
  9634. description: "server error"
  9635. schema:
  9636. $ref: "#/definitions/ErrorResponse"
  9637. parameters:
  9638. - name: "name"
  9639. in: "query"
  9640. description: |
  9641. The name of the plugin. The `:latest` tag is optional, and is the
  9642. default if omitted.
  9643. required: true
  9644. type: "string"
  9645. - name: "tarContext"
  9646. in: "body"
  9647. description: "Path to tar containing plugin rootfs and manifest"
  9648. schema:
  9649. type: "string"
  9650. format: "binary"
  9651. tags: ["Plugin"]
  9652. /plugins/{name}/push:
  9653. post:
  9654. summary: "Push a plugin"
  9655. operationId: "PluginPush"
  9656. description: |
  9657. Push a plugin to the registry.
  9658. parameters:
  9659. - name: "name"
  9660. in: "path"
  9661. description: |
  9662. The name of the plugin. The `:latest` tag is optional, and is the
  9663. default if omitted.
  9664. required: true
  9665. type: "string"
  9666. responses:
  9667. 200:
  9668. description: "no error"
  9669. 404:
  9670. description: "plugin not installed"
  9671. schema:
  9672. $ref: "#/definitions/ErrorResponse"
  9673. 500:
  9674. description: "server error"
  9675. schema:
  9676. $ref: "#/definitions/ErrorResponse"
  9677. tags: ["Plugin"]
  9678. /plugins/{name}/set:
  9679. post:
  9680. summary: "Configure a plugin"
  9681. operationId: "PluginSet"
  9682. consumes:
  9683. - "application/json"
  9684. parameters:
  9685. - name: "name"
  9686. in: "path"
  9687. description: |
  9688. The name of the plugin. The `:latest` tag is optional, and is the
  9689. default if omitted.
  9690. required: true
  9691. type: "string"
  9692. - name: "body"
  9693. in: "body"
  9694. schema:
  9695. type: "array"
  9696. items:
  9697. type: "string"
  9698. example: ["DEBUG=1"]
  9699. responses:
  9700. 204:
  9701. description: "No error"
  9702. 404:
  9703. description: "Plugin not installed"
  9704. schema:
  9705. $ref: "#/definitions/ErrorResponse"
  9706. 500:
  9707. description: "Server error"
  9708. schema:
  9709. $ref: "#/definitions/ErrorResponse"
  9710. tags: ["Plugin"]
  9711. /nodes:
  9712. get:
  9713. summary: "List nodes"
  9714. operationId: "NodeList"
  9715. responses:
  9716. 200:
  9717. description: "no error"
  9718. schema:
  9719. type: "array"
  9720. items:
  9721. $ref: "#/definitions/Node"
  9722. 500:
  9723. description: "server error"
  9724. schema:
  9725. $ref: "#/definitions/ErrorResponse"
  9726. 503:
  9727. description: "node is not part of a swarm"
  9728. schema:
  9729. $ref: "#/definitions/ErrorResponse"
  9730. parameters:
  9731. - name: "filters"
  9732. in: "query"
  9733. description: |
  9734. Filters to process on the nodes list, encoded as JSON (a `map[string][]string`).
  9735. Available filters:
  9736. - `id=<node id>`
  9737. - `label=<engine label>`
  9738. - `membership=`(`accepted`|`pending`)`
  9739. - `name=<node name>`
  9740. - `node.label=<node label>`
  9741. - `role=`(`manager`|`worker`)`
  9742. type: "string"
  9743. tags: ["Node"]
  9744. /nodes/{id}:
  9745. get:
  9746. summary: "Inspect a node"
  9747. operationId: "NodeInspect"
  9748. responses:
  9749. 200:
  9750. description: "no error"
  9751. schema:
  9752. $ref: "#/definitions/Node"
  9753. 404:
  9754. description: "no such node"
  9755. schema:
  9756. $ref: "#/definitions/ErrorResponse"
  9757. 500:
  9758. description: "server error"
  9759. schema:
  9760. $ref: "#/definitions/ErrorResponse"
  9761. 503:
  9762. description: "node is not part of a swarm"
  9763. schema:
  9764. $ref: "#/definitions/ErrorResponse"
  9765. parameters:
  9766. - name: "id"
  9767. in: "path"
  9768. description: "The ID or name of the node"
  9769. type: "string"
  9770. required: true
  9771. tags: ["Node"]
  9772. delete:
  9773. summary: "Delete a node"
  9774. operationId: "NodeDelete"
  9775. responses:
  9776. 200:
  9777. description: "no error"
  9778. 404:
  9779. description: "no such node"
  9780. schema:
  9781. $ref: "#/definitions/ErrorResponse"
  9782. 500:
  9783. description: "server error"
  9784. schema:
  9785. $ref: "#/definitions/ErrorResponse"
  9786. 503:
  9787. description: "node is not part of a swarm"
  9788. schema:
  9789. $ref: "#/definitions/ErrorResponse"
  9790. parameters:
  9791. - name: "id"
  9792. in: "path"
  9793. description: "The ID or name of the node"
  9794. type: "string"
  9795. required: true
  9796. - name: "force"
  9797. in: "query"
  9798. description: "Force remove a node from the swarm"
  9799. default: false
  9800. type: "boolean"
  9801. tags: ["Node"]
  9802. /nodes/{id}/update:
  9803. post:
  9804. summary: "Update a node"
  9805. operationId: "NodeUpdate"
  9806. responses:
  9807. 200:
  9808. description: "no error"
  9809. 400:
  9810. description: "bad parameter"
  9811. schema:
  9812. $ref: "#/definitions/ErrorResponse"
  9813. 404:
  9814. description: "no such node"
  9815. schema:
  9816. $ref: "#/definitions/ErrorResponse"
  9817. 500:
  9818. description: "server error"
  9819. schema:
  9820. $ref: "#/definitions/ErrorResponse"
  9821. 503:
  9822. description: "node is not part of a swarm"
  9823. schema:
  9824. $ref: "#/definitions/ErrorResponse"
  9825. parameters:
  9826. - name: "id"
  9827. in: "path"
  9828. description: "The ID of the node"
  9829. type: "string"
  9830. required: true
  9831. - name: "body"
  9832. in: "body"
  9833. schema:
  9834. $ref: "#/definitions/NodeSpec"
  9835. - name: "version"
  9836. in: "query"
  9837. description: |
  9838. The version number of the node object being updated. This is required
  9839. to avoid conflicting writes.
  9840. type: "integer"
  9841. format: "int64"
  9842. required: true
  9843. tags: ["Node"]
  9844. /swarm:
  9845. get:
  9846. summary: "Inspect swarm"
  9847. operationId: "SwarmInspect"
  9848. responses:
  9849. 200:
  9850. description: "no error"
  9851. schema:
  9852. $ref: "#/definitions/Swarm"
  9853. 404:
  9854. description: "no such swarm"
  9855. schema:
  9856. $ref: "#/definitions/ErrorResponse"
  9857. 500:
  9858. description: "server error"
  9859. schema:
  9860. $ref: "#/definitions/ErrorResponse"
  9861. 503:
  9862. description: "node is not part of a swarm"
  9863. schema:
  9864. $ref: "#/definitions/ErrorResponse"
  9865. tags: ["Swarm"]
  9866. /swarm/init:
  9867. post:
  9868. summary: "Initialize a new swarm"
  9869. operationId: "SwarmInit"
  9870. produces:
  9871. - "application/json"
  9872. - "text/plain"
  9873. responses:
  9874. 200:
  9875. description: "no error"
  9876. schema:
  9877. description: "The node ID"
  9878. type: "string"
  9879. example: "7v2t30z9blmxuhnyo6s4cpenp"
  9880. 400:
  9881. description: "bad parameter"
  9882. schema:
  9883. $ref: "#/definitions/ErrorResponse"
  9884. 500:
  9885. description: "server error"
  9886. schema:
  9887. $ref: "#/definitions/ErrorResponse"
  9888. 503:
  9889. description: "node is already part of a swarm"
  9890. schema:
  9891. $ref: "#/definitions/ErrorResponse"
  9892. parameters:
  9893. - name: "body"
  9894. in: "body"
  9895. required: true
  9896. schema:
  9897. type: "object"
  9898. title: "SwarmInitRequest"
  9899. properties:
  9900. ListenAddr:
  9901. description: |
  9902. Listen address used for inter-manager communication, as well
  9903. as determining the networking interface used for the VXLAN
  9904. Tunnel Endpoint (VTEP). This can either be an address/port
  9905. combination in the form `192.168.1.1:4567`, or an interface
  9906. followed by a port number, like `eth0:4567`. If the port number
  9907. is omitted, the default swarm listening port is used.
  9908. type: "string"
  9909. AdvertiseAddr:
  9910. description: |
  9911. Externally reachable address advertised to other nodes. This
  9912. can either be an address/port combination in the form
  9913. `192.168.1.1:4567`, or an interface followed by a port number,
  9914. like `eth0:4567`. If the port number is omitted, the port
  9915. number from the listen address is used. If `AdvertiseAddr` is
  9916. not specified, it will be automatically detected when possible.
  9917. type: "string"
  9918. DataPathAddr:
  9919. description: |
  9920. Address or interface to use for data path traffic (format:
  9921. `<ip|interface>`), for example, `192.168.1.1`, or an interface,
  9922. like `eth0`. If `DataPathAddr` is unspecified, the same address
  9923. as `AdvertiseAddr` is used.
  9924. The `DataPathAddr` specifies the address that global scope
  9925. network drivers will publish towards other nodes in order to
  9926. reach the containers running on this node. Using this parameter
  9927. it is possible to separate the container data traffic from the
  9928. management traffic of the cluster.
  9929. type: "string"
  9930. DataPathPort:
  9931. description: |
  9932. DataPathPort specifies the data path port number for data traffic.
  9933. Acceptable port range is 1024 to 49151.
  9934. if no port is set or is set to 0, default port 4789 will be used.
  9935. type: "integer"
  9936. format: "uint32"
  9937. DefaultAddrPool:
  9938. description: |
  9939. Default Address Pool specifies default subnet pools for global
  9940. scope networks.
  9941. type: "array"
  9942. items:
  9943. type: "string"
  9944. example: ["10.10.0.0/16", "20.20.0.0/16"]
  9945. ForceNewCluster:
  9946. description: "Force creation of a new swarm."
  9947. type: "boolean"
  9948. SubnetSize:
  9949. description: |
  9950. SubnetSize specifies the subnet size of the networks created
  9951. from the default subnet pool.
  9952. type: "integer"
  9953. format: "uint32"
  9954. Spec:
  9955. $ref: "#/definitions/SwarmSpec"
  9956. example:
  9957. ListenAddr: "0.0.0.0:2377"
  9958. AdvertiseAddr: "192.168.1.1:2377"
  9959. DataPathPort: 4789
  9960. DefaultAddrPool: ["10.10.0.0/8", "20.20.0.0/8"]
  9961. SubnetSize: 24
  9962. ForceNewCluster: false
  9963. Spec:
  9964. Orchestration: {}
  9965. Raft: {}
  9966. Dispatcher: {}
  9967. CAConfig: {}
  9968. EncryptionConfig:
  9969. AutoLockManagers: false
  9970. tags: ["Swarm"]
  9971. /swarm/join:
  9972. post:
  9973. summary: "Join an existing swarm"
  9974. operationId: "SwarmJoin"
  9975. responses:
  9976. 200:
  9977. description: "no error"
  9978. 400:
  9979. description: "bad parameter"
  9980. schema:
  9981. $ref: "#/definitions/ErrorResponse"
  9982. 500:
  9983. description: "server error"
  9984. schema:
  9985. $ref: "#/definitions/ErrorResponse"
  9986. 503:
  9987. description: "node is already part of a swarm"
  9988. schema:
  9989. $ref: "#/definitions/ErrorResponse"
  9990. parameters:
  9991. - name: "body"
  9992. in: "body"
  9993. required: true
  9994. schema:
  9995. type: "object"
  9996. title: "SwarmJoinRequest"
  9997. properties:
  9998. ListenAddr:
  9999. description: |
  10000. Listen address used for inter-manager communication if the node
  10001. gets promoted to manager, as well as determining the networking
  10002. interface used for the VXLAN Tunnel Endpoint (VTEP).
  10003. type: "string"
  10004. AdvertiseAddr:
  10005. description: |
  10006. Externally reachable address advertised to other nodes. This
  10007. can either be an address/port combination in the form
  10008. `192.168.1.1:4567`, or an interface followed by a port number,
  10009. like `eth0:4567`. If the port number is omitted, the port
  10010. number from the listen address is used. If `AdvertiseAddr` is
  10011. not specified, it will be automatically detected when possible.
  10012. type: "string"
  10013. DataPathAddr:
  10014. description: |
  10015. Address or interface to use for data path traffic (format:
  10016. `<ip|interface>`), for example, `192.168.1.1`, or an interface,
  10017. like `eth0`. If `DataPathAddr` is unspecified, the same address
  10018. as `AdvertiseAddr` is used.
  10019. The `DataPathAddr` specifies the address that global scope
  10020. network drivers will publish towards other nodes in order to
  10021. reach the containers running on this node. Using this parameter
  10022. it is possible to separate the container data traffic from the
  10023. management traffic of the cluster.
  10024. type: "string"
  10025. RemoteAddrs:
  10026. description: |
  10027. Addresses of manager nodes already participating in the swarm.
  10028. type: "array"
  10029. items:
  10030. type: "string"
  10031. JoinToken:
  10032. description: "Secret token for joining this swarm."
  10033. type: "string"
  10034. example:
  10035. ListenAddr: "0.0.0.0:2377"
  10036. AdvertiseAddr: "192.168.1.1:2377"
  10037. RemoteAddrs:
  10038. - "node1:2377"
  10039. JoinToken: "SWMTKN-1-3pu6hszjas19xyp7ghgosyx9k8atbfcr8p2is99znpy26u2lkl-7p73s1dx5in4tatdymyhg9hu2"
  10040. tags: ["Swarm"]
  10041. /swarm/leave:
  10042. post:
  10043. summary: "Leave a swarm"
  10044. operationId: "SwarmLeave"
  10045. responses:
  10046. 200:
  10047. description: "no error"
  10048. 500:
  10049. description: "server error"
  10050. schema:
  10051. $ref: "#/definitions/ErrorResponse"
  10052. 503:
  10053. description: "node is not part of a swarm"
  10054. schema:
  10055. $ref: "#/definitions/ErrorResponse"
  10056. parameters:
  10057. - name: "force"
  10058. description: |
  10059. Force leave swarm, even if this is the last manager or that it will
  10060. break the cluster.
  10061. in: "query"
  10062. type: "boolean"
  10063. default: false
  10064. tags: ["Swarm"]
  10065. /swarm/update:
  10066. post:
  10067. summary: "Update a swarm"
  10068. operationId: "SwarmUpdate"
  10069. responses:
  10070. 200:
  10071. description: "no error"
  10072. 400:
  10073. description: "bad parameter"
  10074. schema:
  10075. $ref: "#/definitions/ErrorResponse"
  10076. 500:
  10077. description: "server error"
  10078. schema:
  10079. $ref: "#/definitions/ErrorResponse"
  10080. 503:
  10081. description: "node is not part of a swarm"
  10082. schema:
  10083. $ref: "#/definitions/ErrorResponse"
  10084. parameters:
  10085. - name: "body"
  10086. in: "body"
  10087. required: true
  10088. schema:
  10089. $ref: "#/definitions/SwarmSpec"
  10090. - name: "version"
  10091. in: "query"
  10092. description: |
  10093. The version number of the swarm object being updated. This is
  10094. required to avoid conflicting writes.
  10095. type: "integer"
  10096. format: "int64"
  10097. required: true
  10098. - name: "rotateWorkerToken"
  10099. in: "query"
  10100. description: "Rotate the worker join token."
  10101. type: "boolean"
  10102. default: false
  10103. - name: "rotateManagerToken"
  10104. in: "query"
  10105. description: "Rotate the manager join token."
  10106. type: "boolean"
  10107. default: false
  10108. - name: "rotateManagerUnlockKey"
  10109. in: "query"
  10110. description: "Rotate the manager unlock key."
  10111. type: "boolean"
  10112. default: false
  10113. tags: ["Swarm"]
  10114. /swarm/unlockkey:
  10115. get:
  10116. summary: "Get the unlock key"
  10117. operationId: "SwarmUnlockkey"
  10118. consumes:
  10119. - "application/json"
  10120. responses:
  10121. 200:
  10122. description: "no error"
  10123. schema:
  10124. type: "object"
  10125. title: "UnlockKeyResponse"
  10126. properties:
  10127. UnlockKey:
  10128. description: "The swarm's unlock key."
  10129. type: "string"
  10130. example:
  10131. UnlockKey: "SWMKEY-1-7c37Cc8654o6p38HnroywCi19pllOnGtbdZEgtKxZu8"
  10132. 500:
  10133. description: "server error"
  10134. schema:
  10135. $ref: "#/definitions/ErrorResponse"
  10136. 503:
  10137. description: "node is not part of a swarm"
  10138. schema:
  10139. $ref: "#/definitions/ErrorResponse"
  10140. tags: ["Swarm"]
  10141. /swarm/unlock:
  10142. post:
  10143. summary: "Unlock a locked manager"
  10144. operationId: "SwarmUnlock"
  10145. consumes:
  10146. - "application/json"
  10147. produces:
  10148. - "application/json"
  10149. parameters:
  10150. - name: "body"
  10151. in: "body"
  10152. required: true
  10153. schema:
  10154. type: "object"
  10155. title: "SwarmUnlockRequest"
  10156. properties:
  10157. UnlockKey:
  10158. description: "The swarm's unlock key."
  10159. type: "string"
  10160. example:
  10161. UnlockKey: "SWMKEY-1-7c37Cc8654o6p38HnroywCi19pllOnGtbdZEgtKxZu8"
  10162. responses:
  10163. 200:
  10164. description: "no error"
  10165. 500:
  10166. description: "server error"
  10167. schema:
  10168. $ref: "#/definitions/ErrorResponse"
  10169. 503:
  10170. description: "node is not part of a swarm"
  10171. schema:
  10172. $ref: "#/definitions/ErrorResponse"
  10173. tags: ["Swarm"]
  10174. /services:
  10175. get:
  10176. summary: "List services"
  10177. operationId: "ServiceList"
  10178. responses:
  10179. 200:
  10180. description: "no error"
  10181. schema:
  10182. type: "array"
  10183. items:
  10184. $ref: "#/definitions/Service"
  10185. 500:
  10186. description: "server error"
  10187. schema:
  10188. $ref: "#/definitions/ErrorResponse"
  10189. 503:
  10190. description: "node is not part of a swarm"
  10191. schema:
  10192. $ref: "#/definitions/ErrorResponse"
  10193. parameters:
  10194. - name: "filters"
  10195. in: "query"
  10196. type: "string"
  10197. description: |
  10198. A JSON encoded value of the filters (a `map[string][]string`) to
  10199. process on the services list.
  10200. Available filters:
  10201. - `id=<service id>`
  10202. - `label=<service label>`
  10203. - `mode=["replicated"|"global"]`
  10204. - `name=<service name>`
  10205. - name: "status"
  10206. in: "query"
  10207. type: "boolean"
  10208. description: |
  10209. Include service status, with count of running and desired tasks.
  10210. tags: ["Service"]
  10211. /services/create:
  10212. post:
  10213. summary: "Create a service"
  10214. operationId: "ServiceCreate"
  10215. consumes:
  10216. - "application/json"
  10217. produces:
  10218. - "application/json"
  10219. responses:
  10220. 201:
  10221. description: "no error"
  10222. schema:
  10223. type: "object"
  10224. title: "ServiceCreateResponse"
  10225. properties:
  10226. ID:
  10227. description: "The ID of the created service."
  10228. type: "string"
  10229. Warning:
  10230. description: "Optional warning message"
  10231. type: "string"
  10232. example:
  10233. ID: "ak7w3gjqoa3kuz8xcpnyy0pvl"
  10234. Warning: "unable to pin image doesnotexist:latest to digest: image library/doesnotexist:latest not found"
  10235. 400:
  10236. description: "bad parameter"
  10237. schema:
  10238. $ref: "#/definitions/ErrorResponse"
  10239. 403:
  10240. description: "network is not eligible for services"
  10241. schema:
  10242. $ref: "#/definitions/ErrorResponse"
  10243. 409:
  10244. description: "name conflicts with an existing service"
  10245. schema:
  10246. $ref: "#/definitions/ErrorResponse"
  10247. 500:
  10248. description: "server error"
  10249. schema:
  10250. $ref: "#/definitions/ErrorResponse"
  10251. 503:
  10252. description: "node is not part of a swarm"
  10253. schema:
  10254. $ref: "#/definitions/ErrorResponse"
  10255. parameters:
  10256. - name: "body"
  10257. in: "body"
  10258. required: true
  10259. schema:
  10260. allOf:
  10261. - $ref: "#/definitions/ServiceSpec"
  10262. - type: "object"
  10263. example:
  10264. Name: "web"
  10265. TaskTemplate:
  10266. ContainerSpec:
  10267. Image: "nginx:alpine"
  10268. Mounts:
  10269. -
  10270. ReadOnly: true
  10271. Source: "web-data"
  10272. Target: "/usr/share/nginx/html"
  10273. Type: "volume"
  10274. VolumeOptions:
  10275. DriverConfig: {}
  10276. Labels:
  10277. com.example.something: "something-value"
  10278. Hosts: ["10.10.10.10 host1", "ABCD:EF01:2345:6789:ABCD:EF01:2345:6789 host2"]
  10279. User: "33"
  10280. DNSConfig:
  10281. Nameservers: ["8.8.8.8"]
  10282. Search: ["example.org"]
  10283. Options: ["timeout:3"]
  10284. Secrets:
  10285. -
  10286. File:
  10287. Name: "www.example.org.key"
  10288. UID: "33"
  10289. GID: "33"
  10290. Mode: 384
  10291. SecretID: "fpjqlhnwb19zds35k8wn80lq9"
  10292. SecretName: "example_org_domain_key"
  10293. LogDriver:
  10294. Name: "json-file"
  10295. Options:
  10296. max-file: "3"
  10297. max-size: "10M"
  10298. Placement: {}
  10299. Resources:
  10300. Limits:
  10301. MemoryBytes: 104857600
  10302. Reservations: {}
  10303. RestartPolicy:
  10304. Condition: "on-failure"
  10305. Delay: 10000000000
  10306. MaxAttempts: 10
  10307. Mode:
  10308. Replicated:
  10309. Replicas: 4
  10310. UpdateConfig:
  10311. Parallelism: 2
  10312. Delay: 1000000000
  10313. FailureAction: "pause"
  10314. Monitor: 15000000000
  10315. MaxFailureRatio: 0.15
  10316. RollbackConfig:
  10317. Parallelism: 1
  10318. Delay: 1000000000
  10319. FailureAction: "pause"
  10320. Monitor: 15000000000
  10321. MaxFailureRatio: 0.15
  10322. EndpointSpec:
  10323. Ports:
  10324. -
  10325. Protocol: "tcp"
  10326. PublishedPort: 8080
  10327. TargetPort: 80
  10328. Labels:
  10329. foo: "bar"
  10330. - name: "X-Registry-Auth"
  10331. in: "header"
  10332. description: |
  10333. A base64url-encoded auth configuration for pulling from private
  10334. registries.
  10335. Refer to the [authentication section](#section/Authentication) for
  10336. details.
  10337. type: "string"
  10338. tags: ["Service"]
  10339. /services/{id}:
  10340. get:
  10341. summary: "Inspect a service"
  10342. operationId: "ServiceInspect"
  10343. responses:
  10344. 200:
  10345. description: "no error"
  10346. schema:
  10347. $ref: "#/definitions/Service"
  10348. 404:
  10349. description: "no such service"
  10350. schema:
  10351. $ref: "#/definitions/ErrorResponse"
  10352. 500:
  10353. description: "server error"
  10354. schema:
  10355. $ref: "#/definitions/ErrorResponse"
  10356. 503:
  10357. description: "node is not part of a swarm"
  10358. schema:
  10359. $ref: "#/definitions/ErrorResponse"
  10360. parameters:
  10361. - name: "id"
  10362. in: "path"
  10363. description: "ID or name of service."
  10364. required: true
  10365. type: "string"
  10366. - name: "insertDefaults"
  10367. in: "query"
  10368. description: "Fill empty fields with default values."
  10369. type: "boolean"
  10370. default: false
  10371. tags: ["Service"]
  10372. delete:
  10373. summary: "Delete a service"
  10374. operationId: "ServiceDelete"
  10375. responses:
  10376. 200:
  10377. description: "no error"
  10378. 404:
  10379. description: "no such service"
  10380. schema:
  10381. $ref: "#/definitions/ErrorResponse"
  10382. 500:
  10383. description: "server error"
  10384. schema:
  10385. $ref: "#/definitions/ErrorResponse"
  10386. 503:
  10387. description: "node is not part of a swarm"
  10388. schema:
  10389. $ref: "#/definitions/ErrorResponse"
  10390. parameters:
  10391. - name: "id"
  10392. in: "path"
  10393. description: "ID or name of service."
  10394. required: true
  10395. type: "string"
  10396. tags: ["Service"]
  10397. /services/{id}/update:
  10398. post:
  10399. summary: "Update a service"
  10400. operationId: "ServiceUpdate"
  10401. consumes: ["application/json"]
  10402. produces: ["application/json"]
  10403. responses:
  10404. 200:
  10405. description: "no error"
  10406. schema:
  10407. $ref: "#/definitions/ServiceUpdateResponse"
  10408. 400:
  10409. description: "bad parameter"
  10410. schema:
  10411. $ref: "#/definitions/ErrorResponse"
  10412. 404:
  10413. description: "no such service"
  10414. schema:
  10415. $ref: "#/definitions/ErrorResponse"
  10416. 500:
  10417. description: "server error"
  10418. schema:
  10419. $ref: "#/definitions/ErrorResponse"
  10420. 503:
  10421. description: "node is not part of a swarm"
  10422. schema:
  10423. $ref: "#/definitions/ErrorResponse"
  10424. parameters:
  10425. - name: "id"
  10426. in: "path"
  10427. description: "ID or name of service."
  10428. required: true
  10429. type: "string"
  10430. - name: "body"
  10431. in: "body"
  10432. required: true
  10433. schema:
  10434. allOf:
  10435. - $ref: "#/definitions/ServiceSpec"
  10436. - type: "object"
  10437. example:
  10438. Name: "top"
  10439. TaskTemplate:
  10440. ContainerSpec:
  10441. Image: "busybox"
  10442. Args:
  10443. - "top"
  10444. Resources:
  10445. Limits: {}
  10446. Reservations: {}
  10447. RestartPolicy:
  10448. Condition: "any"
  10449. MaxAttempts: 0
  10450. Placement: {}
  10451. ForceUpdate: 0
  10452. Mode:
  10453. Replicated:
  10454. Replicas: 1
  10455. UpdateConfig:
  10456. Parallelism: 2
  10457. Delay: 1000000000
  10458. FailureAction: "pause"
  10459. Monitor: 15000000000
  10460. MaxFailureRatio: 0.15
  10461. RollbackConfig:
  10462. Parallelism: 1
  10463. Delay: 1000000000
  10464. FailureAction: "pause"
  10465. Monitor: 15000000000
  10466. MaxFailureRatio: 0.15
  10467. EndpointSpec:
  10468. Mode: "vip"
  10469. - name: "version"
  10470. in: "query"
  10471. description: |
  10472. The version number of the service object being updated. This is
  10473. required to avoid conflicting writes.
  10474. This version number should be the value as currently set on the
  10475. service *before* the update. You can find the current version by
  10476. calling `GET /services/{id}`
  10477. required: true
  10478. type: "integer"
  10479. - name: "registryAuthFrom"
  10480. in: "query"
  10481. description: |
  10482. If the `X-Registry-Auth` header is not specified, this parameter
  10483. indicates where to find registry authorization credentials.
  10484. type: "string"
  10485. enum: ["spec", "previous-spec"]
  10486. default: "spec"
  10487. - name: "rollback"
  10488. in: "query"
  10489. description: |
  10490. Set to this parameter to `previous` to cause a server-side rollback
  10491. to the previous service spec. The supplied spec will be ignored in
  10492. this case.
  10493. type: "string"
  10494. - name: "X-Registry-Auth"
  10495. in: "header"
  10496. description: |
  10497. A base64url-encoded auth configuration for pulling from private
  10498. registries.
  10499. Refer to the [authentication section](#section/Authentication) for
  10500. details.
  10501. type: "string"
  10502. tags: ["Service"]
  10503. /services/{id}/logs:
  10504. get:
  10505. summary: "Get service logs"
  10506. description: |
  10507. Get `stdout` and `stderr` logs from a service. See also
  10508. [`/containers/{id}/logs`](#operation/ContainerLogs).
  10509. **Note**: This endpoint works only for services with the `local`,
  10510. `json-file` or `journald` logging drivers.
  10511. operationId: "ServiceLogs"
  10512. responses:
  10513. 200:
  10514. description: "logs returned as a stream in response body"
  10515. schema:
  10516. type: "string"
  10517. format: "binary"
  10518. 404:
  10519. description: "no such service"
  10520. schema:
  10521. $ref: "#/definitions/ErrorResponse"
  10522. examples:
  10523. application/json:
  10524. message: "No such service: c2ada9df5af8"
  10525. 500:
  10526. description: "server error"
  10527. schema:
  10528. $ref: "#/definitions/ErrorResponse"
  10529. 503:
  10530. description: "node is not part of a swarm"
  10531. schema:
  10532. $ref: "#/definitions/ErrorResponse"
  10533. parameters:
  10534. - name: "id"
  10535. in: "path"
  10536. required: true
  10537. description: "ID or name of the service"
  10538. type: "string"
  10539. - name: "details"
  10540. in: "query"
  10541. description: "Show service context and extra details provided to logs."
  10542. type: "boolean"
  10543. default: false
  10544. - name: "follow"
  10545. in: "query"
  10546. description: "Keep connection after returning logs."
  10547. type: "boolean"
  10548. default: false
  10549. - name: "stdout"
  10550. in: "query"
  10551. description: "Return logs from `stdout`"
  10552. type: "boolean"
  10553. default: false
  10554. - name: "stderr"
  10555. in: "query"
  10556. description: "Return logs from `stderr`"
  10557. type: "boolean"
  10558. default: false
  10559. - name: "since"
  10560. in: "query"
  10561. description: "Only return logs since this time, as a UNIX timestamp"
  10562. type: "integer"
  10563. default: 0
  10564. - name: "timestamps"
  10565. in: "query"
  10566. description: "Add timestamps to every log line"
  10567. type: "boolean"
  10568. default: false
  10569. - name: "tail"
  10570. in: "query"
  10571. description: |
  10572. Only return this number of log lines from the end of the logs.
  10573. Specify as an integer or `all` to output all log lines.
  10574. type: "string"
  10575. default: "all"
  10576. tags: ["Service"]
  10577. /tasks:
  10578. get:
  10579. summary: "List tasks"
  10580. operationId: "TaskList"
  10581. produces:
  10582. - "application/json"
  10583. responses:
  10584. 200:
  10585. description: "no error"
  10586. schema:
  10587. type: "array"
  10588. items:
  10589. $ref: "#/definitions/Task"
  10590. example:
  10591. - ID: "0kzzo1i0y4jz6027t0k7aezc7"
  10592. Version:
  10593. Index: 71
  10594. CreatedAt: "2016-06-07T21:07:31.171892745Z"
  10595. UpdatedAt: "2016-06-07T21:07:31.376370513Z"
  10596. Spec:
  10597. ContainerSpec:
  10598. Image: "redis"
  10599. Resources:
  10600. Limits: {}
  10601. Reservations: {}
  10602. RestartPolicy:
  10603. Condition: "any"
  10604. MaxAttempts: 0
  10605. Placement: {}
  10606. ServiceID: "9mnpnzenvg8p8tdbtq4wvbkcz"
  10607. Slot: 1
  10608. NodeID: "60gvrl6tm78dmak4yl7srz94v"
  10609. Status:
  10610. Timestamp: "2016-06-07T21:07:31.290032978Z"
  10611. State: "running"
  10612. Message: "started"
  10613. ContainerStatus:
  10614. ContainerID: "e5d62702a1b48d01c3e02ca1e0212a250801fa8d67caca0b6f35919ebc12f035"
  10615. PID: 677
  10616. DesiredState: "running"
  10617. NetworksAttachments:
  10618. - Network:
  10619. ID: "4qvuz4ko70xaltuqbt8956gd1"
  10620. Version:
  10621. Index: 18
  10622. CreatedAt: "2016-06-07T20:31:11.912919752Z"
  10623. UpdatedAt: "2016-06-07T21:07:29.955277358Z"
  10624. Spec:
  10625. Name: "ingress"
  10626. Labels:
  10627. com.docker.swarm.internal: "true"
  10628. DriverConfiguration: {}
  10629. IPAMOptions:
  10630. Driver: {}
  10631. Configs:
  10632. - Subnet: "10.255.0.0/16"
  10633. Gateway: "10.255.0.1"
  10634. DriverState:
  10635. Name: "overlay"
  10636. Options:
  10637. com.docker.network.driver.overlay.vxlanid_list: "256"
  10638. IPAMOptions:
  10639. Driver:
  10640. Name: "default"
  10641. Configs:
  10642. - Subnet: "10.255.0.0/16"
  10643. Gateway: "10.255.0.1"
  10644. Addresses:
  10645. - "10.255.0.10/16"
  10646. - ID: "1yljwbmlr8er2waf8orvqpwms"
  10647. Version:
  10648. Index: 30
  10649. CreatedAt: "2016-06-07T21:07:30.019104782Z"
  10650. UpdatedAt: "2016-06-07T21:07:30.231958098Z"
  10651. Name: "hopeful_cori"
  10652. Spec:
  10653. ContainerSpec:
  10654. Image: "redis"
  10655. Resources:
  10656. Limits: {}
  10657. Reservations: {}
  10658. RestartPolicy:
  10659. Condition: "any"
  10660. MaxAttempts: 0
  10661. Placement: {}
  10662. ServiceID: "9mnpnzenvg8p8tdbtq4wvbkcz"
  10663. Slot: 1
  10664. NodeID: "60gvrl6tm78dmak4yl7srz94v"
  10665. Status:
  10666. Timestamp: "2016-06-07T21:07:30.202183143Z"
  10667. State: "shutdown"
  10668. Message: "shutdown"
  10669. ContainerStatus:
  10670. ContainerID: "1cf8d63d18e79668b0004a4be4c6ee58cddfad2dae29506d8781581d0688a213"
  10671. DesiredState: "shutdown"
  10672. NetworksAttachments:
  10673. - Network:
  10674. ID: "4qvuz4ko70xaltuqbt8956gd1"
  10675. Version:
  10676. Index: 18
  10677. CreatedAt: "2016-06-07T20:31:11.912919752Z"
  10678. UpdatedAt: "2016-06-07T21:07:29.955277358Z"
  10679. Spec:
  10680. Name: "ingress"
  10681. Labels:
  10682. com.docker.swarm.internal: "true"
  10683. DriverConfiguration: {}
  10684. IPAMOptions:
  10685. Driver: {}
  10686. Configs:
  10687. - Subnet: "10.255.0.0/16"
  10688. Gateway: "10.255.0.1"
  10689. DriverState:
  10690. Name: "overlay"
  10691. Options:
  10692. com.docker.network.driver.overlay.vxlanid_list: "256"
  10693. IPAMOptions:
  10694. Driver:
  10695. Name: "default"
  10696. Configs:
  10697. - Subnet: "10.255.0.0/16"
  10698. Gateway: "10.255.0.1"
  10699. Addresses:
  10700. - "10.255.0.5/16"
  10701. 500:
  10702. description: "server error"
  10703. schema:
  10704. $ref: "#/definitions/ErrorResponse"
  10705. 503:
  10706. description: "node is not part of a swarm"
  10707. schema:
  10708. $ref: "#/definitions/ErrorResponse"
  10709. parameters:
  10710. - name: "filters"
  10711. in: "query"
  10712. type: "string"
  10713. description: |
  10714. A JSON encoded value of the filters (a `map[string][]string`) to
  10715. process on the tasks list.
  10716. Available filters:
  10717. - `desired-state=(running | shutdown | accepted)`
  10718. - `id=<task id>`
  10719. - `label=key` or `label="key=value"`
  10720. - `name=<task name>`
  10721. - `node=<node id or name>`
  10722. - `service=<service name>`
  10723. tags: ["Task"]
  10724. /tasks/{id}:
  10725. get:
  10726. summary: "Inspect a task"
  10727. operationId: "TaskInspect"
  10728. produces:
  10729. - "application/json"
  10730. responses:
  10731. 200:
  10732. description: "no error"
  10733. schema:
  10734. $ref: "#/definitions/Task"
  10735. 404:
  10736. description: "no such task"
  10737. schema:
  10738. $ref: "#/definitions/ErrorResponse"
  10739. 500:
  10740. description: "server error"
  10741. schema:
  10742. $ref: "#/definitions/ErrorResponse"
  10743. 503:
  10744. description: "node is not part of a swarm"
  10745. schema:
  10746. $ref: "#/definitions/ErrorResponse"
  10747. parameters:
  10748. - name: "id"
  10749. in: "path"
  10750. description: "ID of the task"
  10751. required: true
  10752. type: "string"
  10753. tags: ["Task"]
  10754. /tasks/{id}/logs:
  10755. get:
  10756. summary: "Get task logs"
  10757. description: |
  10758. Get `stdout` and `stderr` logs from a task.
  10759. See also [`/containers/{id}/logs`](#operation/ContainerLogs).
  10760. **Note**: This endpoint works only for services with the `local`,
  10761. `json-file` or `journald` logging drivers.
  10762. operationId: "TaskLogs"
  10763. responses:
  10764. 200:
  10765. description: "logs returned as a stream in response body"
  10766. schema:
  10767. type: "string"
  10768. format: "binary"
  10769. 404:
  10770. description: "no such task"
  10771. schema:
  10772. $ref: "#/definitions/ErrorResponse"
  10773. examples:
  10774. application/json:
  10775. message: "No such task: c2ada9df5af8"
  10776. 500:
  10777. description: "server error"
  10778. schema:
  10779. $ref: "#/definitions/ErrorResponse"
  10780. 503:
  10781. description: "node is not part of a swarm"
  10782. schema:
  10783. $ref: "#/definitions/ErrorResponse"
  10784. parameters:
  10785. - name: "id"
  10786. in: "path"
  10787. required: true
  10788. description: "ID of the task"
  10789. type: "string"
  10790. - name: "details"
  10791. in: "query"
  10792. description: "Show task context and extra details provided to logs."
  10793. type: "boolean"
  10794. default: false
  10795. - name: "follow"
  10796. in: "query"
  10797. description: "Keep connection after returning logs."
  10798. type: "boolean"
  10799. default: false
  10800. - name: "stdout"
  10801. in: "query"
  10802. description: "Return logs from `stdout`"
  10803. type: "boolean"
  10804. default: false
  10805. - name: "stderr"
  10806. in: "query"
  10807. description: "Return logs from `stderr`"
  10808. type: "boolean"
  10809. default: false
  10810. - name: "since"
  10811. in: "query"
  10812. description: "Only return logs since this time, as a UNIX timestamp"
  10813. type: "integer"
  10814. default: 0
  10815. - name: "timestamps"
  10816. in: "query"
  10817. description: "Add timestamps to every log line"
  10818. type: "boolean"
  10819. default: false
  10820. - name: "tail"
  10821. in: "query"
  10822. description: |
  10823. Only return this number of log lines from the end of the logs.
  10824. Specify as an integer or `all` to output all log lines.
  10825. type: "string"
  10826. default: "all"
  10827. tags: ["Task"]
  10828. /secrets:
  10829. get:
  10830. summary: "List secrets"
  10831. operationId: "SecretList"
  10832. produces:
  10833. - "application/json"
  10834. responses:
  10835. 200:
  10836. description: "no error"
  10837. schema:
  10838. type: "array"
  10839. items:
  10840. $ref: "#/definitions/Secret"
  10841. example:
  10842. - ID: "blt1owaxmitz71s9v5zh81zun"
  10843. Version:
  10844. Index: 85
  10845. CreatedAt: "2017-07-20T13:55:28.678958722Z"
  10846. UpdatedAt: "2017-07-20T13:55:28.678958722Z"
  10847. Spec:
  10848. Name: "mysql-passwd"
  10849. Labels:
  10850. some.label: "some.value"
  10851. Driver:
  10852. Name: "secret-bucket"
  10853. Options:
  10854. OptionA: "value for driver option A"
  10855. OptionB: "value for driver option B"
  10856. - ID: "ktnbjxoalbkvbvedmg1urrz8h"
  10857. Version:
  10858. Index: 11
  10859. CreatedAt: "2016-11-05T01:20:17.327670065Z"
  10860. UpdatedAt: "2016-11-05T01:20:17.327670065Z"
  10861. Spec:
  10862. Name: "app-dev.crt"
  10863. Labels:
  10864. foo: "bar"
  10865. 500:
  10866. description: "server error"
  10867. schema:
  10868. $ref: "#/definitions/ErrorResponse"
  10869. 503:
  10870. description: "node is not part of a swarm"
  10871. schema:
  10872. $ref: "#/definitions/ErrorResponse"
  10873. parameters:
  10874. - name: "filters"
  10875. in: "query"
  10876. type: "string"
  10877. description: |
  10878. A JSON encoded value of the filters (a `map[string][]string`) to
  10879. process on the secrets list.
  10880. Available filters:
  10881. - `id=<secret id>`
  10882. - `label=<key> or label=<key>=value`
  10883. - `name=<secret name>`
  10884. - `names=<secret name>`
  10885. tags: ["Secret"]
  10886. /secrets/create:
  10887. post:
  10888. summary: "Create a secret"
  10889. operationId: "SecretCreate"
  10890. consumes:
  10891. - "application/json"
  10892. produces:
  10893. - "application/json"
  10894. responses:
  10895. 201:
  10896. description: "no error"
  10897. schema:
  10898. $ref: "#/definitions/IdResponse"
  10899. 409:
  10900. description: "name conflicts with an existing object"
  10901. schema:
  10902. $ref: "#/definitions/ErrorResponse"
  10903. 500:
  10904. description: "server error"
  10905. schema:
  10906. $ref: "#/definitions/ErrorResponse"
  10907. 503:
  10908. description: "node is not part of a swarm"
  10909. schema:
  10910. $ref: "#/definitions/ErrorResponse"
  10911. parameters:
  10912. - name: "body"
  10913. in: "body"
  10914. schema:
  10915. allOf:
  10916. - $ref: "#/definitions/SecretSpec"
  10917. - type: "object"
  10918. example:
  10919. Name: "app-key.crt"
  10920. Labels:
  10921. foo: "bar"
  10922. Data: "VEhJUyBJUyBOT1QgQSBSRUFMIENFUlRJRklDQVRFCg=="
  10923. Driver:
  10924. Name: "secret-bucket"
  10925. Options:
  10926. OptionA: "value for driver option A"
  10927. OptionB: "value for driver option B"
  10928. tags: ["Secret"]
  10929. /secrets/{id}:
  10930. get:
  10931. summary: "Inspect a secret"
  10932. operationId: "SecretInspect"
  10933. produces:
  10934. - "application/json"
  10935. responses:
  10936. 200:
  10937. description: "no error"
  10938. schema:
  10939. $ref: "#/definitions/Secret"
  10940. examples:
  10941. application/json:
  10942. ID: "ktnbjxoalbkvbvedmg1urrz8h"
  10943. Version:
  10944. Index: 11
  10945. CreatedAt: "2016-11-05T01:20:17.327670065Z"
  10946. UpdatedAt: "2016-11-05T01:20:17.327670065Z"
  10947. Spec:
  10948. Name: "app-dev.crt"
  10949. Labels:
  10950. foo: "bar"
  10951. Driver:
  10952. Name: "secret-bucket"
  10953. Options:
  10954. OptionA: "value for driver option A"
  10955. OptionB: "value for driver option B"
  10956. 404:
  10957. description: "secret not found"
  10958. schema:
  10959. $ref: "#/definitions/ErrorResponse"
  10960. 500:
  10961. description: "server error"
  10962. schema:
  10963. $ref: "#/definitions/ErrorResponse"
  10964. 503:
  10965. description: "node is not part of a swarm"
  10966. schema:
  10967. $ref: "#/definitions/ErrorResponse"
  10968. parameters:
  10969. - name: "id"
  10970. in: "path"
  10971. required: true
  10972. type: "string"
  10973. description: "ID of the secret"
  10974. tags: ["Secret"]
  10975. delete:
  10976. summary: "Delete a secret"
  10977. operationId: "SecretDelete"
  10978. produces:
  10979. - "application/json"
  10980. responses:
  10981. 204:
  10982. description: "no error"
  10983. 404:
  10984. description: "secret not found"
  10985. schema:
  10986. $ref: "#/definitions/ErrorResponse"
  10987. 500:
  10988. description: "server error"
  10989. schema:
  10990. $ref: "#/definitions/ErrorResponse"
  10991. 503:
  10992. description: "node is not part of a swarm"
  10993. schema:
  10994. $ref: "#/definitions/ErrorResponse"
  10995. parameters:
  10996. - name: "id"
  10997. in: "path"
  10998. required: true
  10999. type: "string"
  11000. description: "ID of the secret"
  11001. tags: ["Secret"]
  11002. /secrets/{id}/update:
  11003. post:
  11004. summary: "Update a Secret"
  11005. operationId: "SecretUpdate"
  11006. responses:
  11007. 200:
  11008. description: "no error"
  11009. 400:
  11010. description: "bad parameter"
  11011. schema:
  11012. $ref: "#/definitions/ErrorResponse"
  11013. 404:
  11014. description: "no such secret"
  11015. schema:
  11016. $ref: "#/definitions/ErrorResponse"
  11017. 500:
  11018. description: "server error"
  11019. schema:
  11020. $ref: "#/definitions/ErrorResponse"
  11021. 503:
  11022. description: "node is not part of a swarm"
  11023. schema:
  11024. $ref: "#/definitions/ErrorResponse"
  11025. parameters:
  11026. - name: "id"
  11027. in: "path"
  11028. description: "The ID or name of the secret"
  11029. type: "string"
  11030. required: true
  11031. - name: "body"
  11032. in: "body"
  11033. schema:
  11034. $ref: "#/definitions/SecretSpec"
  11035. description: |
  11036. The spec of the secret to update. Currently, only the Labels field
  11037. can be updated. All other fields must remain unchanged from the
  11038. [SecretInspect endpoint](#operation/SecretInspect) response values.
  11039. - name: "version"
  11040. in: "query"
  11041. description: |
  11042. The version number of the secret object being updated. This is
  11043. required to avoid conflicting writes.
  11044. type: "integer"
  11045. format: "int64"
  11046. required: true
  11047. tags: ["Secret"]
  11048. /configs:
  11049. get:
  11050. summary: "List configs"
  11051. operationId: "ConfigList"
  11052. produces:
  11053. - "application/json"
  11054. responses:
  11055. 200:
  11056. description: "no error"
  11057. schema:
  11058. type: "array"
  11059. items:
  11060. $ref: "#/definitions/Config"
  11061. example:
  11062. - ID: "ktnbjxoalbkvbvedmg1urrz8h"
  11063. Version:
  11064. Index: 11
  11065. CreatedAt: "2016-11-05T01:20:17.327670065Z"
  11066. UpdatedAt: "2016-11-05T01:20:17.327670065Z"
  11067. Spec:
  11068. Name: "server.conf"
  11069. 500:
  11070. description: "server error"
  11071. schema:
  11072. $ref: "#/definitions/ErrorResponse"
  11073. 503:
  11074. description: "node is not part of a swarm"
  11075. schema:
  11076. $ref: "#/definitions/ErrorResponse"
  11077. parameters:
  11078. - name: "filters"
  11079. in: "query"
  11080. type: "string"
  11081. description: |
  11082. A JSON encoded value of the filters (a `map[string][]string`) to
  11083. process on the configs list.
  11084. Available filters:
  11085. - `id=<config id>`
  11086. - `label=<key> or label=<key>=value`
  11087. - `name=<config name>`
  11088. - `names=<config name>`
  11089. tags: ["Config"]
  11090. /configs/create:
  11091. post:
  11092. summary: "Create a config"
  11093. operationId: "ConfigCreate"
  11094. consumes:
  11095. - "application/json"
  11096. produces:
  11097. - "application/json"
  11098. responses:
  11099. 201:
  11100. description: "no error"
  11101. schema:
  11102. $ref: "#/definitions/IdResponse"
  11103. 409:
  11104. description: "name conflicts with an existing object"
  11105. schema:
  11106. $ref: "#/definitions/ErrorResponse"
  11107. 500:
  11108. description: "server error"
  11109. schema:
  11110. $ref: "#/definitions/ErrorResponse"
  11111. 503:
  11112. description: "node is not part of a swarm"
  11113. schema:
  11114. $ref: "#/definitions/ErrorResponse"
  11115. parameters:
  11116. - name: "body"
  11117. in: "body"
  11118. schema:
  11119. allOf:
  11120. - $ref: "#/definitions/ConfigSpec"
  11121. - type: "object"
  11122. example:
  11123. Name: "server.conf"
  11124. Labels:
  11125. foo: "bar"
  11126. Data: "VEhJUyBJUyBOT1QgQSBSRUFMIENFUlRJRklDQVRFCg=="
  11127. tags: ["Config"]
  11128. /configs/{id}:
  11129. get:
  11130. summary: "Inspect a config"
  11131. operationId: "ConfigInspect"
  11132. produces:
  11133. - "application/json"
  11134. responses:
  11135. 200:
  11136. description: "no error"
  11137. schema:
  11138. $ref: "#/definitions/Config"
  11139. examples:
  11140. application/json:
  11141. ID: "ktnbjxoalbkvbvedmg1urrz8h"
  11142. Version:
  11143. Index: 11
  11144. CreatedAt: "2016-11-05T01:20:17.327670065Z"
  11145. UpdatedAt: "2016-11-05T01:20:17.327670065Z"
  11146. Spec:
  11147. Name: "app-dev.crt"
  11148. 404:
  11149. description: "config not found"
  11150. schema:
  11151. $ref: "#/definitions/ErrorResponse"
  11152. 500:
  11153. description: "server error"
  11154. schema:
  11155. $ref: "#/definitions/ErrorResponse"
  11156. 503:
  11157. description: "node is not part of a swarm"
  11158. schema:
  11159. $ref: "#/definitions/ErrorResponse"
  11160. parameters:
  11161. - name: "id"
  11162. in: "path"
  11163. required: true
  11164. type: "string"
  11165. description: "ID of the config"
  11166. tags: ["Config"]
  11167. delete:
  11168. summary: "Delete a config"
  11169. operationId: "ConfigDelete"
  11170. produces:
  11171. - "application/json"
  11172. responses:
  11173. 204:
  11174. description: "no error"
  11175. 404:
  11176. description: "config not found"
  11177. schema:
  11178. $ref: "#/definitions/ErrorResponse"
  11179. 500:
  11180. description: "server error"
  11181. schema:
  11182. $ref: "#/definitions/ErrorResponse"
  11183. 503:
  11184. description: "node is not part of a swarm"
  11185. schema:
  11186. $ref: "#/definitions/ErrorResponse"
  11187. parameters:
  11188. - name: "id"
  11189. in: "path"
  11190. required: true
  11191. type: "string"
  11192. description: "ID of the config"
  11193. tags: ["Config"]
  11194. /configs/{id}/update:
  11195. post:
  11196. summary: "Update a Config"
  11197. operationId: "ConfigUpdate"
  11198. responses:
  11199. 200:
  11200. description: "no error"
  11201. 400:
  11202. description: "bad parameter"
  11203. schema:
  11204. $ref: "#/definitions/ErrorResponse"
  11205. 404:
  11206. description: "no such config"
  11207. schema:
  11208. $ref: "#/definitions/ErrorResponse"
  11209. 500:
  11210. description: "server error"
  11211. schema:
  11212. $ref: "#/definitions/ErrorResponse"
  11213. 503:
  11214. description: "node is not part of a swarm"
  11215. schema:
  11216. $ref: "#/definitions/ErrorResponse"
  11217. parameters:
  11218. - name: "id"
  11219. in: "path"
  11220. description: "The ID or name of the config"
  11221. type: "string"
  11222. required: true
  11223. - name: "body"
  11224. in: "body"
  11225. schema:
  11226. $ref: "#/definitions/ConfigSpec"
  11227. description: |
  11228. The spec of the config to update. Currently, only the Labels field
  11229. can be updated. All other fields must remain unchanged from the
  11230. [ConfigInspect endpoint](#operation/ConfigInspect) response values.
  11231. - name: "version"
  11232. in: "query"
  11233. description: |
  11234. The version number of the config object being updated. This is
  11235. required to avoid conflicting writes.
  11236. type: "integer"
  11237. format: "int64"
  11238. required: true
  11239. tags: ["Config"]
  11240. /distribution/{name}/json:
  11241. get:
  11242. summary: "Get image information from the registry"
  11243. description: |
  11244. Return image digest and platform information by contacting the registry.
  11245. operationId: "DistributionInspect"
  11246. produces:
  11247. - "application/json"
  11248. responses:
  11249. 200:
  11250. description: "descriptor and platform information"
  11251. schema:
  11252. $ref: "#/definitions/DistributionInspect"
  11253. 401:
  11254. description: "Failed authentication or no image found"
  11255. schema:
  11256. $ref: "#/definitions/ErrorResponse"
  11257. examples:
  11258. application/json:
  11259. message: "No such image: someimage (tag: latest)"
  11260. 500:
  11261. description: "Server error"
  11262. schema:
  11263. $ref: "#/definitions/ErrorResponse"
  11264. parameters:
  11265. - name: "name"
  11266. in: "path"
  11267. description: "Image name or id"
  11268. type: "string"
  11269. required: true
  11270. tags: ["Distribution"]
  11271. /session:
  11272. post:
  11273. summary: "Initialize interactive session"
  11274. description: |
  11275. Start a new interactive session with a server. Session allows server to
  11276. call back to the client for advanced capabilities.
  11277. ### Hijacking
  11278. This endpoint hijacks the HTTP connection to HTTP2 transport that allows
  11279. the client to expose gPRC services on that connection.
  11280. For example, the client sends this request to upgrade the connection:
  11281. ```
  11282. POST /session HTTP/1.1
  11283. Upgrade: h2c
  11284. Connection: Upgrade
  11285. ```
  11286. The Docker daemon responds with a `101 UPGRADED` response follow with
  11287. the raw stream:
  11288. ```
  11289. HTTP/1.1 101 UPGRADED
  11290. Connection: Upgrade
  11291. Upgrade: h2c
  11292. ```
  11293. operationId: "Session"
  11294. produces:
  11295. - "application/vnd.docker.raw-stream"
  11296. responses:
  11297. 101:
  11298. description: "no error, hijacking successful"
  11299. 400:
  11300. description: "bad parameter"
  11301. schema:
  11302. $ref: "#/definitions/ErrorResponse"
  11303. 500:
  11304. description: "server error"
  11305. schema:
  11306. $ref: "#/definitions/ErrorResponse"
  11307. tags: ["Session"]