v1.29.yaml 274 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646264726482649265026512652265326542655265626572658265926602661266226632664266526662667266826692670267126722673267426752676267726782679268026812682268326842685268626872688268926902691269226932694269526962697269826992700270127022703270427052706270727082709271027112712271327142715271627172718271927202721272227232724272527262727272827292730273127322733273427352736273727382739274027412742274327442745274627472748274927502751275227532754275527562757275827592760276127622763276427652766276727682769277027712772277327742775277627772778277927802781278227832784278527862787278827892790279127922793279427952796279727982799280028012802280328042805280628072808280928102811281228132814281528162817281828192820282128222823282428252826282728282829283028312832283328342835283628372838283928402841284228432844284528462847284828492850285128522853285428552856285728582859286028612862286328642865286628672868286928702871287228732874287528762877287828792880288128822883288428852886288728882889289028912892289328942895289628972898289929002901290229032904290529062907290829092910291129122913291429152916291729182919292029212922292329242925292629272928292929302931293229332934293529362937293829392940294129422943294429452946294729482949295029512952295329542955295629572958295929602961296229632964296529662967296829692970297129722973297429752976297729782979298029812982298329842985298629872988298929902991299229932994299529962997299829993000300130023003300430053006300730083009301030113012301330143015301630173018301930203021302230233024302530263027302830293030303130323033303430353036303730383039304030413042304330443045304630473048304930503051305230533054305530563057305830593060306130623063306430653066306730683069307030713072307330743075307630773078307930803081308230833084308530863087308830893090309130923093309430953096309730983099310031013102310331043105310631073108310931103111311231133114311531163117311831193120312131223123312431253126312731283129313031313132313331343135313631373138313931403141314231433144314531463147314831493150315131523153315431553156315731583159316031613162316331643165316631673168316931703171317231733174317531763177317831793180318131823183318431853186318731883189319031913192319331943195319631973198319932003201320232033204320532063207320832093210321132123213321432153216321732183219322032213222322332243225322632273228322932303231323232333234323532363237323832393240324132423243324432453246324732483249325032513252325332543255325632573258325932603261326232633264326532663267326832693270327132723273327432753276327732783279328032813282328332843285328632873288328932903291329232933294329532963297329832993300330133023303330433053306330733083309331033113312331333143315331633173318331933203321332233233324332533263327332833293330333133323333333433353336333733383339334033413342334333443345334633473348334933503351335233533354335533563357335833593360336133623363336433653366336733683369337033713372337333743375337633773378337933803381338233833384338533863387338833893390339133923393339433953396339733983399340034013402340334043405340634073408340934103411341234133414341534163417341834193420342134223423342434253426342734283429343034313432343334343435343634373438343934403441344234433444344534463447344834493450345134523453345434553456345734583459346034613462346334643465346634673468346934703471347234733474347534763477347834793480348134823483348434853486348734883489349034913492349334943495349634973498349935003501350235033504350535063507350835093510351135123513351435153516351735183519352035213522352335243525352635273528352935303531353235333534353535363537353835393540354135423543354435453546354735483549355035513552355335543555355635573558355935603561356235633564356535663567356835693570357135723573357435753576357735783579358035813582358335843585358635873588358935903591359235933594359535963597359835993600360136023603360436053606360736083609361036113612361336143615361636173618361936203621362236233624362536263627362836293630363136323633363436353636363736383639364036413642364336443645364636473648364936503651365236533654365536563657365836593660366136623663366436653666366736683669367036713672367336743675367636773678367936803681368236833684368536863687368836893690369136923693369436953696369736983699370037013702370337043705370637073708370937103711371237133714371537163717371837193720372137223723372437253726372737283729373037313732373337343735373637373738373937403741374237433744374537463747374837493750375137523753375437553756375737583759376037613762376337643765376637673768376937703771377237733774377537763777377837793780378137823783378437853786378737883789379037913792379337943795379637973798379938003801380238033804380538063807380838093810381138123813381438153816381738183819382038213822382338243825382638273828382938303831383238333834383538363837383838393840384138423843384438453846384738483849385038513852385338543855385638573858385938603861386238633864386538663867386838693870387138723873387438753876387738783879388038813882388338843885388638873888388938903891389238933894389538963897389838993900390139023903390439053906390739083909391039113912391339143915391639173918391939203921392239233924392539263927392839293930393139323933393439353936393739383939394039413942394339443945394639473948394939503951395239533954395539563957395839593960396139623963396439653966396739683969397039713972397339743975397639773978397939803981398239833984398539863987398839893990399139923993399439953996399739983999400040014002400340044005400640074008400940104011401240134014401540164017401840194020402140224023402440254026402740284029403040314032403340344035403640374038403940404041404240434044404540464047404840494050405140524053405440554056405740584059406040614062406340644065406640674068406940704071407240734074407540764077407840794080408140824083408440854086408740884089409040914092409340944095409640974098409941004101410241034104410541064107410841094110411141124113411441154116411741184119412041214122412341244125412641274128412941304131413241334134413541364137413841394140414141424143414441454146414741484149415041514152415341544155415641574158415941604161416241634164416541664167416841694170417141724173417441754176417741784179418041814182418341844185418641874188418941904191419241934194419541964197419841994200420142024203420442054206420742084209421042114212421342144215421642174218421942204221422242234224422542264227422842294230423142324233423442354236423742384239424042414242424342444245424642474248424942504251425242534254425542564257425842594260426142624263426442654266426742684269427042714272427342744275427642774278427942804281428242834284428542864287428842894290429142924293429442954296429742984299430043014302430343044305430643074308430943104311431243134314431543164317431843194320432143224323432443254326432743284329433043314332433343344335433643374338433943404341434243434344434543464347434843494350435143524353435443554356435743584359436043614362436343644365436643674368436943704371437243734374437543764377437843794380438143824383438443854386438743884389439043914392439343944395439643974398439944004401440244034404440544064407440844094410441144124413441444154416441744184419442044214422442344244425442644274428442944304431443244334434443544364437443844394440444144424443444444454446444744484449445044514452445344544455445644574458445944604461446244634464446544664467446844694470447144724473447444754476447744784479448044814482448344844485448644874488448944904491449244934494449544964497449844994500450145024503450445054506450745084509451045114512451345144515451645174518451945204521452245234524452545264527452845294530453145324533453445354536453745384539454045414542454345444545454645474548454945504551455245534554455545564557455845594560456145624563456445654566456745684569457045714572457345744575457645774578457945804581458245834584458545864587458845894590459145924593459445954596459745984599460046014602460346044605460646074608460946104611461246134614461546164617461846194620462146224623462446254626462746284629463046314632463346344635463646374638463946404641464246434644464546464647464846494650465146524653465446554656465746584659466046614662466346644665466646674668466946704671467246734674467546764677467846794680468146824683468446854686468746884689469046914692469346944695469646974698469947004701470247034704470547064707470847094710471147124713471447154716471747184719472047214722472347244725472647274728472947304731473247334734473547364737473847394740474147424743474447454746474747484749475047514752475347544755475647574758475947604761476247634764476547664767476847694770477147724773477447754776477747784779478047814782478347844785478647874788478947904791479247934794479547964797479847994800480148024803480448054806480748084809481048114812481348144815481648174818481948204821482248234824482548264827482848294830483148324833483448354836483748384839484048414842484348444845484648474848484948504851485248534854485548564857485848594860486148624863486448654866486748684869487048714872487348744875487648774878487948804881488248834884488548864887488848894890489148924893489448954896489748984899490049014902490349044905490649074908490949104911491249134914491549164917491849194920492149224923492449254926492749284929493049314932493349344935493649374938493949404941494249434944494549464947494849494950495149524953495449554956495749584959496049614962496349644965496649674968496949704971497249734974497549764977497849794980498149824983498449854986498749884989499049914992499349944995499649974998499950005001500250035004500550065007500850095010501150125013501450155016501750185019502050215022502350245025502650275028502950305031503250335034503550365037503850395040504150425043504450455046504750485049505050515052505350545055505650575058505950605061506250635064506550665067506850695070507150725073507450755076507750785079508050815082508350845085508650875088508950905091509250935094509550965097509850995100510151025103510451055106510751085109511051115112511351145115511651175118511951205121512251235124512551265127512851295130513151325133513451355136513751385139514051415142514351445145514651475148514951505151515251535154515551565157515851595160516151625163516451655166516751685169517051715172517351745175517651775178517951805181518251835184518551865187518851895190519151925193519451955196519751985199520052015202520352045205520652075208520952105211521252135214521552165217521852195220522152225223522452255226522752285229523052315232523352345235523652375238523952405241524252435244524552465247524852495250525152525253525452555256525752585259526052615262526352645265526652675268526952705271527252735274527552765277527852795280528152825283528452855286528752885289529052915292529352945295529652975298529953005301530253035304530553065307530853095310531153125313531453155316531753185319532053215322532353245325532653275328532953305331533253335334533553365337533853395340534153425343534453455346534753485349535053515352535353545355535653575358535953605361536253635364536553665367536853695370537153725373537453755376537753785379538053815382538353845385538653875388538953905391539253935394539553965397539853995400540154025403540454055406540754085409541054115412541354145415541654175418541954205421542254235424542554265427542854295430543154325433543454355436543754385439544054415442544354445445544654475448544954505451545254535454545554565457545854595460546154625463546454655466546754685469547054715472547354745475547654775478547954805481548254835484548554865487548854895490549154925493549454955496549754985499550055015502550355045505550655075508550955105511551255135514551555165517551855195520552155225523552455255526552755285529553055315532553355345535553655375538553955405541554255435544554555465547554855495550555155525553555455555556555755585559556055615562556355645565556655675568556955705571557255735574557555765577557855795580558155825583558455855586558755885589559055915592559355945595559655975598559956005601560256035604560556065607560856095610561156125613561456155616561756185619562056215622562356245625562656275628562956305631563256335634563556365637563856395640564156425643564456455646564756485649565056515652565356545655565656575658565956605661566256635664566556665667566856695670567156725673567456755676567756785679568056815682568356845685568656875688568956905691569256935694569556965697569856995700570157025703570457055706570757085709571057115712571357145715571657175718571957205721572257235724572557265727572857295730573157325733573457355736573757385739574057415742574357445745574657475748574957505751575257535754575557565757575857595760576157625763576457655766576757685769577057715772577357745775577657775778577957805781578257835784578557865787578857895790579157925793579457955796579757985799580058015802580358045805580658075808580958105811581258135814581558165817581858195820582158225823582458255826582758285829583058315832583358345835583658375838583958405841584258435844584558465847584858495850585158525853585458555856585758585859586058615862586358645865586658675868586958705871587258735874587558765877587858795880588158825883588458855886588758885889589058915892589358945895589658975898589959005901590259035904590559065907590859095910591159125913591459155916591759185919592059215922592359245925592659275928592959305931593259335934593559365937593859395940594159425943594459455946594759485949595059515952595359545955595659575958595959605961596259635964596559665967596859695970597159725973597459755976597759785979598059815982598359845985598659875988598959905991599259935994599559965997599859996000600160026003600460056006600760086009601060116012601360146015601660176018601960206021602260236024602560266027602860296030603160326033603460356036603760386039604060416042604360446045604660476048604960506051605260536054605560566057605860596060606160626063606460656066606760686069607060716072607360746075607660776078607960806081608260836084608560866087608860896090609160926093609460956096609760986099610061016102610361046105610661076108610961106111611261136114611561166117611861196120612161226123612461256126612761286129613061316132613361346135613661376138613961406141614261436144614561466147614861496150615161526153615461556156615761586159616061616162616361646165616661676168616961706171617261736174617561766177617861796180618161826183618461856186618761886189619061916192619361946195619661976198619962006201620262036204620562066207620862096210621162126213621462156216621762186219622062216222622362246225622662276228622962306231623262336234623562366237623862396240624162426243624462456246624762486249625062516252625362546255625662576258625962606261626262636264626562666267626862696270627162726273627462756276627762786279628062816282628362846285628662876288628962906291629262936294629562966297629862996300630163026303630463056306630763086309631063116312631363146315631663176318631963206321632263236324632563266327632863296330633163326333633463356336633763386339634063416342634363446345634663476348634963506351635263536354635563566357635863596360636163626363636463656366636763686369637063716372637363746375637663776378637963806381638263836384638563866387638863896390639163926393639463956396639763986399640064016402640364046405640664076408640964106411641264136414641564166417641864196420642164226423642464256426642764286429643064316432643364346435643664376438643964406441644264436444644564466447644864496450645164526453645464556456645764586459646064616462646364646465646664676468646964706471647264736474647564766477647864796480648164826483648464856486648764886489649064916492649364946495649664976498649965006501650265036504650565066507650865096510651165126513651465156516651765186519652065216522652365246525652665276528652965306531653265336534653565366537653865396540654165426543654465456546654765486549655065516552655365546555655665576558655965606561656265636564656565666567656865696570657165726573657465756576657765786579658065816582658365846585658665876588658965906591659265936594659565966597659865996600660166026603660466056606660766086609661066116612661366146615661666176618661966206621662266236624662566266627662866296630663166326633663466356636663766386639664066416642664366446645664666476648664966506651665266536654665566566657665866596660666166626663666466656666666766686669667066716672667366746675667666776678667966806681668266836684668566866687668866896690669166926693669466956696669766986699670067016702670367046705670667076708670967106711671267136714671567166717671867196720672167226723672467256726672767286729673067316732673367346735673667376738673967406741674267436744674567466747674867496750675167526753675467556756675767586759676067616762676367646765676667676768676967706771677267736774677567766777677867796780678167826783678467856786678767886789679067916792679367946795679667976798679968006801680268036804680568066807680868096810681168126813681468156816681768186819682068216822682368246825682668276828682968306831683268336834683568366837683868396840684168426843684468456846684768486849685068516852685368546855685668576858685968606861686268636864686568666867686868696870687168726873687468756876687768786879688068816882688368846885688668876888688968906891689268936894689568966897689868996900690169026903690469056906690769086909691069116912691369146915691669176918691969206921692269236924692569266927692869296930693169326933693469356936693769386939694069416942694369446945694669476948694969506951695269536954695569566957695869596960696169626963696469656966696769686969697069716972697369746975697669776978697969806981698269836984698569866987698869896990699169926993699469956996699769986999700070017002700370047005700670077008700970107011701270137014701570167017701870197020702170227023702470257026702770287029703070317032703370347035703670377038703970407041704270437044704570467047704870497050705170527053705470557056705770587059706070617062706370647065706670677068706970707071707270737074707570767077707870797080708170827083708470857086708770887089709070917092709370947095709670977098709971007101710271037104710571067107710871097110711171127113711471157116711771187119712071217122712371247125712671277128712971307131713271337134713571367137713871397140714171427143714471457146714771487149715071517152715371547155715671577158715971607161716271637164716571667167716871697170717171727173717471757176717771787179718071817182718371847185718671877188718971907191719271937194719571967197719871997200720172027203720472057206720772087209721072117212721372147215721672177218721972207221722272237224722572267227722872297230723172327233723472357236723772387239724072417242724372447245724672477248724972507251725272537254725572567257725872597260726172627263726472657266726772687269727072717272727372747275727672777278727972807281728272837284728572867287728872897290729172927293729472957296729772987299730073017302730373047305730673077308730973107311731273137314731573167317731873197320732173227323732473257326732773287329733073317332733373347335733673377338733973407341734273437344734573467347734873497350735173527353735473557356735773587359736073617362736373647365736673677368736973707371737273737374737573767377737873797380738173827383738473857386738773887389739073917392739373947395739673977398739974007401740274037404740574067407740874097410741174127413741474157416741774187419742074217422742374247425742674277428742974307431743274337434743574367437743874397440744174427443744474457446744774487449745074517452745374547455745674577458745974607461746274637464746574667467746874697470747174727473747474757476747774787479748074817482748374847485748674877488748974907491749274937494749574967497749874997500750175027503750475057506750775087509751075117512751375147515751675177518751975207521752275237524752575267527752875297530753175327533753475357536753775387539754075417542754375447545754675477548754975507551755275537554755575567557755875597560756175627563756475657566756775687569757075717572757375747575757675777578757975807581758275837584758575867587758875897590759175927593759475957596759775987599760076017602760376047605760676077608760976107611761276137614761576167617761876197620762176227623762476257626762776287629763076317632763376347635763676377638763976407641764276437644764576467647764876497650765176527653765476557656765776587659766076617662766376647665766676677668766976707671767276737674767576767677767876797680768176827683768476857686768776887689769076917692769376947695769676977698769977007701770277037704770577067707770877097710771177127713771477157716771777187719772077217722772377247725772677277728772977307731773277337734773577367737773877397740774177427743774477457746774777487749775077517752775377547755775677577758775977607761776277637764776577667767776877697770777177727773777477757776777777787779778077817782778377847785778677877788778977907791779277937794779577967797779877997800780178027803780478057806780778087809781078117812781378147815781678177818781978207821782278237824782578267827782878297830783178327833783478357836783778387839784078417842784378447845784678477848784978507851785278537854785578567857785878597860786178627863786478657866786778687869787078717872787378747875787678777878787978807881788278837884788578867887788878897890789178927893789478957896789778987899790079017902790379047905790679077908790979107911791279137914791579167917791879197920792179227923792479257926792779287929793079317932793379347935793679377938793979407941794279437944794579467947794879497950795179527953795479557956795779587959796079617962796379647965796679677968796979707971797279737974797579767977797879797980798179827983798479857986798779887989799079917992799379947995799679977998799980008001800280038004800580068007800880098010801180128013801480158016801780188019802080218022802380248025802680278028802980308031803280338034803580368037803880398040804180428043804480458046804780488049805080518052805380548055805680578058805980608061806280638064806580668067806880698070807180728073807480758076807780788079808080818082808380848085808680878088808980908091809280938094809580968097809880998100810181028103810481058106810781088109811081118112811381148115811681178118811981208121812281238124812581268127812881298130813181328133813481358136813781388139814081418142814381448145814681478148814981508151815281538154815581568157815881598160816181628163816481658166816781688169817081718172817381748175817681778178817981808181818281838184818581868187818881898190819181928193819481958196819781988199820082018202820382048205820682078208820982108211821282138214821582168217821882198220822182228223822482258226822782288229823082318232823382348235823682378238823982408241824282438244824582468247824882498250825182528253825482558256825782588259826082618262826382648265826682678268826982708271827282738274827582768277
  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.29"
  22. info:
  23. title: "Docker Engine API"
  24. version: "1.29"
  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 Docker client uses to communicate with the Engine, so everything the Docker client can do can be done with the API.
  29. Most of the client's commands map directly to API endpoints (e.g. `docker ps` is `GET /containers/json`). The notable exception is running containers, which consists of several API calls.
  30. # Errors
  31. The API uses standard HTTP status codes to indicate the success or failure of the API call. The body of the response will be JSON in the following format:
  32. ```
  33. {
  34. "message": "page not found"
  35. }
  36. ```
  37. # Versioning
  38. The API is usually changed in each release of Docker, so API calls are versioned to ensure that clients don't break.
  39. For Docker Engine 17.05, the API version is 1.29. To lock to this version, you prefix the URL with `/v1.29`. For example, calling `/info` is the same as calling `/v1.29/info`.
  40. Engine releases in the near future should support this version of the API, so your client will continue to work even if it is talking to a newer Engine.
  41. In previous versions of Docker, it was possible to access the API without providing a version. This behaviour is now deprecated will be removed in a future version of Docker.
  42. The API uses an open schema model, which means server may add extra properties to responses. Likewise, the server will ignore any extra query parameters and request body properties. When you write clients, you need to ignore additional properties in responses to ensure they do not break when talking to newer Docker daemons.
  43. This documentation is for version 1.29 of the API, which was introduced with Docker 17.05. Use this table to find documentation for previous versions of the API:
  44. Docker version | API version | Changes
  45. ----------------|-------------|---------
  46. 17.04.x | [1.28](https://docs.docker.com/engine/api/v1.28/) | [API changes](https://docs.docker.com/engine/api/version-history/#v1-28-api-changes)
  47. 17.03.1 | [1.27](https://docs.docker.com/engine/api/v1.27/) | [API changes](https://docs.docker.com/engine/api/version-history/#v1-27-api-changes)
  48. 1.13.1 & 17.03.0 | [1.26](https://docs.docker.com/engine/api/v1.26/) | [API changes](https://docs.docker.com/engine/api/version-history/#v1-26-api-changes)
  49. 1.13.0 | [1.25](https://docs.docker.com/engine/api/v1.25/) | [API changes](https://docs.docker.com/engine/api/version-history/#v1-25-api-changes)
  50. 1.12.x | [1.24](https://docs.docker.com/engine/api/v1.24/) | [API changes](https://docs.docker.com/engine/api/version-history/#v1-24-api-changes)
  51. 1.11.x | [1.23](https://docs.docker.com/engine/api/v1.23/) | [API changes](https://docs.docker.com/engine/api/version-history/#v1-23-api-changes)
  52. 1.10.x | [1.22](https://docs.docker.com/engine/api/v1.22/) | [API changes](https://docs.docker.com/engine/api/version-history/#v1-22-api-changes)
  53. 1.9.x | [1.21](https://docs.docker.com/engine/api/v1.21/) | [API changes](https://docs.docker.com/engine/api/version-history/#v1-21-api-changes)
  54. 1.8.x | [1.20](https://docs.docker.com/engine/api/v1.20/) | [API changes](https://docs.docker.com/engine/api/version-history/#v1-20-api-changes)
  55. 1.7.x | [1.19](https://docs.docker.com/engine/api/v1.19/) | [API changes](https://docs.docker.com/engine/api/version-history/#v1-19-api-changes)
  56. 1.6.x | [1.18](https://docs.docker.com/engine/api/v1.18/) | [API changes](https://docs.docker.com/engine/api/version-history/#v1-18-api-changes)
  57. # Authentication
  58. Authentication for registries is handled client side. The client has to send authentication details to various endpoints that need to communicate with registries, such as `POST /images/(name)/push`. These are sent as `X-Registry-Auth` header as a Base64 encoded (JSON) string with the following structure:
  59. ```
  60. {
  61. "username": "string",
  62. "password": "string",
  63. "email": "string",
  64. "serveraddress": "string"
  65. }
  66. ```
  67. The `serveraddress` is a domain/IP without a protocol. Throughout this structure, double quotes are required.
  68. If you have already got an identity token from the [`/auth` endpoint](#operation/SystemAuth), you can just pass this instead of credentials:
  69. ```
  70. {
  71. "identitytoken": "9cbaf023786cd7..."
  72. }
  73. ```
  74. # The tags on paths define the menu sections in the ReDoc documentation, so
  75. # the usage of tags must make sense for that:
  76. # - They should be singular, not plural.
  77. # - There should not be too many tags, or the menu becomes unwieldy. For
  78. # example, it is preferable to add a path to the "System" tag instead of
  79. # creating a tag with a single path in it.
  80. # - The order of tags in this list defines the order in the menu.
  81. tags:
  82. # Primary objects
  83. - name: "Container"
  84. x-displayName: "Containers"
  85. description: |
  86. Create and manage containers.
  87. - name: "Image"
  88. x-displayName: "Images"
  89. - name: "Network"
  90. x-displayName: "Networks"
  91. description: |
  92. Networks are user-defined networks that containers can be attached to. See the [networking documentation](https://docs.docker.com/network/) for more information.
  93. - name: "Volume"
  94. x-displayName: "Volumes"
  95. description: |
  96. Create and manage persistent storage that can be attached to containers.
  97. - name: "Exec"
  98. x-displayName: "Exec"
  99. description: |
  100. Run new commands inside running containers. See the [command-line reference](https://docs.docker.com/engine/reference/commandline/exec/) for more information.
  101. To exec a command in a container, you first need to create an exec instance, then start it. These two API endpoints are wrapped up in a single command-line command, `docker exec`.
  102. # Swarm things
  103. - name: "Swarm"
  104. x-displayName: "Swarm"
  105. description: |
  106. Engines can be clustered together in a swarm. See [the swarm mode documentation](https://docs.docker.com/engine/swarm/) for more information.
  107. - name: "Node"
  108. x-displayName: "Nodes"
  109. description: |
  110. Nodes are instances of the Engine participating in a swarm. Swarm mode must be enabled for these endpoints to work.
  111. - name: "Service"
  112. x-displayName: "Services"
  113. description: |
  114. Services are the definitions of tasks to run on a swarm. Swarm mode must be enabled for these endpoints to work.
  115. - name: "Task"
  116. x-displayName: "Tasks"
  117. description: |
  118. A task is a container running on a swarm. It is the atomic scheduling unit of swarm. Swarm mode must be enabled for these endpoints to work.
  119. - name: "Secret"
  120. x-displayName: "Secrets"
  121. description: |
  122. Secrets are sensitive data that can be used by services. Swarm mode must be enabled for these endpoints to work.
  123. # System things
  124. - name: "Plugin"
  125. x-displayName: "Plugins"
  126. - name: "System"
  127. x-displayName: "System"
  128. definitions:
  129. Port:
  130. type: "object"
  131. description: "An open port on a container"
  132. required: [PrivatePort, Type]
  133. properties:
  134. IP:
  135. type: "string"
  136. format: "ip-address"
  137. PrivatePort:
  138. type: "integer"
  139. format: "uint16"
  140. x-nullable: false
  141. description: "Port on the container"
  142. PublicPort:
  143. type: "integer"
  144. format: "uint16"
  145. description: "Port exposed on the host"
  146. Type:
  147. type: "string"
  148. x-nullable: false
  149. enum: ["tcp", "udp"]
  150. example:
  151. PrivatePort: 8080
  152. PublicPort: 80
  153. Type: "tcp"
  154. MountPoint:
  155. type: "object"
  156. description: |
  157. MountPoint represents a mount point configuration inside the container.
  158. This is used for reporting the mountpoints in use by a container.
  159. properties:
  160. Type:
  161. description: |
  162. The mount type:
  163. - `bind` a mount of a file or directory from the host into the container.
  164. - `volume` a docker volume with the given `Name`.
  165. - `tmpfs` a `tmpfs`.
  166. type: "string"
  167. enum:
  168. - "bind"
  169. - "volume"
  170. - "tmpfs"
  171. example: "volume"
  172. Name:
  173. description: |
  174. Name is the name reference to the underlying data defined by `Source`
  175. e.g., the volume name.
  176. type: "string"
  177. example: "myvolume"
  178. Source:
  179. description: |
  180. Source location of the mount.
  181. For volumes, this contains the storage location of the volume (within
  182. `/var/lib/docker/volumes/`). For bind-mounts, and `npipe`, this contains
  183. the source (host) part of the bind-mount. For `tmpfs` mount points, this
  184. field is empty.
  185. type: "string"
  186. example: "/var/lib/docker/volumes/myvolume/_data"
  187. Destination:
  188. description: |
  189. Destination is the path relative to the container root (`/`) where
  190. the `Source` is mounted inside the container.
  191. type: "string"
  192. example: "/usr/share/nginx/html/"
  193. Driver:
  194. description: |
  195. Driver is the volume driver used to create the volume (if it is a volume).
  196. type: "string"
  197. example: "local"
  198. Mode:
  199. description: |
  200. Mode is a comma separated list of options supplied by the user when
  201. creating the bind/volume mount.
  202. The default is platform-specific (`"z"` on Linux, empty on Windows).
  203. type: "string"
  204. example: "z"
  205. RW:
  206. description: |
  207. Whether the mount is mounted writable (read-write).
  208. type: "boolean"
  209. example: true
  210. Propagation:
  211. description: |
  212. Propagation describes how mounts are propagated from the host into the
  213. mount point, and vice-versa. Refer to the [Linux kernel documentation](https://www.kernel.org/doc/Documentation/filesystems/sharedsubtree.txt)
  214. for details. This field is not used on Windows.
  215. type: "string"
  216. example: ""
  217. DeviceMapping:
  218. type: "object"
  219. description: "A device mapping between the host and container"
  220. properties:
  221. PathOnHost:
  222. type: "string"
  223. PathInContainer:
  224. type: "string"
  225. CgroupPermissions:
  226. type: "string"
  227. example:
  228. PathOnHost: "/dev/deviceName"
  229. PathInContainer: "/dev/deviceName"
  230. CgroupPermissions: "mrw"
  231. ThrottleDevice:
  232. type: "object"
  233. properties:
  234. Path:
  235. description: "Device path"
  236. type: "string"
  237. Rate:
  238. description: "Rate"
  239. type: "integer"
  240. format: "int64"
  241. minimum: 0
  242. Mount:
  243. type: "object"
  244. properties:
  245. Target:
  246. description: "Container path."
  247. type: "string"
  248. Source:
  249. description: "Mount source (e.g. a volume name, a host path)."
  250. Type:
  251. description: |
  252. The mount type. Available types:
  253. - `bind` Mounts a file or directory from the host into the container. Must exist prior to creating the container.
  254. - `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.
  255. - `tmpfs` Create a tmpfs with the given options. The mount source cannot be specified for tmpfs.
  256. type: "string"
  257. enum:
  258. - "bind"
  259. - "volume"
  260. - "tmpfs"
  261. ReadOnly:
  262. description: "Whether the mount should be read-only."
  263. type: "boolean"
  264. Consistency:
  265. description: "The consistency requirement for the mount: `default`, `consistent`, `cached`, or `delegated`."
  266. type: "string"
  267. BindOptions:
  268. description: "Optional configuration for the `bind` type."
  269. type: "object"
  270. properties:
  271. Propagation:
  272. description: "A propagation mode with the value `[r]private`, `[r]shared`, or `[r]slave`."
  273. enum:
  274. - "private"
  275. - "rprivate"
  276. - "shared"
  277. - "rshared"
  278. - "slave"
  279. - "rslave"
  280. VolumeOptions:
  281. description: "Optional configuration for the `volume` type."
  282. type: "object"
  283. properties:
  284. NoCopy:
  285. description: "Populate volume with data from the target."
  286. type: "boolean"
  287. default: false
  288. Labels:
  289. description: "User-defined key/value metadata."
  290. type: "object"
  291. additionalProperties:
  292. type: "string"
  293. DriverConfig:
  294. description: "Map of driver specific options"
  295. type: "object"
  296. properties:
  297. Name:
  298. description: "Name of the driver to use to create the volume."
  299. type: "string"
  300. Options:
  301. description: "key/value map of driver specific options."
  302. type: "object"
  303. additionalProperties:
  304. type: "string"
  305. TmpfsOptions:
  306. description: "Optional configuration for the `tmpfs` type."
  307. type: "object"
  308. properties:
  309. SizeBytes:
  310. description: "The size for the tmpfs mount in bytes."
  311. type: "integer"
  312. format: "int64"
  313. Mode:
  314. description: "The permission mode for the tmpfs mount in an integer."
  315. type: "integer"
  316. RestartPolicy:
  317. description: |
  318. The behavior to apply when the container exits. The default is not to restart.
  319. An ever increasing delay (double the previous delay, starting at 100ms) is added before each restart to prevent flooding the server.
  320. type: "object"
  321. properties:
  322. Name:
  323. type: "string"
  324. description: |
  325. - `always` Always restart
  326. - `unless-stopped` Restart always except when the user has manually stopped the container
  327. - `on-failure` Restart only when the container exit code is non-zero
  328. enum:
  329. - "always"
  330. - "unless-stopped"
  331. - "on-failure"
  332. MaximumRetryCount:
  333. type: "integer"
  334. description: "If `on-failure` is used, the number of times to retry before giving up"
  335. default: {}
  336. Resources:
  337. description: "A container's resources (cgroups config, ulimits, etc)"
  338. type: "object"
  339. properties:
  340. # Applicable to all platforms
  341. CpuShares:
  342. description: "An integer value representing this container's relative CPU weight versus other containers."
  343. type: "integer"
  344. Memory:
  345. description: "Memory limit in bytes."
  346. type: "integer"
  347. default: 0
  348. # Applicable to UNIX platforms
  349. CgroupParent:
  350. description: "Path to `cgroups` under which the container's `cgroup` is created. If the path is not absolute, the path is considered to be relative to the `cgroups` path of the init process. Cgroups are created if they do not already exist."
  351. type: "string"
  352. BlkioWeight:
  353. description: "Block IO weight (relative weight)."
  354. type: "integer"
  355. minimum: 0
  356. maximum: 1000
  357. BlkioWeightDevice:
  358. description: |
  359. Block IO weight (relative device weight) in the form `[{"Path": "device_path", "Weight": weight}]`.
  360. type: "array"
  361. items:
  362. type: "object"
  363. properties:
  364. Path:
  365. type: "string"
  366. Weight:
  367. type: "integer"
  368. minimum: 0
  369. BlkioDeviceReadBps:
  370. description: |
  371. Limit read rate (bytes per second) from a device, in the form `[{"Path": "device_path", "Rate": rate}]`.
  372. type: "array"
  373. items:
  374. $ref: "#/definitions/ThrottleDevice"
  375. BlkioDeviceWriteBps:
  376. description: |
  377. Limit write rate (bytes per second) to a device, in the form `[{"Path": "device_path", "Rate": rate}]`.
  378. type: "array"
  379. items:
  380. $ref: "#/definitions/ThrottleDevice"
  381. BlkioDeviceReadIOps:
  382. description: |
  383. Limit read rate (IO per second) from a device, in the form `[{"Path": "device_path", "Rate": rate}]`.
  384. type: "array"
  385. items:
  386. $ref: "#/definitions/ThrottleDevice"
  387. BlkioDeviceWriteIOps:
  388. description: |
  389. Limit write rate (IO per second) to a device, in the form `[{"Path": "device_path", "Rate": rate}]`.
  390. type: "array"
  391. items:
  392. $ref: "#/definitions/ThrottleDevice"
  393. CpuPeriod:
  394. description: "The length of a CPU period in microseconds."
  395. type: "integer"
  396. format: "int64"
  397. CpuQuota:
  398. description: "Microseconds of CPU time that the container can get in a CPU period."
  399. type: "integer"
  400. format: "int64"
  401. CpuRealtimePeriod:
  402. description: "The length of a CPU real-time period in microseconds. Set to 0 to allocate no time allocated to real-time tasks."
  403. type: "integer"
  404. format: "int64"
  405. CpuRealtimeRuntime:
  406. description: "The length of a CPU real-time runtime in microseconds. Set to 0 to allocate no time allocated to real-time tasks."
  407. type: "integer"
  408. format: "int64"
  409. CpusetCpus:
  410. description: "CPUs in which to allow execution (e.g., `0-3`, `0,1`)"
  411. type: "string"
  412. CpusetMems:
  413. description: "Memory nodes (MEMs) in which to allow execution (0-3, 0,1). Only effective on NUMA systems."
  414. type: "string"
  415. Devices:
  416. description: "A list of devices to add to the container."
  417. type: "array"
  418. items:
  419. $ref: "#/definitions/DeviceMapping"
  420. DeviceCgroupRules:
  421. description: "a list of cgroup rules to apply to the container"
  422. type: "array"
  423. items:
  424. type: "string"
  425. example: "c 13:* rwm"
  426. DiskQuota:
  427. description: "Disk limit (in bytes)."
  428. type: "integer"
  429. format: "int64"
  430. KernelMemory:
  431. description: "Kernel memory limit in bytes."
  432. type: "integer"
  433. format: "int64"
  434. MemoryReservation:
  435. description: "Memory soft limit in bytes."
  436. type: "integer"
  437. format: "int64"
  438. MemorySwap:
  439. description: "Total memory limit (memory + swap). Set as `-1` to enable unlimited swap."
  440. type: "integer"
  441. format: "int64"
  442. MemorySwappiness:
  443. description: "Tune a container's memory swappiness behavior. Accepts an integer between 0 and 100."
  444. type: "integer"
  445. format: "int64"
  446. minimum: 0
  447. maximum: 100
  448. NanoCpus:
  449. description: "CPU quota in units of 10<sup>-9</sup> CPUs."
  450. type: "integer"
  451. format: "int64"
  452. OomKillDisable:
  453. description: "Disable OOM Killer for the container."
  454. type: "boolean"
  455. PidsLimit:
  456. description: "Tune a container's pids limit. Set -1 for unlimited."
  457. type: "integer"
  458. format: "int64"
  459. Ulimits:
  460. description: |
  461. A list of resource limits to set in the container. For example: `{"Name": "nofile", "Soft": 1024, "Hard": 2048}`"
  462. type: "array"
  463. items:
  464. type: "object"
  465. properties:
  466. Name:
  467. description: "Name of ulimit"
  468. type: "string"
  469. Soft:
  470. description: "Soft limit"
  471. type: "integer"
  472. Hard:
  473. description: "Hard limit"
  474. type: "integer"
  475. # Applicable to Windows
  476. CpuCount:
  477. description: |
  478. The number of usable CPUs (Windows only).
  479. On Windows Server containers, the processor resource controls are mutually exclusive. The order of precedence is `CPUCount` first, then `CPUShares`, and `CPUPercent` last.
  480. type: "integer"
  481. format: "int64"
  482. CpuPercent:
  483. description: |
  484. The usable percentage of the available CPUs (Windows only).
  485. On Windows Server containers, the processor resource controls are mutually exclusive. The order of precedence is `CPUCount` first, then `CPUShares`, and `CPUPercent` last.
  486. type: "integer"
  487. format: "int64"
  488. IOMaximumIOps:
  489. description: "Maximum IOps for the container system drive (Windows only)"
  490. type: "integer"
  491. format: "int64"
  492. IOMaximumBandwidth:
  493. description: "Maximum IO in bytes per second for the container system drive (Windows only)"
  494. type: "integer"
  495. format: "int64"
  496. HealthConfig:
  497. description: "A test to perform to check that the container is healthy."
  498. type: "object"
  499. properties:
  500. Test:
  501. description: |
  502. The test to perform. Possible values are:
  503. - `[]` inherit healthcheck from image or parent image
  504. - `["NONE"]` disable healthcheck
  505. - `["CMD", args...]` exec arguments directly
  506. - `["CMD-SHELL", command]` run command with system's default shell
  507. type: "array"
  508. items:
  509. type: "string"
  510. Interval:
  511. description: "The time to wait between checks in nanoseconds. It should be 0 or not less than 1000000000(1s). 0 means inherit."
  512. type: "integer"
  513. Timeout:
  514. description: "The time to wait before considering the check to have hung. It should be 0 or not less than 1000000000(1s). 0 means inherit."
  515. type: "integer"
  516. Retries:
  517. description: "The number of consecutive failures needed to consider a container as unhealthy. 0 means inherit."
  518. type: "integer"
  519. StartPeriod:
  520. description: "Start period for the container to initialize before starting health-retries countdown in nanoseconds. 0 means inherit."
  521. type: "integer"
  522. HostConfig:
  523. description: "Container configuration that depends on the host we are running on"
  524. allOf:
  525. - $ref: "#/definitions/Resources"
  526. - type: "object"
  527. properties:
  528. # Applicable to all platforms
  529. Binds:
  530. type: "array"
  531. description: |
  532. A list of volume bindings for this container. Each volume binding is a string in one of these forms:
  533. - `host-src:container-dest` to bind-mount a host path into the container. Both `host-src`, and `container-dest` must be an _absolute_ path.
  534. - `host-src:container-dest:ro` to make the bind-mount read-only inside the container. Both `host-src`, and `container-dest` must be an _absolute_ path.
  535. - `volume-name:container-dest` to bind-mount a volume managed by a volume driver into the container. `container-dest` must be an _absolute_ path.
  536. - `volume-name:container-dest:ro` to mount the volume read-only inside the container. `container-dest` must be an _absolute_ path.
  537. items:
  538. type: "string"
  539. ContainerIDFile:
  540. type: "string"
  541. description: "Path to a file where the container ID is written"
  542. LogConfig:
  543. type: "object"
  544. description: "The logging configuration for this container"
  545. properties:
  546. Type:
  547. type: "string"
  548. enum:
  549. - "json-file"
  550. - "syslog"
  551. - "journald"
  552. - "gelf"
  553. - "fluentd"
  554. - "awslogs"
  555. - "splunk"
  556. - "etwlogs"
  557. - "none"
  558. Config:
  559. type: "object"
  560. additionalProperties:
  561. type: "string"
  562. NetworkMode:
  563. type: "string"
  564. description: "Network mode to use for this container. Supported standard values are: `bridge`, `host`, `none`, and `container:<name|id>`. Any other value is taken
  565. as a custom network's name to which this container should connect to."
  566. PortBindings:
  567. type: "object"
  568. description: "A map of exposed container ports and the host port they should map to."
  569. additionalProperties:
  570. type: "object"
  571. properties:
  572. HostIp:
  573. type: "string"
  574. description: "The host IP address"
  575. HostPort:
  576. type: "string"
  577. description: "The host port number, as a string"
  578. RestartPolicy:
  579. $ref: "#/definitions/RestartPolicy"
  580. AutoRemove:
  581. type: "boolean"
  582. description: "Automatically remove the container when the container's process exits. This has no effect if `RestartPolicy` is set."
  583. VolumeDriver:
  584. type: "string"
  585. description: "Driver that this container uses to mount volumes."
  586. VolumesFrom:
  587. type: "array"
  588. description: "A list of volumes to inherit from another container, specified in the form `<container name>[:<ro|rw>]`."
  589. items:
  590. type: "string"
  591. Mounts:
  592. description: "Specification for mounts to be added to the container."
  593. type: "array"
  594. items:
  595. $ref: "#/definitions/Mount"
  596. # Applicable to UNIX platforms
  597. CapAdd:
  598. type: "array"
  599. description: "A list of kernel capabilities to add to the container."
  600. items:
  601. type: "string"
  602. CapDrop:
  603. type: "array"
  604. description: "A list of kernel capabilities to drop from the container."
  605. items:
  606. type: "string"
  607. Dns:
  608. type: "array"
  609. description: "A list of DNS servers for the container to use."
  610. items:
  611. type: "string"
  612. DnsOptions:
  613. type: "array"
  614. description: "A list of DNS options."
  615. items:
  616. type: "string"
  617. DnsSearch:
  618. type: "array"
  619. description: "A list of DNS search domains."
  620. items:
  621. type: "string"
  622. ExtraHosts:
  623. type: "array"
  624. description: |
  625. A list of hostnames/IP mappings to add to the container's `/etc/hosts` file. Specified in the form `["hostname:IP"]`.
  626. items:
  627. type: "string"
  628. GroupAdd:
  629. type: "array"
  630. description: "A list of additional groups that the container process will run as."
  631. items:
  632. type: "string"
  633. IpcMode:
  634. type: "string"
  635. description: "IPC namespace to use for the container."
  636. Cgroup:
  637. type: "string"
  638. description: "Cgroup to use for the container."
  639. Links:
  640. type: "array"
  641. description: "A list of links for the container in the form `container_name:alias`."
  642. items:
  643. type: "string"
  644. OomScoreAdj:
  645. type: "integer"
  646. description: "An integer value containing the score given to the container in order to tune OOM killer preferences."
  647. PidMode:
  648. type: "string"
  649. description: |
  650. Set the PID (Process) Namespace mode for the container. It can be either:
  651. - `"container:<name|id>"`: joins another container's PID namespace
  652. - `"host"`: use the host's PID namespace inside the container
  653. Privileged:
  654. type: "boolean"
  655. description: "Gives the container full access to the host."
  656. PublishAllPorts:
  657. type: "boolean"
  658. description: "Allocates a random host port for all of a container's exposed ports."
  659. ReadonlyRootfs:
  660. type: "boolean"
  661. description: "Mount the container's root filesystem as read only."
  662. SecurityOpt:
  663. type: "array"
  664. description: "A list of string values to customize labels for MLS
  665. systems, such as SELinux."
  666. items:
  667. type: "string"
  668. StorageOpt:
  669. type: "object"
  670. description: |
  671. Storage driver options for this container, in the form `{"size": "120G"}`.
  672. additionalProperties:
  673. type: "string"
  674. Tmpfs:
  675. type: "object"
  676. description: |
  677. A map of container directories which should be replaced by tmpfs mounts, and their corresponding mount options. For example: `{ "/run": "rw,noexec,nosuid,size=65536k" }`.
  678. additionalProperties:
  679. type: "string"
  680. UTSMode:
  681. type: "string"
  682. description: "UTS namespace to use for the container."
  683. UsernsMode:
  684. type: "string"
  685. description: "Sets the usernamespace mode for the container when usernamespace remapping option is enabled."
  686. ShmSize:
  687. type: "integer"
  688. description: "Size of `/dev/shm` in bytes. If omitted, the system uses 64MB."
  689. minimum: 0
  690. Sysctls:
  691. type: "object"
  692. description: |
  693. A list of kernel parameters (sysctls) to set in the container. For example: `{"net.ipv4.ip_forward": "1"}`
  694. additionalProperties:
  695. type: "string"
  696. Runtime:
  697. type: "string"
  698. description: "Runtime to use with this container."
  699. # Applicable to Windows
  700. ConsoleSize:
  701. type: "array"
  702. description: "Initial console size, as an `[height, width]` array. (Windows only)"
  703. minItems: 2
  704. maxItems: 2
  705. items:
  706. type: "integer"
  707. minimum: 0
  708. Isolation:
  709. type: "string"
  710. description: "Isolation technology of the container. (Windows only)"
  711. enum:
  712. - "default"
  713. - "process"
  714. - "hyperv"
  715. Config:
  716. description: "Configuration for a container that is portable between hosts"
  717. type: "object"
  718. properties:
  719. Hostname:
  720. description: "The hostname to use for the container, as a valid RFC 1123 hostname."
  721. type: "string"
  722. Domainname:
  723. description: "The domain name to use for the container."
  724. type: "string"
  725. User:
  726. description: "The user that commands are run as inside the container."
  727. type: "string"
  728. AttachStdin:
  729. description: "Whether to attach to `stdin`."
  730. type: "boolean"
  731. default: false
  732. AttachStdout:
  733. description: "Whether to attach to `stdout`."
  734. type: "boolean"
  735. default: true
  736. AttachStderr:
  737. description: "Whether to attach to `stderr`."
  738. type: "boolean"
  739. default: true
  740. ExposedPorts:
  741. description: |
  742. An object mapping ports to an empty object in the form:
  743. `{"<port>/<tcp|udp>": {}}`
  744. type: "object"
  745. additionalProperties:
  746. type: "object"
  747. enum:
  748. - {}
  749. default: {}
  750. Tty:
  751. description: "Attach standard streams to a TTY, including `stdin` if it is not closed."
  752. type: "boolean"
  753. default: false
  754. OpenStdin:
  755. description: "Open `stdin`"
  756. type: "boolean"
  757. default: false
  758. StdinOnce:
  759. description: "Close `stdin` after one attached client disconnects"
  760. type: "boolean"
  761. default: false
  762. Env:
  763. description: |
  764. A list of environment variables to set inside the container in the form `["VAR=value", ...]`. A variable without `=` is removed from the environment, rather than to have an empty value.
  765. type: "array"
  766. items:
  767. type: "string"
  768. Cmd:
  769. description: "Command to run specified as a string or an array of strings."
  770. type:
  771. - "array"
  772. - "string"
  773. items:
  774. type: "string"
  775. Healthcheck:
  776. $ref: "#/definitions/HealthConfig"
  777. ArgsEscaped:
  778. description: "Command is already escaped (Windows only)"
  779. type: "boolean"
  780. Image:
  781. description: "The name of the image to use when creating the container"
  782. type: "string"
  783. Volumes:
  784. description: "An object mapping mount point paths inside the container to empty objects."
  785. type: "object"
  786. properties:
  787. additionalProperties:
  788. type: "object"
  789. enum:
  790. - {}
  791. default: {}
  792. WorkingDir:
  793. description: "The working directory for commands to run in."
  794. type: "string"
  795. Entrypoint:
  796. description: |
  797. The entry point for the container as a string or an array of strings.
  798. If the array consists of exactly one empty string (`[""]`) then the entry point is reset to system default (i.e., the entry point used by docker when there is no `ENTRYPOINT` instruction in the `Dockerfile`).
  799. type:
  800. - "array"
  801. - "string"
  802. items:
  803. type: "string"
  804. NetworkDisabled:
  805. description: "Disable networking for the container."
  806. type: "boolean"
  807. MacAddress:
  808. description: "MAC address of the container."
  809. type: "string"
  810. OnBuild:
  811. description: "`ONBUILD` metadata that were defined in the image's `Dockerfile`."
  812. type: "array"
  813. items:
  814. type: "string"
  815. Labels:
  816. description: "User-defined key/value metadata."
  817. type: "object"
  818. additionalProperties:
  819. type: "string"
  820. StopSignal:
  821. description: "Signal to stop a container as a string or unsigned integer."
  822. type: "string"
  823. default: "SIGTERM"
  824. StopTimeout:
  825. description: "Timeout to stop a container in seconds."
  826. type: "integer"
  827. default: 10
  828. Shell:
  829. description: "Shell for when `RUN`, `CMD`, and `ENTRYPOINT` uses a shell."
  830. type: "array"
  831. items:
  832. type: "string"
  833. NetworkConfig:
  834. description: "TODO: check is correct"
  835. type: "object"
  836. properties:
  837. Bridge:
  838. type: "string"
  839. Gateway:
  840. type: "string"
  841. Address:
  842. type: "string"
  843. IPPrefixLen:
  844. type: "integer"
  845. MacAddress:
  846. type: "string"
  847. PortMapping:
  848. type: "string"
  849. Ports:
  850. type: "array"
  851. items:
  852. $ref: "#/definitions/Port"
  853. GraphDriverData:
  854. description: "Information about a container's graph driver."
  855. type: "object"
  856. required: [Name, Data]
  857. properties:
  858. Name:
  859. type: "string"
  860. x-nullable: false
  861. Data:
  862. type: "object"
  863. x-nullable: false
  864. additionalProperties:
  865. type: "string"
  866. Image:
  867. type: "object"
  868. required:
  869. - Id
  870. - Parent
  871. - Comment
  872. - Created
  873. - Container
  874. - DockerVersion
  875. - Author
  876. - Architecture
  877. - Os
  878. - Size
  879. - VirtualSize
  880. - GraphDriver
  881. - RootFS
  882. properties:
  883. Id:
  884. type: "string"
  885. x-nullable: false
  886. RepoTags:
  887. type: "array"
  888. items:
  889. type: "string"
  890. RepoDigests:
  891. type: "array"
  892. items:
  893. type: "string"
  894. Parent:
  895. type: "string"
  896. x-nullable: false
  897. Comment:
  898. type: "string"
  899. x-nullable: false
  900. Created:
  901. type: "string"
  902. x-nullable: false
  903. Container:
  904. type: "string"
  905. x-nullable: false
  906. ContainerConfig:
  907. $ref: "#/definitions/Config"
  908. DockerVersion:
  909. type: "string"
  910. x-nullable: false
  911. Author:
  912. type: "string"
  913. x-nullable: false
  914. Config:
  915. $ref: "#/definitions/Config"
  916. Architecture:
  917. type: "string"
  918. x-nullable: false
  919. Os:
  920. type: "string"
  921. x-nullable: false
  922. OsVersion:
  923. type: "string"
  924. Size:
  925. type: "integer"
  926. format: "int64"
  927. x-nullable: false
  928. VirtualSize:
  929. type: "integer"
  930. format: "int64"
  931. x-nullable: false
  932. GraphDriver:
  933. $ref: "#/definitions/GraphDriverData"
  934. RootFS:
  935. type: "object"
  936. required: [Type]
  937. properties:
  938. Type:
  939. type: "string"
  940. x-nullable: false
  941. Layers:
  942. type: "array"
  943. items:
  944. type: "string"
  945. ImageSummary:
  946. type: "object"
  947. required:
  948. - Id
  949. - ParentId
  950. - RepoTags
  951. - RepoDigests
  952. - Created
  953. - Size
  954. - SharedSize
  955. - VirtualSize
  956. - Labels
  957. - Containers
  958. properties:
  959. Id:
  960. type: "string"
  961. x-nullable: false
  962. ParentId:
  963. type: "string"
  964. x-nullable: false
  965. RepoTags:
  966. type: "array"
  967. x-nullable: false
  968. items:
  969. type: "string"
  970. RepoDigests:
  971. type: "array"
  972. x-nullable: false
  973. items:
  974. type: "string"
  975. Created:
  976. type: "integer"
  977. x-nullable: false
  978. Size:
  979. type: "integer"
  980. x-nullable: false
  981. SharedSize:
  982. type: "integer"
  983. x-nullable: false
  984. VirtualSize:
  985. type: "integer"
  986. x-nullable: false
  987. Labels:
  988. type: "object"
  989. x-nullable: false
  990. additionalProperties:
  991. type: "string"
  992. Containers:
  993. x-nullable: false
  994. type: "integer"
  995. AuthConfig:
  996. type: "object"
  997. properties:
  998. username:
  999. type: "string"
  1000. password:
  1001. type: "string"
  1002. email:
  1003. type: "string"
  1004. serveraddress:
  1005. type: "string"
  1006. example:
  1007. username: "hannibal"
  1008. password: "xxxx"
  1009. serveraddress: "https://index.docker.io/v1/"
  1010. ProcessConfig:
  1011. type: "object"
  1012. properties:
  1013. privileged:
  1014. type: "boolean"
  1015. user:
  1016. type: "string"
  1017. tty:
  1018. type: "boolean"
  1019. entrypoint:
  1020. type: "string"
  1021. arguments:
  1022. type: "array"
  1023. items:
  1024. type: "string"
  1025. Volume:
  1026. type: "object"
  1027. required: [Name, Driver, Mountpoint, Labels, Scope, Options]
  1028. properties:
  1029. Name:
  1030. type: "string"
  1031. description: "Name of the volume."
  1032. x-nullable: false
  1033. Driver:
  1034. type: "string"
  1035. description: "Name of the volume driver used by the volume."
  1036. x-nullable: false
  1037. Mountpoint:
  1038. type: "string"
  1039. description: "Mount path of the volume on the host."
  1040. x-nullable: false
  1041. Status:
  1042. type: "object"
  1043. description: |
  1044. Low-level details about the volume, provided by the volume driver.
  1045. Details are returned as a map with key/value pairs:
  1046. `{"key":"value","key2":"value2"}`.
  1047. The `Status` field is optional, and is omitted if the volume driver
  1048. does not support this feature.
  1049. additionalProperties:
  1050. type: "object"
  1051. Labels:
  1052. type: "object"
  1053. description: "User-defined key/value metadata."
  1054. x-nullable: false
  1055. additionalProperties:
  1056. type: "string"
  1057. Scope:
  1058. type: "string"
  1059. description: "The level at which the volume exists. Either `global` for cluster-wide, or `local` for machine level."
  1060. default: "local"
  1061. x-nullable: false
  1062. enum: ["local", "global"]
  1063. Options:
  1064. type: "object"
  1065. description: "The driver specific options used when creating the volume."
  1066. additionalProperties:
  1067. type: "string"
  1068. UsageData:
  1069. type: "object"
  1070. required: [Size, RefCount]
  1071. properties:
  1072. Size:
  1073. type: "integer"
  1074. description: "The disk space used by the volume (local driver only)"
  1075. default: -1
  1076. x-nullable: false
  1077. RefCount:
  1078. type: "integer"
  1079. default: -1
  1080. description: "The number of containers referencing this volume."
  1081. x-nullable: false
  1082. example:
  1083. Name: "tardis"
  1084. Driver: "custom"
  1085. Mountpoint: "/var/lib/docker/volumes/tardis"
  1086. Status:
  1087. hello: "world"
  1088. Labels:
  1089. com.example.some-label: "some-value"
  1090. com.example.some-other-label: "some-other-value"
  1091. Scope: "local"
  1092. Network:
  1093. type: "object"
  1094. properties:
  1095. Name:
  1096. type: "string"
  1097. Id:
  1098. type: "string"
  1099. Created:
  1100. type: "string"
  1101. format: "dateTime"
  1102. Scope:
  1103. type: "string"
  1104. Driver:
  1105. type: "string"
  1106. EnableIPv6:
  1107. type: "boolean"
  1108. IPAM:
  1109. $ref: "#/definitions/IPAM"
  1110. Internal:
  1111. type: "boolean"
  1112. Attachable:
  1113. type: "boolean"
  1114. Ingress:
  1115. type: "boolean"
  1116. Containers:
  1117. type: "object"
  1118. additionalProperties:
  1119. $ref: "#/definitions/NetworkContainer"
  1120. Options:
  1121. type: "object"
  1122. additionalProperties:
  1123. type: "string"
  1124. Labels:
  1125. type: "object"
  1126. additionalProperties:
  1127. type: "string"
  1128. example:
  1129. Name: "net01"
  1130. Id: "7d86d31b1478e7cca9ebed7e73aa0fdeec46c5ca29497431d3007d2d9e15ed99"
  1131. Created: "2016-10-19T04:33:30.360899459Z"
  1132. Scope: "local"
  1133. Driver: "bridge"
  1134. EnableIPv6: false
  1135. IPAM:
  1136. Driver: "default"
  1137. Config:
  1138. - Subnet: "172.19.0.0/16"
  1139. Gateway: "172.19.0.1"
  1140. Options:
  1141. foo: "bar"
  1142. Internal: false
  1143. Attachable: false
  1144. Ingress: false
  1145. Containers:
  1146. 19a4d5d687db25203351ed79d478946f861258f018fe384f229f2efa4b23513c:
  1147. Name: "test"
  1148. EndpointID: "628cadb8bcb92de107b2a1e516cbffe463e321f548feb37697cce00ad694f21a"
  1149. MacAddress: "02:42:ac:13:00:02"
  1150. IPv4Address: "172.19.0.2/16"
  1151. IPv6Address: ""
  1152. Options:
  1153. com.docker.network.bridge.default_bridge: "true"
  1154. com.docker.network.bridge.enable_icc: "true"
  1155. com.docker.network.bridge.enable_ip_masquerade: "true"
  1156. com.docker.network.bridge.host_binding_ipv4: "0.0.0.0"
  1157. com.docker.network.bridge.name: "docker0"
  1158. com.docker.network.driver.mtu: "1500"
  1159. Labels:
  1160. com.example.some-label: "some-value"
  1161. com.example.some-other-label: "some-other-value"
  1162. IPAM:
  1163. type: "object"
  1164. properties:
  1165. Driver:
  1166. description: "Name of the IPAM driver to use."
  1167. type: "string"
  1168. default: "default"
  1169. Config:
  1170. description: "List of IPAM configuration options, specified as a map: `{\"Subnet\": <CIDR>, \"IPRange\": <CIDR>, \"Gateway\": <IP address>, \"AuxAddress\": <device_name:IP address>}`"
  1171. type: "array"
  1172. items:
  1173. type: "object"
  1174. additionalProperties:
  1175. type: "string"
  1176. Options:
  1177. description: "Driver-specific options, specified as a map."
  1178. type: "array"
  1179. items:
  1180. type: "object"
  1181. additionalProperties:
  1182. type: "string"
  1183. NetworkContainer:
  1184. type: "object"
  1185. properties:
  1186. EndpointID:
  1187. type: "string"
  1188. MacAddress:
  1189. type: "string"
  1190. IPv4Address:
  1191. type: "string"
  1192. IPv6Address:
  1193. type: "string"
  1194. BuildInfo:
  1195. type: "object"
  1196. properties:
  1197. id:
  1198. type: "string"
  1199. stream:
  1200. type: "string"
  1201. error:
  1202. type: "string"
  1203. errorDetail:
  1204. $ref: "#/definitions/ErrorDetail"
  1205. status:
  1206. type: "string"
  1207. progress:
  1208. type: "string"
  1209. progressDetail:
  1210. $ref: "#/definitions/ProgressDetail"
  1211. CreateImageInfo:
  1212. type: "object"
  1213. properties:
  1214. error:
  1215. type: "string"
  1216. status:
  1217. type: "string"
  1218. progress:
  1219. type: "string"
  1220. progressDetail:
  1221. $ref: "#/definitions/ProgressDetail"
  1222. PushImageInfo:
  1223. type: "object"
  1224. properties:
  1225. error:
  1226. type: "string"
  1227. status:
  1228. type: "string"
  1229. progress:
  1230. type: "string"
  1231. progressDetail:
  1232. $ref: "#/definitions/ProgressDetail"
  1233. ErrorDetail:
  1234. type: "object"
  1235. properties:
  1236. code:
  1237. type: "integer"
  1238. message:
  1239. type: "string"
  1240. ProgressDetail:
  1241. type: "object"
  1242. properties:
  1243. code:
  1244. type: "integer"
  1245. message:
  1246. type: "integer"
  1247. ErrorResponse:
  1248. description: "Represents an error."
  1249. type: "object"
  1250. required: ["message"]
  1251. properties:
  1252. message:
  1253. description: "The error message."
  1254. type: "string"
  1255. x-nullable: false
  1256. example:
  1257. message: "Something went wrong."
  1258. IdResponse:
  1259. description: "Response to an API call that returns just an Id"
  1260. type: "object"
  1261. required: ["Id"]
  1262. properties:
  1263. Id:
  1264. description: "The id of the newly created object."
  1265. type: "string"
  1266. x-nullable: false
  1267. EndpointSettings:
  1268. description: "Configuration for a network endpoint."
  1269. type: "object"
  1270. properties:
  1271. IPAMConfig:
  1272. description: "IPAM configurations for the endpoint"
  1273. type: "object"
  1274. properties:
  1275. IPv4Address:
  1276. type: "string"
  1277. IPv6Address:
  1278. type: "string"
  1279. LinkLocalIPs:
  1280. type: "array"
  1281. items:
  1282. type: "string"
  1283. Links:
  1284. type: "array"
  1285. items:
  1286. type: "string"
  1287. Aliases:
  1288. type: "array"
  1289. items:
  1290. type: "string"
  1291. NetworkID:
  1292. type: "string"
  1293. EndpointID:
  1294. type: "string"
  1295. Gateway:
  1296. type: "string"
  1297. IPAddress:
  1298. type: "string"
  1299. IPPrefixLen:
  1300. type: "integer"
  1301. IPv6Gateway:
  1302. type: "string"
  1303. GlobalIPv6Address:
  1304. type: "string"
  1305. GlobalIPv6PrefixLen:
  1306. type: "integer"
  1307. format: "int64"
  1308. MacAddress:
  1309. type: "string"
  1310. PluginMount:
  1311. type: "object"
  1312. x-nullable: false
  1313. required: [Name, Description, Settable, Source, Destination, Type, Options]
  1314. properties:
  1315. Name:
  1316. type: "string"
  1317. x-nullable: false
  1318. Description:
  1319. type: "string"
  1320. x-nullable: false
  1321. Settable:
  1322. type: "array"
  1323. items:
  1324. type: "string"
  1325. Source:
  1326. type: "string"
  1327. Destination:
  1328. type: "string"
  1329. x-nullable: false
  1330. Type:
  1331. type: "string"
  1332. x-nullable: false
  1333. Options:
  1334. type: "array"
  1335. items:
  1336. type: "string"
  1337. PluginDevice:
  1338. type: "object"
  1339. required: [Name, Description, Settable, Path]
  1340. x-nullable: false
  1341. properties:
  1342. Name:
  1343. type: "string"
  1344. x-nullable: false
  1345. Description:
  1346. type: "string"
  1347. x-nullable: false
  1348. Settable:
  1349. type: "array"
  1350. items:
  1351. type: "string"
  1352. Path:
  1353. type: "string"
  1354. PluginEnv:
  1355. type: "object"
  1356. x-nullable: false
  1357. required: [Name, Description, Settable, Value]
  1358. properties:
  1359. Name:
  1360. x-nullable: false
  1361. type: "string"
  1362. Description:
  1363. x-nullable: false
  1364. type: "string"
  1365. Settable:
  1366. type: "array"
  1367. items:
  1368. type: "string"
  1369. Value:
  1370. type: "string"
  1371. PluginInterfaceType:
  1372. type: "object"
  1373. x-nullable: false
  1374. required: [Prefix, Capability, Version]
  1375. properties:
  1376. Prefix:
  1377. type: "string"
  1378. x-nullable: false
  1379. Capability:
  1380. type: "string"
  1381. x-nullable: false
  1382. Version:
  1383. type: "string"
  1384. x-nullable: false
  1385. Plugin:
  1386. description: "A plugin for the Engine API"
  1387. type: "object"
  1388. required: [Settings, Enabled, Config, Name]
  1389. properties:
  1390. Id:
  1391. type: "string"
  1392. Name:
  1393. type: "string"
  1394. x-nullable: false
  1395. Enabled:
  1396. description: "True when the plugin is running. False when the plugin is not running, only installed."
  1397. type: "boolean"
  1398. x-nullable: false
  1399. Settings:
  1400. description: "Settings that can be modified by users."
  1401. type: "object"
  1402. x-nullable: false
  1403. required: [Args, Devices, Env, Mounts]
  1404. properties:
  1405. Mounts:
  1406. type: "array"
  1407. items:
  1408. $ref: "#/definitions/PluginMount"
  1409. Env:
  1410. type: "array"
  1411. items:
  1412. type: "string"
  1413. Args:
  1414. type: "array"
  1415. items:
  1416. type: "string"
  1417. Devices:
  1418. type: "array"
  1419. items:
  1420. $ref: "#/definitions/PluginDevice"
  1421. PluginReference:
  1422. description: "plugin remote reference used to push/pull the plugin"
  1423. type: "string"
  1424. x-nullable: false
  1425. Config:
  1426. description: "The config of a plugin."
  1427. type: "object"
  1428. x-nullable: false
  1429. required:
  1430. - Description
  1431. - Documentation
  1432. - Interface
  1433. - Entrypoint
  1434. - WorkDir
  1435. - Network
  1436. - Linux
  1437. - PidHost
  1438. - PropagatedMount
  1439. - IpcHost
  1440. - Mounts
  1441. - Env
  1442. - Args
  1443. properties:
  1444. DockerVersion:
  1445. description: "Docker Version used to create the plugin"
  1446. type: "string"
  1447. x-nullable: false
  1448. Description:
  1449. type: "string"
  1450. x-nullable: false
  1451. Documentation:
  1452. type: "string"
  1453. x-nullable: false
  1454. Interface:
  1455. description: "The interface between Docker and the plugin"
  1456. x-nullable: false
  1457. type: "object"
  1458. required: [Types, Socket]
  1459. properties:
  1460. Types:
  1461. type: "array"
  1462. items:
  1463. $ref: "#/definitions/PluginInterfaceType"
  1464. Socket:
  1465. type: "string"
  1466. x-nullable: false
  1467. Entrypoint:
  1468. type: "array"
  1469. items:
  1470. type: "string"
  1471. WorkDir:
  1472. type: "string"
  1473. x-nullable: false
  1474. User:
  1475. type: "object"
  1476. x-nullable: false
  1477. properties:
  1478. UID:
  1479. type: "integer"
  1480. format: "uint32"
  1481. GID:
  1482. type: "integer"
  1483. format: "uint32"
  1484. Network:
  1485. type: "object"
  1486. x-nullable: false
  1487. required: [Type]
  1488. properties:
  1489. Type:
  1490. x-nullable: false
  1491. type: "string"
  1492. Linux:
  1493. type: "object"
  1494. x-nullable: false
  1495. required: [Capabilities, AllowAllDevices, Devices]
  1496. properties:
  1497. Capabilities:
  1498. type: "array"
  1499. items:
  1500. type: "string"
  1501. AllowAllDevices:
  1502. type: "boolean"
  1503. x-nullable: false
  1504. Devices:
  1505. type: "array"
  1506. items:
  1507. $ref: "#/definitions/PluginDevice"
  1508. PropagatedMount:
  1509. type: "string"
  1510. x-nullable: false
  1511. IpcHost:
  1512. type: "boolean"
  1513. x-nullable: false
  1514. PidHost:
  1515. type: "boolean"
  1516. x-nullable: false
  1517. Mounts:
  1518. type: "array"
  1519. items:
  1520. $ref: "#/definitions/PluginMount"
  1521. Env:
  1522. type: "array"
  1523. items:
  1524. $ref: "#/definitions/PluginEnv"
  1525. Args:
  1526. type: "object"
  1527. x-nullable: false
  1528. required: [Name, Description, Settable, Value]
  1529. properties:
  1530. Name:
  1531. x-nullable: false
  1532. type: "string"
  1533. Description:
  1534. x-nullable: false
  1535. type: "string"
  1536. Settable:
  1537. type: "array"
  1538. items:
  1539. type: "string"
  1540. Value:
  1541. type: "array"
  1542. items:
  1543. type: "string"
  1544. rootfs:
  1545. type: "object"
  1546. properties:
  1547. type:
  1548. type: "string"
  1549. diff_ids:
  1550. type: "array"
  1551. items:
  1552. type: "string"
  1553. example:
  1554. Id: "5724e2c8652da337ab2eedd19fc6fc0ec908e4bd907c7421bf6a8dfc70c4c078"
  1555. Name: "tiborvass/sample-volume-plugin"
  1556. Tag: "latest"
  1557. Active: true
  1558. Settings:
  1559. Env:
  1560. - "DEBUG=0"
  1561. Args: null
  1562. Devices: null
  1563. Config:
  1564. Description: "A sample volume plugin for Docker"
  1565. Documentation: "https://docs.docker.com/engine/extend/plugins/"
  1566. Interface:
  1567. Types:
  1568. - "docker.volumedriver/1.0"
  1569. Socket: "plugins.sock"
  1570. Entrypoint:
  1571. - "/usr/bin/sample-volume-plugin"
  1572. - "/data"
  1573. WorkDir: ""
  1574. User: {}
  1575. Network:
  1576. Type: ""
  1577. Linux:
  1578. Capabilities: null
  1579. AllowAllDevices: false
  1580. Devices: null
  1581. Mounts: null
  1582. PropagatedMount: "/data"
  1583. Env:
  1584. - Name: "DEBUG"
  1585. Description: "If set, prints debug messages"
  1586. Settable: null
  1587. Value: "0"
  1588. Args:
  1589. Name: "args"
  1590. Description: "command line arguments"
  1591. Settable: null
  1592. Value: []
  1593. ObjectVersion:
  1594. description: |
  1595. The version number of the object such as node, service, etc. This is needed to avoid conflicting writes.
  1596. The client must send the version number along with the modified specification when updating these objects.
  1597. This approach ensures safe concurrency and determinism in that the change on the object
  1598. may not be applied if the version number has changed from the last read. In other words,
  1599. if two update requests specify the same base version, only one of the requests can succeed.
  1600. As a result, two separate update requests that happen at the same time will not
  1601. unintentially overwrite each other.
  1602. type: "object"
  1603. properties:
  1604. Index:
  1605. type: "integer"
  1606. format: "int64"
  1607. NodeSpec:
  1608. type: "object"
  1609. properties:
  1610. Name:
  1611. description: "Name for the node."
  1612. type: "string"
  1613. Labels:
  1614. description: "User-defined key/value metadata."
  1615. type: "object"
  1616. additionalProperties:
  1617. type: "string"
  1618. Role:
  1619. description: "Role of the node."
  1620. type: "string"
  1621. enum:
  1622. - "worker"
  1623. - "manager"
  1624. Availability:
  1625. description: "Availability of the node."
  1626. type: "string"
  1627. enum:
  1628. - "active"
  1629. - "pause"
  1630. - "drain"
  1631. example:
  1632. Availability: "active"
  1633. Name: "node-name"
  1634. Role: "manager"
  1635. Labels:
  1636. foo: "bar"
  1637. Node:
  1638. type: "object"
  1639. properties:
  1640. ID:
  1641. type: "string"
  1642. Version:
  1643. $ref: "#/definitions/ObjectVersion"
  1644. CreatedAt:
  1645. type: "string"
  1646. format: "dateTime"
  1647. UpdatedAt:
  1648. type: "string"
  1649. format: "dateTime"
  1650. Spec:
  1651. $ref: "#/definitions/NodeSpec"
  1652. Description:
  1653. type: "object"
  1654. properties:
  1655. Hostname:
  1656. type: "string"
  1657. Platform:
  1658. type: "object"
  1659. properties:
  1660. Architecture:
  1661. type: "string"
  1662. OS:
  1663. type: "string"
  1664. Resources:
  1665. type: "object"
  1666. properties:
  1667. NanoCPUs:
  1668. type: "integer"
  1669. format: "int64"
  1670. MemoryBytes:
  1671. type: "integer"
  1672. format: "int64"
  1673. Engine:
  1674. type: "object"
  1675. properties:
  1676. EngineVersion:
  1677. type: "string"
  1678. Labels:
  1679. type: "object"
  1680. additionalProperties:
  1681. type: "string"
  1682. Plugins:
  1683. type: "array"
  1684. items:
  1685. type: "object"
  1686. properties:
  1687. Type:
  1688. type: "string"
  1689. Name:
  1690. type: "string"
  1691. example:
  1692. ID: "24ifsmvkjbyhk"
  1693. Version:
  1694. Index: 8
  1695. CreatedAt: "2016-06-07T20:31:11.853781916Z"
  1696. UpdatedAt: "2016-06-07T20:31:11.999868824Z"
  1697. Spec:
  1698. Name: "my-node"
  1699. Role: "manager"
  1700. Availability: "active"
  1701. Labels:
  1702. foo: "bar"
  1703. Description:
  1704. Hostname: "bf3067039e47"
  1705. Platform:
  1706. Architecture: "x86_64"
  1707. OS: "linux"
  1708. Resources:
  1709. NanoCPUs: 4000000000
  1710. MemoryBytes: 8272408576
  1711. Engine:
  1712. EngineVersion: "17.04.0"
  1713. Labels:
  1714. foo: "bar"
  1715. Plugins:
  1716. - Type: "Volume"
  1717. Name: "local"
  1718. - Type: "Network"
  1719. Name: "bridge"
  1720. - Type: "Network"
  1721. Name: "null"
  1722. - Type: "Network"
  1723. Name: "overlay"
  1724. Status:
  1725. State: "ready"
  1726. Addr: "172.17.0.2"
  1727. ManagerStatus:
  1728. Leader: true
  1729. Reachability: "reachable"
  1730. Addr: "172.17.0.2:2377"
  1731. SwarmSpec:
  1732. description: "User modifiable swarm configuration."
  1733. type: "object"
  1734. properties:
  1735. Name:
  1736. description: "Name of the swarm."
  1737. type: "string"
  1738. Labels:
  1739. description: "User-defined key/value metadata."
  1740. type: "object"
  1741. additionalProperties:
  1742. type: "string"
  1743. Orchestration:
  1744. description: "Orchestration configuration."
  1745. type: "object"
  1746. properties:
  1747. TaskHistoryRetentionLimit:
  1748. description: "The number of historic tasks to keep per instance or node. If negative, never remove completed or failed tasks."
  1749. type: "integer"
  1750. format: "int64"
  1751. Raft:
  1752. description: "Raft configuration."
  1753. type: "object"
  1754. properties:
  1755. SnapshotInterval:
  1756. description: "The number of log entries between snapshots."
  1757. type: "integer"
  1758. format: "int64"
  1759. KeepOldSnapshots:
  1760. description: "The number of snapshots to keep beyond the current snapshot."
  1761. type: "integer"
  1762. format: "int64"
  1763. LogEntriesForSlowFollowers:
  1764. description: "The number of log entries to keep around to sync up slow followers after a snapshot is created."
  1765. type: "integer"
  1766. format: "int64"
  1767. ElectionTick:
  1768. description: |
  1769. The number of ticks that a follower will wait for a message from the leader before becoming a candidate and starting an election. `ElectionTick` must be greater than `HeartbeatTick`.
  1770. A tick currently defaults to one second, so these translate directly to seconds currently, but this is NOT guaranteed.
  1771. type: "integer"
  1772. HeartbeatTick:
  1773. description: |
  1774. The number of ticks between heartbeats. Every HeartbeatTick ticks, the leader will send a heartbeat to the followers.
  1775. A tick currently defaults to one second, so these translate directly to seconds currently, but this is NOT guaranteed.
  1776. type: "integer"
  1777. Dispatcher:
  1778. description: "Dispatcher configuration."
  1779. type: "object"
  1780. properties:
  1781. HeartbeatPeriod:
  1782. description: "The delay for an agent to send a heartbeat to the dispatcher."
  1783. type: "integer"
  1784. format: "int64"
  1785. CAConfig:
  1786. description: "CA configuration."
  1787. type: "object"
  1788. properties:
  1789. NodeCertExpiry:
  1790. description: "The duration node certificates are issued for."
  1791. type: "integer"
  1792. format: "int64"
  1793. ExternalCAs:
  1794. description: "Configuration for forwarding signing requests to an external certificate authority."
  1795. type: "array"
  1796. items:
  1797. type: "object"
  1798. properties:
  1799. Protocol:
  1800. description: "Protocol for communication with the external CA (currently only `cfssl` is supported)."
  1801. type: "string"
  1802. enum:
  1803. - "cfssl"
  1804. default: "cfssl"
  1805. URL:
  1806. description: "URL where certificate signing requests should be sent."
  1807. type: "string"
  1808. Options:
  1809. description: "An object with key/value pairs that are interpreted as protocol-specific options for the external CA driver."
  1810. type: "object"
  1811. additionalProperties:
  1812. type: "string"
  1813. EncryptionConfig:
  1814. description: "Parameters related to encryption-at-rest."
  1815. type: "object"
  1816. properties:
  1817. AutoLockManagers:
  1818. description: "If set, generate a key and use it to lock data stored on the managers."
  1819. type: "boolean"
  1820. TaskDefaults:
  1821. description: "Defaults for creating tasks in this cluster."
  1822. type: "object"
  1823. properties:
  1824. LogDriver:
  1825. description: |
  1826. The log driver to use for tasks created in the orchestrator if unspecified by a service.
  1827. Updating this value will only have an affect on new tasks. Old tasks will continue use their previously configured log driver until recreated.
  1828. type: "object"
  1829. properties:
  1830. Name:
  1831. type: "string"
  1832. Options:
  1833. type: "object"
  1834. additionalProperties:
  1835. type: "string"
  1836. example:
  1837. Name: "default"
  1838. Orchestration:
  1839. TaskHistoryRetentionLimit: 10
  1840. Raft:
  1841. SnapshotInterval: 10000
  1842. LogEntriesForSlowFollowers: 500
  1843. HeartbeatTick: 1
  1844. ElectionTick: 3
  1845. Dispatcher:
  1846. HeartbeatPeriod: 5000000000
  1847. CAConfig:
  1848. NodeCertExpiry: 7776000000000000
  1849. JoinTokens:
  1850. Worker: "SWMTKN-1-3pu6hszjas19xyp7ghgosyx9k8atbfcr8p2is99znpy26u2lkl-1awxwuwd3z9j1z3puu7rcgdbx"
  1851. Manager: "SWMTKN-1-3pu6hszjas19xyp7ghgosyx9k8atbfcr8p2is99znpy26u2lkl-7p73s1dx5in4tatdymyhg9hu2"
  1852. EncryptionConfig:
  1853. AutoLockManagers: false
  1854. # The Swarm information for `GET /info`. It is the same as `GET /swarm`, but
  1855. # without `JoinTokens`.
  1856. ClusterInfo:
  1857. type: "object"
  1858. properties:
  1859. ID:
  1860. description: "The ID of the swarm."
  1861. type: "string"
  1862. Version:
  1863. $ref: "#/definitions/ObjectVersion"
  1864. CreatedAt:
  1865. type: "string"
  1866. format: "dateTime"
  1867. UpdatedAt:
  1868. type: "string"
  1869. format: "dateTime"
  1870. Spec:
  1871. $ref: "#/definitions/SwarmSpec"
  1872. TaskSpec:
  1873. description: "User modifiable task configuration."
  1874. type: "object"
  1875. properties:
  1876. ContainerSpec:
  1877. type: "object"
  1878. properties:
  1879. Image:
  1880. description: "The image name to use for the container."
  1881. type: "string"
  1882. Labels:
  1883. description: "User-defined key/value data."
  1884. type: "object"
  1885. additionalProperties:
  1886. type: "string"
  1887. Command:
  1888. description: "The command to be run in the image."
  1889. type: "array"
  1890. items:
  1891. type: "string"
  1892. Args:
  1893. description: "Arguments to the command."
  1894. type: "array"
  1895. items:
  1896. type: "string"
  1897. Hostname:
  1898. description: "The hostname to use for the container, as a valid RFC 1123 hostname."
  1899. type: "string"
  1900. Env:
  1901. description: "A list of environment variables in the form `VAR=value`."
  1902. type: "array"
  1903. items:
  1904. type: "string"
  1905. Dir:
  1906. description: "The working directory for commands to run in."
  1907. type: "string"
  1908. User:
  1909. description: "The user inside the container."
  1910. type: "string"
  1911. Groups:
  1912. type: "array"
  1913. description: "A list of additional groups that the container process will run as."
  1914. items:
  1915. type: "string"
  1916. TTY:
  1917. description: "Whether a pseudo-TTY should be allocated."
  1918. type: "boolean"
  1919. OpenStdin:
  1920. description: "Open `stdin`"
  1921. type: "boolean"
  1922. ReadOnly:
  1923. description: "Mount the container's root filesystem as read only."
  1924. type: "boolean"
  1925. Mounts:
  1926. description: "Specification for mounts to be added to containers created as part of the service."
  1927. type: "array"
  1928. items:
  1929. $ref: "#/definitions/Mount"
  1930. StopSignal:
  1931. description: "Signal to stop the container."
  1932. type: "string"
  1933. StopGracePeriod:
  1934. description: "Amount of time to wait for the container to terminate before forcefully killing it."
  1935. type: "integer"
  1936. format: "int64"
  1937. HealthCheck:
  1938. $ref: "#/definitions/HealthConfig"
  1939. Hosts:
  1940. type: "array"
  1941. description: |
  1942. A list of hostnames/IP mappings to add to the container's `/etc/hosts` file.
  1943. The format of extra hosts on swarmkit is specified in:
  1944. http://man7.org/linux/man-pages/man5/hosts.5.html
  1945. IP_address canonical_hostname [aliases...]
  1946. items:
  1947. type: "string"
  1948. DNSConfig:
  1949. description: "Specification for DNS related configurations in resolver configuration file (`resolv.conf`)."
  1950. type: "object"
  1951. properties:
  1952. Nameservers:
  1953. description: "The IP addresses of the name servers."
  1954. type: "array"
  1955. items:
  1956. type: "string"
  1957. Search:
  1958. description: "A search list for host-name lookup."
  1959. type: "array"
  1960. items:
  1961. type: "string"
  1962. Options:
  1963. description: "A list of internal resolver variables to be modified (e.g., `debug`, `ndots:3`, etc.)."
  1964. type: "array"
  1965. items:
  1966. type: "string"
  1967. Secrets:
  1968. description: "Secrets contains references to zero or more secrets that will be exposed to the service."
  1969. type: "array"
  1970. items:
  1971. type: "object"
  1972. properties:
  1973. File:
  1974. description: "File represents a specific target that is backed by a file."
  1975. type: "object"
  1976. properties:
  1977. Name:
  1978. description: "Name represents the final filename in the filesystem."
  1979. type: "string"
  1980. UID:
  1981. description: "UID represents the file UID."
  1982. type: "string"
  1983. GID:
  1984. description: "GID represents the file GID."
  1985. type: "string"
  1986. Mode:
  1987. description: "Mode represents the FileMode of the file."
  1988. type: "integer"
  1989. format: "uint32"
  1990. SecretID:
  1991. description: "SecretID represents the ID of the specific secret that we're referencing."
  1992. type: "string"
  1993. SecretName:
  1994. description: |
  1995. SecretName is the name of the secret that this references, but this is just provided for
  1996. lookup/display purposes. The secret in the reference will be identified by its ID.
  1997. type: "string"
  1998. Resources:
  1999. description: "Resource requirements which apply to each individual container created as part of the service."
  2000. type: "object"
  2001. properties:
  2002. Limits:
  2003. description: "Define resources limits."
  2004. type: "object"
  2005. properties:
  2006. NanoCPUs:
  2007. description: "CPU limit in units of 10<sup>-9</sup> CPU shares."
  2008. type: "integer"
  2009. format: "int64"
  2010. MemoryBytes:
  2011. description: "Memory limit in Bytes."
  2012. type: "integer"
  2013. format: "int64"
  2014. Reservations:
  2015. description: "Define resources reservation."
  2016. properties:
  2017. NanoCPUs:
  2018. description: "CPU reservation in units of 10<sup>-9</sup> CPU shares."
  2019. type: "integer"
  2020. format: "int64"
  2021. MemoryBytes:
  2022. description: "Memory reservation in Bytes."
  2023. type: "integer"
  2024. format: "int64"
  2025. RestartPolicy:
  2026. description: "Specification for the restart policy which applies to containers created as part of this service."
  2027. type: "object"
  2028. properties:
  2029. Condition:
  2030. description: "Condition for restart."
  2031. type: "string"
  2032. enum:
  2033. - "none"
  2034. - "on-failure"
  2035. - "any"
  2036. Delay:
  2037. description: "Delay between restart attempts."
  2038. type: "integer"
  2039. format: "int64"
  2040. MaxAttempts:
  2041. description: "Maximum attempts to restart a given container before giving up (default value is 0, which is ignored)."
  2042. type: "integer"
  2043. format: "int64"
  2044. default: 0
  2045. Window:
  2046. description: "Windows is the time window used to evaluate the restart policy (default value is 0, which is unbounded)."
  2047. type: "integer"
  2048. format: "int64"
  2049. default: 0
  2050. Placement:
  2051. type: "object"
  2052. properties:
  2053. Constraints:
  2054. description: "An array of constraints."
  2055. type: "array"
  2056. items:
  2057. type: "string"
  2058. Preferences:
  2059. description: "Preferences provide a way to make the scheduler aware of factors such as topology. They are provided in order from highest to lowest precedence."
  2060. type: "array"
  2061. items:
  2062. type: "object"
  2063. properties:
  2064. Spread:
  2065. type: "object"
  2066. properties:
  2067. SpreadDescriptor:
  2068. description: "label descriptor, such as engine.labels.az"
  2069. type: "string"
  2070. ForceUpdate:
  2071. description: "A counter that triggers an update even if no relevant parameters have been changed."
  2072. type: "integer"
  2073. Networks:
  2074. type: "array"
  2075. items:
  2076. type: "object"
  2077. properties:
  2078. Target:
  2079. type: "string"
  2080. Aliases:
  2081. type: "array"
  2082. items:
  2083. type: "string"
  2084. LogDriver:
  2085. description: "Specifies the log driver to use for tasks created from this spec. If not present, the default one for the swarm will be used, finally falling back to the engine default if not specified."
  2086. type: "object"
  2087. properties:
  2088. Name:
  2089. type: "string"
  2090. Options:
  2091. type: "object"
  2092. additionalProperties:
  2093. type: "string"
  2094. TaskState:
  2095. type: "string"
  2096. enum:
  2097. - "new"
  2098. - "allocated"
  2099. - "pending"
  2100. - "assigned"
  2101. - "accepted"
  2102. - "preparing"
  2103. - "ready"
  2104. - "starting"
  2105. - "running"
  2106. - "complete"
  2107. - "shutdown"
  2108. - "failed"
  2109. - "rejected"
  2110. Task:
  2111. type: "object"
  2112. properties:
  2113. ID:
  2114. description: "The ID of the task."
  2115. type: "string"
  2116. Version:
  2117. $ref: "#/definitions/ObjectVersion"
  2118. CreatedAt:
  2119. type: "string"
  2120. format: "dateTime"
  2121. UpdatedAt:
  2122. type: "string"
  2123. format: "dateTime"
  2124. Name:
  2125. description: "Name of the task."
  2126. type: "string"
  2127. Labels:
  2128. description: "User-defined key/value metadata."
  2129. type: "object"
  2130. additionalProperties:
  2131. type: "string"
  2132. Spec:
  2133. $ref: "#/definitions/TaskSpec"
  2134. ServiceID:
  2135. description: "The ID of the service this task is part of."
  2136. type: "string"
  2137. Slot:
  2138. type: "integer"
  2139. NodeID:
  2140. description: "The ID of the node that this task is on."
  2141. type: "string"
  2142. Status:
  2143. type: "object"
  2144. properties:
  2145. Timestamp:
  2146. type: "string"
  2147. format: "dateTime"
  2148. State:
  2149. $ref: "#/definitions/TaskState"
  2150. Message:
  2151. type: "string"
  2152. Err:
  2153. type: "string"
  2154. ContainerStatus:
  2155. type: "object"
  2156. properties:
  2157. ContainerID:
  2158. type: "string"
  2159. PID:
  2160. type: "integer"
  2161. ExitCode:
  2162. type: "integer"
  2163. DesiredState:
  2164. $ref: "#/definitions/TaskState"
  2165. example:
  2166. ID: "0kzzo1i0y4jz6027t0k7aezc7"
  2167. Version:
  2168. Index: 71
  2169. CreatedAt: "2016-06-07T21:07:31.171892745Z"
  2170. UpdatedAt: "2016-06-07T21:07:31.376370513Z"
  2171. Spec:
  2172. ContainerSpec:
  2173. Image: "redis"
  2174. Resources:
  2175. Limits: {}
  2176. Reservations: {}
  2177. RestartPolicy:
  2178. Condition: "any"
  2179. MaxAttempts: 0
  2180. Placement: {}
  2181. ServiceID: "9mnpnzenvg8p8tdbtq4wvbkcz"
  2182. Slot: 1
  2183. NodeID: "60gvrl6tm78dmak4yl7srz94v"
  2184. Status:
  2185. Timestamp: "2016-06-07T21:07:31.290032978Z"
  2186. State: "running"
  2187. Message: "started"
  2188. ContainerStatus:
  2189. ContainerID: "e5d62702a1b48d01c3e02ca1e0212a250801fa8d67caca0b6f35919ebc12f035"
  2190. PID: 677
  2191. DesiredState: "running"
  2192. NetworksAttachments:
  2193. - Network:
  2194. ID: "4qvuz4ko70xaltuqbt8956gd1"
  2195. Version:
  2196. Index: 18
  2197. CreatedAt: "2016-06-07T20:31:11.912919752Z"
  2198. UpdatedAt: "2016-06-07T21:07:29.955277358Z"
  2199. Spec:
  2200. Name: "ingress"
  2201. Labels:
  2202. com.docker.swarm.internal: "true"
  2203. DriverConfiguration: {}
  2204. IPAMOptions:
  2205. Driver: {}
  2206. Configs:
  2207. - Subnet: "10.255.0.0/16"
  2208. Gateway: "10.255.0.1"
  2209. DriverState:
  2210. Name: "overlay"
  2211. Options:
  2212. com.docker.network.driver.overlay.vxlanid_list: "256"
  2213. IPAMOptions:
  2214. Driver:
  2215. Name: "default"
  2216. Configs:
  2217. - Subnet: "10.255.0.0/16"
  2218. Gateway: "10.255.0.1"
  2219. Addresses:
  2220. - "10.255.0.10/16"
  2221. ServiceSpec:
  2222. description: "User modifiable configuration for a service."
  2223. type: object
  2224. properties:
  2225. Name:
  2226. description: "Name of the service."
  2227. type: "string"
  2228. Labels:
  2229. description: "User-defined key/value metadata."
  2230. type: "object"
  2231. additionalProperties:
  2232. type: "string"
  2233. TaskTemplate:
  2234. $ref: "#/definitions/TaskSpec"
  2235. Mode:
  2236. description: "Scheduling mode for the service."
  2237. type: "object"
  2238. properties:
  2239. Replicated:
  2240. type: "object"
  2241. properties:
  2242. Replicas:
  2243. type: "integer"
  2244. format: "int64"
  2245. Global:
  2246. type: "object"
  2247. UpdateConfig:
  2248. description: "Specification for the update strategy of the service."
  2249. type: "object"
  2250. properties:
  2251. Parallelism:
  2252. description: "Maximum number of tasks to be updated in one iteration (0 means unlimited parallelism)."
  2253. type: "integer"
  2254. format: "int64"
  2255. Delay:
  2256. description: "Amount of time between updates, in nanoseconds."
  2257. type: "integer"
  2258. format: "int64"
  2259. FailureAction:
  2260. description: "Action to take if an updated task fails to run, or stops running during the update."
  2261. type: "string"
  2262. enum:
  2263. - "continue"
  2264. - "pause"
  2265. - "rollback"
  2266. Monitor:
  2267. description: "Amount of time to monitor each updated task for failures, in nanoseconds."
  2268. type: "integer"
  2269. format: "int64"
  2270. MaxFailureRatio:
  2271. description: "The fraction of tasks that may fail during an update before the failure action is invoked, specified as a floating point number between 0 and 1."
  2272. type: "number"
  2273. default: 0
  2274. Order:
  2275. description: "The order of operations when rolling out an updated task. Either the old task is shut down before the new task is started, or the new task is started before the old task is shut down."
  2276. type: "string"
  2277. enum:
  2278. - "stop-first"
  2279. - "start-first"
  2280. RollbackConfig:
  2281. description: "Specification for the rollback strategy of the service."
  2282. type: "object"
  2283. properties:
  2284. Parallelism:
  2285. description: "Maximum number of tasks to be rolled back in one iteration (0 means unlimited parallelism)."
  2286. type: "integer"
  2287. format: "int64"
  2288. Delay:
  2289. description: "Amount of time between rollback iterations, in nanoseconds."
  2290. type: "integer"
  2291. format: "int64"
  2292. FailureAction:
  2293. description: "Action to take if an rolled back task fails to run, or stops running during the rollback."
  2294. type: "string"
  2295. enum:
  2296. - "continue"
  2297. - "pause"
  2298. Monitor:
  2299. description: "Amount of time to monitor each rolled back task for failures, in nanoseconds."
  2300. type: "integer"
  2301. format: "int64"
  2302. MaxFailureRatio:
  2303. description: "The fraction of tasks that may fail during a rollback before the failure action is invoked, specified as a floating point number between 0 and 1."
  2304. type: "number"
  2305. default: 0
  2306. Order:
  2307. description: "The order of operations when rolling back a task. Either the old task is shut down before the new task is started, or the new task is started before the old task is shut down."
  2308. type: "string"
  2309. enum:
  2310. - "stop-first"
  2311. - "start-first"
  2312. Networks:
  2313. description: "Array of network names or IDs to attach the service to."
  2314. type: "array"
  2315. items:
  2316. type: "object"
  2317. properties:
  2318. Target:
  2319. type: "string"
  2320. Aliases:
  2321. type: "array"
  2322. items:
  2323. type: "string"
  2324. EndpointSpec:
  2325. $ref: "#/definitions/EndpointSpec"
  2326. EndpointPortConfig:
  2327. type: "object"
  2328. properties:
  2329. Name:
  2330. type: "string"
  2331. Protocol:
  2332. type: "string"
  2333. enum:
  2334. - "tcp"
  2335. - "udp"
  2336. TargetPort:
  2337. description: "The port inside the container."
  2338. type: "integer"
  2339. PublishedPort:
  2340. description: "The port on the swarm hosts."
  2341. type: "integer"
  2342. EndpointSpec:
  2343. description: "Properties that can be configured to access and load balance a service."
  2344. type: "object"
  2345. properties:
  2346. Mode:
  2347. description: "The mode of resolution to use for internal load balancing
  2348. between tasks."
  2349. type: "string"
  2350. enum:
  2351. - "vip"
  2352. - "dnsrr"
  2353. default: "vip"
  2354. Ports:
  2355. description: "List of exposed ports that this service is accessible on from the outside. Ports can only be provided if `vip` resolution mode is used."
  2356. type: "array"
  2357. items:
  2358. $ref: "#/definitions/EndpointPortConfig"
  2359. Service:
  2360. type: "object"
  2361. properties:
  2362. ID:
  2363. type: "string"
  2364. Version:
  2365. $ref: "#/definitions/ObjectVersion"
  2366. CreatedAt:
  2367. type: "string"
  2368. format: "dateTime"
  2369. UpdatedAt:
  2370. type: "string"
  2371. format: "dateTime"
  2372. Spec:
  2373. $ref: "#/definitions/ServiceSpec"
  2374. Endpoint:
  2375. type: "object"
  2376. properties:
  2377. Spec:
  2378. $ref: "#/definitions/EndpointSpec"
  2379. Ports:
  2380. type: "array"
  2381. items:
  2382. $ref: "#/definitions/EndpointPortConfig"
  2383. VirtualIPs:
  2384. type: "array"
  2385. items:
  2386. type: "object"
  2387. properties:
  2388. NetworkID:
  2389. type: "string"
  2390. Addr:
  2391. type: "string"
  2392. UpdateStatus:
  2393. description: "The status of a service update."
  2394. type: "object"
  2395. properties:
  2396. State:
  2397. type: "string"
  2398. enum:
  2399. - "updating"
  2400. - "paused"
  2401. - "completed"
  2402. StartedAt:
  2403. type: "string"
  2404. format: "dateTime"
  2405. CompletedAt:
  2406. type: "string"
  2407. format: "dateTime"
  2408. Message:
  2409. type: "string"
  2410. example:
  2411. ID: "9mnpnzenvg8p8tdbtq4wvbkcz"
  2412. Version:
  2413. Index: 19
  2414. CreatedAt: "2016-06-07T21:05:51.880065305Z"
  2415. UpdatedAt: "2016-06-07T21:07:29.962229872Z"
  2416. Spec:
  2417. Name: "hopeful_cori"
  2418. TaskTemplate:
  2419. ContainerSpec:
  2420. Image: "redis"
  2421. Resources:
  2422. Limits: {}
  2423. Reservations: {}
  2424. RestartPolicy:
  2425. Condition: "any"
  2426. MaxAttempts: 0
  2427. Placement: {}
  2428. ForceUpdate: 0
  2429. Mode:
  2430. Replicated:
  2431. Replicas: 1
  2432. UpdateConfig:
  2433. Parallelism: 1
  2434. Delay: 1000000000
  2435. FailureAction: "pause"
  2436. Monitor: 15000000000
  2437. MaxFailureRatio: 0.15
  2438. RollbackConfig:
  2439. Parallelism: 1
  2440. Delay: 1000000000
  2441. FailureAction: "pause"
  2442. Monitor: 15000000000
  2443. MaxFailureRatio: 0.15
  2444. EndpointSpec:
  2445. Mode: "vip"
  2446. Ports:
  2447. -
  2448. Protocol: "tcp"
  2449. TargetPort: 6379
  2450. PublishedPort: 30001
  2451. Endpoint:
  2452. Spec:
  2453. Mode: "vip"
  2454. Ports:
  2455. -
  2456. Protocol: "tcp"
  2457. TargetPort: 6379
  2458. PublishedPort: 30001
  2459. Ports:
  2460. -
  2461. Protocol: "tcp"
  2462. TargetPort: 6379
  2463. PublishedPort: 30001
  2464. VirtualIPs:
  2465. -
  2466. NetworkID: "4qvuz4ko70xaltuqbt8956gd1"
  2467. Addr: "10.255.0.2/16"
  2468. -
  2469. NetworkID: "4qvuz4ko70xaltuqbt8956gd1"
  2470. Addr: "10.255.0.3/16"
  2471. ImageDeleteResponseItem:
  2472. type: "object"
  2473. properties:
  2474. Untagged:
  2475. description: "The image ID of an image that was untagged"
  2476. type: "string"
  2477. Deleted:
  2478. description: "The image ID of an image that was deleted"
  2479. type: "string"
  2480. ServiceUpdateResponse:
  2481. type: "object"
  2482. properties:
  2483. Warnings:
  2484. description: "Optional warning messages"
  2485. type: "array"
  2486. items:
  2487. type: "string"
  2488. example:
  2489. Warning: "unable to pin image doesnotexist:latest to digest: image library/doesnotexist:latest not found"
  2490. ContainerSummary:
  2491. type: "array"
  2492. items:
  2493. type: "object"
  2494. properties:
  2495. Id:
  2496. description: "The ID of this container"
  2497. type: "string"
  2498. x-go-name: "ID"
  2499. Names:
  2500. description: "The names that this container has been given"
  2501. type: "array"
  2502. items:
  2503. type: "string"
  2504. Image:
  2505. description: "The name of the image used when creating this container"
  2506. type: "string"
  2507. ImageID:
  2508. description: "The ID of the image that this container was created from"
  2509. type: "string"
  2510. Command:
  2511. description: "Command to run when starting the container"
  2512. type: "string"
  2513. Created:
  2514. description: "When the container was created"
  2515. type: "integer"
  2516. format: "int64"
  2517. Ports:
  2518. description: "The ports exposed by this container"
  2519. type: "array"
  2520. items:
  2521. $ref: "#/definitions/Port"
  2522. SizeRw:
  2523. description: "The size of files that have been created or changed by this container"
  2524. type: "integer"
  2525. format: "int64"
  2526. SizeRootFs:
  2527. description: "The total size of all the files in this container"
  2528. type: "integer"
  2529. format: "int64"
  2530. Labels:
  2531. description: "User-defined key/value metadata."
  2532. type: "object"
  2533. additionalProperties:
  2534. type: "string"
  2535. State:
  2536. description: "The state of this container (e.g. `Exited`)"
  2537. type: "string"
  2538. Status:
  2539. description: "Additional human-readable status of this container (e.g. `Exit 0`)"
  2540. type: "string"
  2541. HostConfig:
  2542. type: "object"
  2543. properties:
  2544. NetworkMode:
  2545. type: "string"
  2546. NetworkSettings:
  2547. description: "A summary of the container's network settings"
  2548. type: "object"
  2549. properties:
  2550. Networks:
  2551. type: "object"
  2552. additionalProperties:
  2553. $ref: "#/definitions/EndpointSettings"
  2554. Mounts:
  2555. type: "array"
  2556. items:
  2557. $ref: "#/definitions/MountPoint"
  2558. SecretSpec:
  2559. type: "object"
  2560. properties:
  2561. Name:
  2562. description: "User-defined name of the secret."
  2563. type: "string"
  2564. Labels:
  2565. description: "User-defined key/value metadata."
  2566. type: "object"
  2567. additionalProperties:
  2568. type: "string"
  2569. Data:
  2570. description: "Base64-url-safe-encoded secret data"
  2571. type: "array"
  2572. items:
  2573. type: "string"
  2574. Secret:
  2575. type: "object"
  2576. properties:
  2577. ID:
  2578. type: "string"
  2579. Version:
  2580. $ref: "#/definitions/ObjectVersion"
  2581. CreatedAt:
  2582. type: "string"
  2583. format: "dateTime"
  2584. UpdatedAt:
  2585. type: "string"
  2586. format: "dateTime"
  2587. Spec:
  2588. $ref: "#/definitions/ServiceSpec"
  2589. paths:
  2590. /containers/json:
  2591. get:
  2592. summary: "List containers"
  2593. operationId: "ContainerList"
  2594. produces:
  2595. - "application/json"
  2596. parameters:
  2597. - name: "all"
  2598. in: "query"
  2599. description: "Return all containers. By default, only running containers are shown"
  2600. type: "boolean"
  2601. default: false
  2602. - name: "limit"
  2603. in: "query"
  2604. description: "Return this number of most recently created containers, including non-running ones."
  2605. type: "integer"
  2606. - name: "size"
  2607. in: "query"
  2608. description: "Return the size of container as fields `SizeRw` and `SizeRootFs`."
  2609. type: "boolean"
  2610. default: false
  2611. - name: "filters"
  2612. in: "query"
  2613. description: |
  2614. Filters to process on the container list, encoded as JSON (a `map[string][]string`). For example, `{"status": ["paused"]}` will only return paused containers. Available filters:
  2615. - `ancestor`=(`<image-name>[:<tag>]`, `<image id>`, or `<image@digest>`)
  2616. - `before`=(`<container id>` or `<container name>`)
  2617. - `expose`=(`<port>[/<proto>]`|`<startport-endport>/[<proto>]`)
  2618. - `exited=<int>` containers with exit code of `<int>`
  2619. - `health`=(`starting`|`healthy`|`unhealthy`|`none`)
  2620. - `id=<ID>` a container's ID
  2621. - `isolation=`(`default`|`process`|`hyperv`) (Windows daemon only)
  2622. - `is-task=`(`true`|`false`)
  2623. - `label=key` or `label="key=value"` of a container label
  2624. - `name=<name>` a container's name
  2625. - `network`=(`<network id>` or `<network name>`)
  2626. - `publish`=(`<port>[/<proto>]`|`<startport-endport>/[<proto>]`)
  2627. - `since`=(`<container id>` or `<container name>`)
  2628. - `status=`(`created`|`restarting`|`running`|`removing`|`paused`|`exited`|`dead`)
  2629. - `volume`=(`<volume name>` or `<mount point destination>`)
  2630. type: "string"
  2631. responses:
  2632. 200:
  2633. description: "no error"
  2634. schema:
  2635. $ref: "#/definitions/ContainerSummary"
  2636. examples:
  2637. application/json:
  2638. - Id: "8dfafdbc3a40"
  2639. Names:
  2640. - "/boring_feynman"
  2641. Image: "ubuntu:latest"
  2642. ImageID: "d74508fb6632491cea586a1fd7d748dfc5274cd6fdfedee309ecdcbc2bf5cb82"
  2643. Command: "echo 1"
  2644. Created: 1367854155
  2645. State: "Exited"
  2646. Status: "Exit 0"
  2647. Ports:
  2648. - PrivatePort: 2222
  2649. PublicPort: 3333
  2650. Type: "tcp"
  2651. Labels:
  2652. com.example.vendor: "Acme"
  2653. com.example.license: "GPL"
  2654. com.example.version: "1.0"
  2655. SizeRw: 12288
  2656. SizeRootFs: 0
  2657. HostConfig:
  2658. NetworkMode: "default"
  2659. NetworkSettings:
  2660. Networks:
  2661. bridge:
  2662. NetworkID: "7ea29fc1412292a2d7bba362f9253545fecdfa8ce9a6e37dd10ba8bee7129812"
  2663. EndpointID: "2cdc4edb1ded3631c81f57966563e5c8525b81121bb3706a9a9a3ae102711f3f"
  2664. Gateway: "172.17.0.1"
  2665. IPAddress: "172.17.0.2"
  2666. IPPrefixLen: 16
  2667. IPv6Gateway: ""
  2668. GlobalIPv6Address: ""
  2669. GlobalIPv6PrefixLen: 0
  2670. MacAddress: "02:42:ac:11:00:02"
  2671. Mounts:
  2672. - Name: "fac362...80535"
  2673. Source: "/data"
  2674. Destination: "/data"
  2675. Driver: "local"
  2676. Mode: "ro,Z"
  2677. RW: false
  2678. Propagation: ""
  2679. - Id: "9cd87474be90"
  2680. Names:
  2681. - "/coolName"
  2682. Image: "ubuntu:latest"
  2683. ImageID: "d74508fb6632491cea586a1fd7d748dfc5274cd6fdfedee309ecdcbc2bf5cb82"
  2684. Command: "echo 222222"
  2685. Created: 1367854155
  2686. State: "Exited"
  2687. Status: "Exit 0"
  2688. Ports: []
  2689. Labels: {}
  2690. SizeRw: 12288
  2691. SizeRootFs: 0
  2692. HostConfig:
  2693. NetworkMode: "default"
  2694. NetworkSettings:
  2695. Networks:
  2696. bridge:
  2697. NetworkID: "7ea29fc1412292a2d7bba362f9253545fecdfa8ce9a6e37dd10ba8bee7129812"
  2698. EndpointID: "88eaed7b37b38c2a3f0c4bc796494fdf51b270c2d22656412a2ca5d559a64d7a"
  2699. Gateway: "172.17.0.1"
  2700. IPAddress: "172.17.0.8"
  2701. IPPrefixLen: 16
  2702. IPv6Gateway: ""
  2703. GlobalIPv6Address: ""
  2704. GlobalIPv6PrefixLen: 0
  2705. MacAddress: "02:42:ac:11:00:08"
  2706. Mounts: []
  2707. - Id: "3176a2479c92"
  2708. Names:
  2709. - "/sleepy_dog"
  2710. Image: "ubuntu:latest"
  2711. ImageID: "d74508fb6632491cea586a1fd7d748dfc5274cd6fdfedee309ecdcbc2bf5cb82"
  2712. Command: "echo 3333333333333333"
  2713. Created: 1367854154
  2714. State: "Exited"
  2715. Status: "Exit 0"
  2716. Ports: []
  2717. Labels: {}
  2718. SizeRw: 12288
  2719. SizeRootFs: 0
  2720. HostConfig:
  2721. NetworkMode: "default"
  2722. NetworkSettings:
  2723. Networks:
  2724. bridge:
  2725. NetworkID: "7ea29fc1412292a2d7bba362f9253545fecdfa8ce9a6e37dd10ba8bee7129812"
  2726. EndpointID: "8b27c041c30326d59cd6e6f510d4f8d1d570a228466f956edf7815508f78e30d"
  2727. Gateway: "172.17.0.1"
  2728. IPAddress: "172.17.0.6"
  2729. IPPrefixLen: 16
  2730. IPv6Gateway: ""
  2731. GlobalIPv6Address: ""
  2732. GlobalIPv6PrefixLen: 0
  2733. MacAddress: "02:42:ac:11:00:06"
  2734. Mounts: []
  2735. - Id: "4cb07b47f9fb"
  2736. Names:
  2737. - "/running_cat"
  2738. Image: "ubuntu:latest"
  2739. ImageID: "d74508fb6632491cea586a1fd7d748dfc5274cd6fdfedee309ecdcbc2bf5cb82"
  2740. Command: "echo 444444444444444444444444444444444"
  2741. Created: 1367854152
  2742. State: "Exited"
  2743. Status: "Exit 0"
  2744. Ports: []
  2745. Labels: {}
  2746. SizeRw: 12288
  2747. SizeRootFs: 0
  2748. HostConfig:
  2749. NetworkMode: "default"
  2750. NetworkSettings:
  2751. Networks:
  2752. bridge:
  2753. NetworkID: "7ea29fc1412292a2d7bba362f9253545fecdfa8ce9a6e37dd10ba8bee7129812"
  2754. EndpointID: "d91c7b2f0644403d7ef3095985ea0e2370325cd2332ff3a3225c4247328e66e9"
  2755. Gateway: "172.17.0.1"
  2756. IPAddress: "172.17.0.5"
  2757. IPPrefixLen: 16
  2758. IPv6Gateway: ""
  2759. GlobalIPv6Address: ""
  2760. GlobalIPv6PrefixLen: 0
  2761. MacAddress: "02:42:ac:11:00:05"
  2762. Mounts: []
  2763. 400:
  2764. description: "bad parameter"
  2765. schema:
  2766. $ref: "#/definitions/ErrorResponse"
  2767. 500:
  2768. description: "server error"
  2769. schema:
  2770. $ref: "#/definitions/ErrorResponse"
  2771. tags: ["Container"]
  2772. /containers/create:
  2773. post:
  2774. summary: "Create a container"
  2775. operationId: "ContainerCreate"
  2776. consumes:
  2777. - "application/json"
  2778. - "application/octet-stream"
  2779. produces:
  2780. - "application/json"
  2781. parameters:
  2782. - name: "name"
  2783. in: "query"
  2784. description: "Assign the specified name to the container. Must match `/?[a-zA-Z0-9_-]+`."
  2785. type: "string"
  2786. pattern: "/?[a-zA-Z0-9_-]+"
  2787. - name: "body"
  2788. in: "body"
  2789. description: "Container to create"
  2790. schema:
  2791. allOf:
  2792. - $ref: "#/definitions/Config"
  2793. - type: "object"
  2794. properties:
  2795. HostConfig:
  2796. $ref: "#/definitions/HostConfig"
  2797. NetworkingConfig:
  2798. description: "This container's networking configuration."
  2799. type: "object"
  2800. properties:
  2801. EndpointsConfig:
  2802. description: "A mapping of network name to endpoint configuration for that network."
  2803. type: "object"
  2804. additionalProperties:
  2805. $ref: "#/definitions/EndpointSettings"
  2806. example:
  2807. Hostname: ""
  2808. Domainname: ""
  2809. User: ""
  2810. AttachStdin: false
  2811. AttachStdout: true
  2812. AttachStderr: true
  2813. Tty: false
  2814. OpenStdin: false
  2815. StdinOnce: false
  2816. Env:
  2817. - "FOO=bar"
  2818. - "BAZ=quux"
  2819. Cmd:
  2820. - "date"
  2821. Entrypoint: ""
  2822. Image: "ubuntu"
  2823. Labels:
  2824. com.example.vendor: "Acme"
  2825. com.example.license: "GPL"
  2826. com.example.version: "1.0"
  2827. Volumes:
  2828. /volumes/data: {}
  2829. WorkingDir: ""
  2830. NetworkDisabled: false
  2831. MacAddress: "12:34:56:78:9a:bc"
  2832. ExposedPorts:
  2833. 22/tcp: {}
  2834. StopSignal: "SIGTERM"
  2835. StopTimeout: 10
  2836. HostConfig:
  2837. Binds:
  2838. - "/tmp:/tmp"
  2839. Links:
  2840. - "redis3:redis"
  2841. Memory: 0
  2842. MemorySwap: 0
  2843. MemoryReservation: 0
  2844. KernelMemory: 0
  2845. NanoCpus: 500000
  2846. CpuPercent: 80
  2847. CpuShares: 512
  2848. CpuPeriod: 100000
  2849. CpuRealtimePeriod: 1000000
  2850. CpuRealtimeRuntime: 10000
  2851. CpuQuota: 50000
  2852. CpusetCpus: "0,1"
  2853. CpusetMems: "0,1"
  2854. MaximumIOps: 0
  2855. MaximumIOBps: 0
  2856. BlkioWeight: 300
  2857. BlkioWeightDevice:
  2858. - {}
  2859. BlkioDeviceReadBps:
  2860. - {}
  2861. BlkioDeviceReadIOps:
  2862. - {}
  2863. BlkioDeviceWriteBps:
  2864. - {}
  2865. BlkioDeviceWriteIOps:
  2866. - {}
  2867. MemorySwappiness: 60
  2868. OomKillDisable: false
  2869. OomScoreAdj: 500
  2870. PidMode: ""
  2871. PidsLimit: -1
  2872. PortBindings:
  2873. 22/tcp:
  2874. - HostPort: "11022"
  2875. PublishAllPorts: false
  2876. Privileged: false
  2877. ReadonlyRootfs: false
  2878. Dns:
  2879. - "8.8.8.8"
  2880. DnsOptions:
  2881. - ""
  2882. DnsSearch:
  2883. - ""
  2884. VolumesFrom:
  2885. - "parent"
  2886. - "other:ro"
  2887. CapAdd:
  2888. - "NET_ADMIN"
  2889. CapDrop:
  2890. - "MKNOD"
  2891. GroupAdd:
  2892. - "newgroup"
  2893. RestartPolicy:
  2894. Name: ""
  2895. MaximumRetryCount: 0
  2896. AutoRemove: true
  2897. NetworkMode: "bridge"
  2898. Devices: []
  2899. Ulimits:
  2900. - {}
  2901. LogConfig:
  2902. Type: "json-file"
  2903. Config: {}
  2904. SecurityOpt: []
  2905. StorageOpt: {}
  2906. CgroupParent: ""
  2907. VolumeDriver: ""
  2908. ShmSize: 67108864
  2909. NetworkingConfig:
  2910. EndpointsConfig:
  2911. isolated_nw:
  2912. IPAMConfig:
  2913. IPv4Address: "172.20.30.33"
  2914. IPv6Address: "2001:db8:abcd::3033"
  2915. LinkLocalIPs:
  2916. - "169.254.34.68"
  2917. - "fe80::3468"
  2918. Links:
  2919. - "container_1"
  2920. - "container_2"
  2921. Aliases:
  2922. - "server_x"
  2923. - "server_y"
  2924. required: true
  2925. responses:
  2926. 201:
  2927. description: "Container created successfully"
  2928. schema:
  2929. type: "object"
  2930. required: [Id, Warnings]
  2931. properties:
  2932. Id:
  2933. description: "The ID of the created container"
  2934. type: "string"
  2935. x-nullable: false
  2936. Warnings:
  2937. description: "Warnings encountered when creating the container"
  2938. type: "array"
  2939. x-nullable: false
  2940. items:
  2941. type: "string"
  2942. examples:
  2943. application/json:
  2944. Id: "e90e34656806"
  2945. Warnings: []
  2946. 400:
  2947. description: "bad parameter"
  2948. schema:
  2949. $ref: "#/definitions/ErrorResponse"
  2950. 404:
  2951. description: "no such image"
  2952. schema:
  2953. $ref: "#/definitions/ErrorResponse"
  2954. examples:
  2955. application/json:
  2956. message: "No such image: c2ada9df5af8"
  2957. 406:
  2958. description: "impossible to attach"
  2959. schema:
  2960. $ref: "#/definitions/ErrorResponse"
  2961. 409:
  2962. description: "conflict"
  2963. schema:
  2964. $ref: "#/definitions/ErrorResponse"
  2965. 500:
  2966. description: "server error"
  2967. schema:
  2968. $ref: "#/definitions/ErrorResponse"
  2969. tags: ["Container"]
  2970. /containers/{id}/json:
  2971. get:
  2972. summary: "Inspect a container"
  2973. description: "Return low-level information about a container."
  2974. operationId: "ContainerInspect"
  2975. produces:
  2976. - "application/json"
  2977. responses:
  2978. 200:
  2979. description: "no error"
  2980. schema:
  2981. type: "object"
  2982. properties:
  2983. Id:
  2984. description: "The ID of the container"
  2985. type: "string"
  2986. Created:
  2987. description: "The time the container was created"
  2988. type: "string"
  2989. Path:
  2990. description: "The path to the command being run"
  2991. type: "string"
  2992. Args:
  2993. description: "The arguments to the command being run"
  2994. type: "array"
  2995. items:
  2996. type: "string"
  2997. State:
  2998. description: "The state of the container."
  2999. type: "object"
  3000. properties:
  3001. Status:
  3002. description: "The status of the container. For example, `running` or `exited`."
  3003. type: "string"
  3004. Running:
  3005. description: "Whether this container is running."
  3006. type: "boolean"
  3007. Paused:
  3008. description: "Whether this container is paused."
  3009. type: "boolean"
  3010. Restarting:
  3011. description: "Whether this container is restarting."
  3012. type: "boolean"
  3013. OOMKilled:
  3014. description: "Whether this container has been killed because it ran out of memory."
  3015. type: "boolean"
  3016. Dead:
  3017. type: "boolean"
  3018. Pid:
  3019. description: "The process ID of this container"
  3020. type: "integer"
  3021. ExitCode:
  3022. description: "The last exit code of this container"
  3023. type: "integer"
  3024. Error:
  3025. type: "string"
  3026. StartedAt:
  3027. description: "The time when this container was last started."
  3028. type: "string"
  3029. FinishedAt:
  3030. description: "The time when this container last exited."
  3031. type: "string"
  3032. Image:
  3033. description: "The container's image"
  3034. type: "string"
  3035. ResolvConfPath:
  3036. type: "string"
  3037. HostnamePath:
  3038. type: "string"
  3039. HostsPath:
  3040. type: "string"
  3041. LogPath:
  3042. type: "string"
  3043. Node:
  3044. description: "TODO"
  3045. type: "object"
  3046. Name:
  3047. type: "string"
  3048. RestartCount:
  3049. type: "integer"
  3050. Driver:
  3051. type: "string"
  3052. MountLabel:
  3053. type: "string"
  3054. ProcessLabel:
  3055. type: "string"
  3056. AppArmorProfile:
  3057. type: "string"
  3058. ExecIDs:
  3059. type: "string"
  3060. HostConfig:
  3061. $ref: "#/definitions/HostConfig"
  3062. GraphDriver:
  3063. $ref: "#/definitions/GraphDriverData"
  3064. SizeRw:
  3065. description: "The size of files that have been created or changed by this container."
  3066. type: "integer"
  3067. format: "int64"
  3068. SizeRootFs:
  3069. description: "The total size of all the files in this container."
  3070. type: "integer"
  3071. format: "int64"
  3072. Mounts:
  3073. type: "array"
  3074. items:
  3075. $ref: "#/definitions/MountPoint"
  3076. Config:
  3077. $ref: "#/definitions/Config"
  3078. NetworkSettings:
  3079. $ref: "#/definitions/NetworkConfig"
  3080. examples:
  3081. application/json:
  3082. AppArmorProfile: ""
  3083. Args:
  3084. - "-c"
  3085. - "exit 9"
  3086. Config:
  3087. AttachStderr: true
  3088. AttachStdin: false
  3089. AttachStdout: true
  3090. Cmd:
  3091. - "/bin/sh"
  3092. - "-c"
  3093. - "exit 9"
  3094. Domainname: ""
  3095. Env:
  3096. - "PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
  3097. Hostname: "ba033ac44011"
  3098. Image: "ubuntu"
  3099. Labels:
  3100. com.example.vendor: "Acme"
  3101. com.example.license: "GPL"
  3102. com.example.version: "1.0"
  3103. MacAddress: ""
  3104. NetworkDisabled: false
  3105. OpenStdin: false
  3106. StdinOnce: false
  3107. Tty: false
  3108. User: ""
  3109. Volumes:
  3110. /volumes/data: {}
  3111. WorkingDir: ""
  3112. StopSignal: "SIGTERM"
  3113. StopTimeout: 10
  3114. Created: "2015-01-06T15:47:31.485331387Z"
  3115. Driver: "overlay2"
  3116. HostConfig:
  3117. MaximumIOps: 0
  3118. MaximumIOBps: 0
  3119. BlkioWeight: 0
  3120. BlkioWeightDevice:
  3121. - {}
  3122. BlkioDeviceReadBps:
  3123. - {}
  3124. BlkioDeviceWriteBps:
  3125. - {}
  3126. BlkioDeviceReadIOps:
  3127. - {}
  3128. BlkioDeviceWriteIOps:
  3129. - {}
  3130. ContainerIDFile: ""
  3131. CpusetCpus: ""
  3132. CpusetMems: ""
  3133. CpuPercent: 80
  3134. CpuShares: 0
  3135. CpuPeriod: 100000
  3136. CpuRealtimePeriod: 1000000
  3137. CpuRealtimeRuntime: 10000
  3138. Devices: []
  3139. IpcMode: ""
  3140. Memory: 0
  3141. MemorySwap: 0
  3142. MemoryReservation: 0
  3143. KernelMemory: 0
  3144. OomKillDisable: false
  3145. OomScoreAdj: 500
  3146. NetworkMode: "bridge"
  3147. PidMode: ""
  3148. PortBindings: {}
  3149. Privileged: false
  3150. ReadonlyRootfs: false
  3151. PublishAllPorts: false
  3152. RestartPolicy:
  3153. MaximumRetryCount: 2
  3154. Name: "on-failure"
  3155. LogConfig:
  3156. Type: "json-file"
  3157. Sysctls:
  3158. net.ipv4.ip_forward: "1"
  3159. Ulimits:
  3160. - {}
  3161. VolumeDriver: ""
  3162. ShmSize: 67108864
  3163. HostnamePath: "/var/lib/docker/containers/ba033ac4401106a3b513bc9d639eee123ad78ca3616b921167cd74b20e25ed39/hostname"
  3164. HostsPath: "/var/lib/docker/containers/ba033ac4401106a3b513bc9d639eee123ad78ca3616b921167cd74b20e25ed39/hosts"
  3165. LogPath: "/var/lib/docker/containers/1eb5fabf5a03807136561b3c00adcd2992b535d624d5e18b6cdc6a6844d9767b/1eb5fabf5a03807136561b3c00adcd2992b535d624d5e18b6cdc6a6844d9767b-json.log"
  3166. Id: "ba033ac4401106a3b513bc9d639eee123ad78ca3616b921167cd74b20e25ed39"
  3167. Image: "04c5d3b7b0656168630d3ba35d8889bd0e9caafcaeb3004d2bfbc47e7c5d35d2"
  3168. MountLabel: ""
  3169. Name: "/boring_euclid"
  3170. NetworkSettings:
  3171. Bridge: ""
  3172. SandboxID: ""
  3173. HairpinMode: false
  3174. LinkLocalIPv6Address: ""
  3175. LinkLocalIPv6PrefixLen: 0
  3176. SandboxKey: ""
  3177. SecondaryIPAddresses: null
  3178. SecondaryIPv6Addresses: null
  3179. EndpointID: ""
  3180. Gateway: ""
  3181. GlobalIPv6Address: ""
  3182. GlobalIPv6PrefixLen: 0
  3183. IPAddress: ""
  3184. IPPrefixLen: 0
  3185. IPv6Gateway: ""
  3186. MacAddress: ""
  3187. Networks:
  3188. bridge:
  3189. NetworkID: "7ea29fc1412292a2d7bba362f9253545fecdfa8ce9a6e37dd10ba8bee7129812"
  3190. EndpointID: "7587b82f0dada3656fda26588aee72630c6fab1536d36e394b2bfbcf898c971d"
  3191. Gateway: "172.17.0.1"
  3192. IPAddress: "172.17.0.2"
  3193. IPPrefixLen: 16
  3194. IPv6Gateway: ""
  3195. GlobalIPv6Address: ""
  3196. GlobalIPv6PrefixLen: 0
  3197. MacAddress: "02:42:ac:12:00:02"
  3198. Path: "/bin/sh"
  3199. ProcessLabel: ""
  3200. ResolvConfPath: "/var/lib/docker/containers/ba033ac4401106a3b513bc9d639eee123ad78ca3616b921167cd74b20e25ed39/resolv.conf"
  3201. RestartCount: 1
  3202. State:
  3203. Error: ""
  3204. ExitCode: 9
  3205. FinishedAt: "2015-01-06T15:47:32.080254511Z"
  3206. OOMKilled: false
  3207. Dead: false
  3208. Paused: false
  3209. Pid: 0
  3210. Restarting: false
  3211. Running: true
  3212. StartedAt: "2015-01-06T15:47:32.072697474Z"
  3213. Status: "running"
  3214. Mounts:
  3215. - Name: "fac362...80535"
  3216. Source: "/data"
  3217. Destination: "/data"
  3218. Driver: "local"
  3219. Mode: "ro,Z"
  3220. RW: false
  3221. Propagation: ""
  3222. 404:
  3223. description: "no such container"
  3224. schema:
  3225. $ref: "#/definitions/ErrorResponse"
  3226. examples:
  3227. application/json:
  3228. message: "No such container: c2ada9df5af8"
  3229. 500:
  3230. description: "server error"
  3231. schema:
  3232. $ref: "#/definitions/ErrorResponse"
  3233. parameters:
  3234. - name: "id"
  3235. in: "path"
  3236. required: true
  3237. description: "ID or name of the container"
  3238. type: "string"
  3239. - name: "size"
  3240. in: "query"
  3241. type: "boolean"
  3242. default: false
  3243. description: "Return the size of container as fields `SizeRw` and `SizeRootFs`"
  3244. tags: ["Container"]
  3245. /containers/{id}/top:
  3246. get:
  3247. summary: "List processes running inside a container"
  3248. description: "On Unix systems, this is done by running the `ps` command. This endpoint is not supported on Windows."
  3249. operationId: "ContainerTop"
  3250. responses:
  3251. 200:
  3252. description: "no error"
  3253. schema:
  3254. type: "object"
  3255. properties:
  3256. Titles:
  3257. description: "The ps column titles"
  3258. type: "array"
  3259. items:
  3260. type: "string"
  3261. Processes:
  3262. description: "Each process running in the container, where each is process is an array of values corresponding to the titles"
  3263. type: "array"
  3264. items:
  3265. type: "array"
  3266. items:
  3267. type: "string"
  3268. examples:
  3269. application/json:
  3270. Titles:
  3271. - "UID"
  3272. - "PID"
  3273. - "PPID"
  3274. - "C"
  3275. - "STIME"
  3276. - "TTY"
  3277. - "TIME"
  3278. - "CMD"
  3279. Processes:
  3280. -
  3281. - "root"
  3282. - "13642"
  3283. - "882"
  3284. - "0"
  3285. - "17:03"
  3286. - "pts/0"
  3287. - "00:00:00"
  3288. - "/bin/bash"
  3289. -
  3290. - "root"
  3291. - "13735"
  3292. - "13642"
  3293. - "0"
  3294. - "17:06"
  3295. - "pts/0"
  3296. - "00:00:00"
  3297. - "sleep 10"
  3298. 404:
  3299. description: "no such container"
  3300. schema:
  3301. $ref: "#/definitions/ErrorResponse"
  3302. examples:
  3303. application/json:
  3304. message: "No such container: c2ada9df5af8"
  3305. 500:
  3306. description: "server error"
  3307. schema:
  3308. $ref: "#/definitions/ErrorResponse"
  3309. parameters:
  3310. - name: "id"
  3311. in: "path"
  3312. required: true
  3313. description: "ID or name of the container"
  3314. type: "string"
  3315. - name: "ps_args"
  3316. in: "query"
  3317. description: "The arguments to pass to `ps`. For example, `aux`"
  3318. type: "string"
  3319. default: "-ef"
  3320. tags: ["Container"]
  3321. /containers/{id}/logs:
  3322. get:
  3323. summary: "Get container logs"
  3324. description: |
  3325. Get `stdout` and `stderr` logs from a container.
  3326. Note: This endpoint works only for containers with the `json-file` or `journald` logging driver.
  3327. operationId: "ContainerLogs"
  3328. responses:
  3329. 101:
  3330. description: "logs returned as a stream"
  3331. schema:
  3332. type: "string"
  3333. format: "binary"
  3334. 200:
  3335. description: "logs returned as a string in response body"
  3336. schema:
  3337. type: "string"
  3338. 404:
  3339. description: "no such container"
  3340. schema:
  3341. $ref: "#/definitions/ErrorResponse"
  3342. examples:
  3343. application/json:
  3344. message: "No such container: c2ada9df5af8"
  3345. 500:
  3346. description: "server error"
  3347. schema:
  3348. $ref: "#/definitions/ErrorResponse"
  3349. parameters:
  3350. - name: "id"
  3351. in: "path"
  3352. required: true
  3353. description: "ID or name of the container"
  3354. type: "string"
  3355. - name: "follow"
  3356. in: "query"
  3357. description: |
  3358. Return the logs as a stream.
  3359. This will return a `101` HTTP response with a `Connection: upgrade` header, then hijack the HTTP connection to send raw output. For more information about hijacking and the stream format, [see the documentation for the attach endpoint](#operation/ContainerAttach).
  3360. type: "boolean"
  3361. default: false
  3362. - name: "stdout"
  3363. in: "query"
  3364. description: "Return logs from `stdout`"
  3365. type: "boolean"
  3366. default: false
  3367. - name: "stderr"
  3368. in: "query"
  3369. description: "Return logs from `stderr`"
  3370. type: "boolean"
  3371. default: false
  3372. - name: "since"
  3373. in: "query"
  3374. description: "Only return logs since this time, as a UNIX timestamp"
  3375. type: "integer"
  3376. default: 0
  3377. - name: "timestamps"
  3378. in: "query"
  3379. description: "Add timestamps to every log line"
  3380. type: "boolean"
  3381. default: false
  3382. - name: "tail"
  3383. in: "query"
  3384. description: "Only return this number of log lines from the end of the logs. Specify as an integer or `all` to output all log lines."
  3385. type: "string"
  3386. default: "all"
  3387. tags: ["Container"]
  3388. /containers/{id}/changes:
  3389. get:
  3390. summary: "Get changes on a container’s filesystem"
  3391. description: |
  3392. Returns which files in a container's filesystem have been added, deleted,
  3393. or modified. The `Kind` of modification can be one of:
  3394. - `0`: Modified
  3395. - `1`: Added
  3396. - `2`: Deleted
  3397. operationId: "ContainerChanges"
  3398. produces: ["application/json"]
  3399. responses:
  3400. 200:
  3401. description: "The list of changes"
  3402. schema:
  3403. type: "array"
  3404. items:
  3405. type: "object"
  3406. x-go-name: "ContainerChangeResponseItem"
  3407. required: [Path, Kind]
  3408. properties:
  3409. Path:
  3410. description: "Path to file that has changed"
  3411. type: "string"
  3412. x-nullable: false
  3413. Kind:
  3414. description: "Kind of change"
  3415. type: "integer"
  3416. format: "uint8"
  3417. enum: [0, 1, 2]
  3418. x-nullable: false
  3419. examples:
  3420. application/json:
  3421. - Path: "/dev"
  3422. Kind: 0
  3423. - Path: "/dev/kmsg"
  3424. Kind: 1
  3425. - Path: "/test"
  3426. Kind: 1
  3427. 404:
  3428. description: "no such container"
  3429. schema:
  3430. $ref: "#/definitions/ErrorResponse"
  3431. examples:
  3432. application/json:
  3433. message: "No such container: c2ada9df5af8"
  3434. 500:
  3435. description: "server error"
  3436. schema:
  3437. $ref: "#/definitions/ErrorResponse"
  3438. parameters:
  3439. - name: "id"
  3440. in: "path"
  3441. required: true
  3442. description: "ID or name of the container"
  3443. type: "string"
  3444. tags: ["Container"]
  3445. /containers/{id}/export:
  3446. get:
  3447. summary: "Export a container"
  3448. description: "Export the contents of a container as a tarball."
  3449. operationId: "ContainerExport"
  3450. produces:
  3451. - "application/octet-stream"
  3452. responses:
  3453. 200:
  3454. description: "no error"
  3455. 404:
  3456. description: "no such container"
  3457. schema:
  3458. $ref: "#/definitions/ErrorResponse"
  3459. examples:
  3460. application/json:
  3461. message: "No such container: c2ada9df5af8"
  3462. 500:
  3463. description: "server error"
  3464. schema:
  3465. $ref: "#/definitions/ErrorResponse"
  3466. parameters:
  3467. - name: "id"
  3468. in: "path"
  3469. required: true
  3470. description: "ID or name of the container"
  3471. type: "string"
  3472. tags: ["Container"]
  3473. /containers/{id}/stats:
  3474. get:
  3475. summary: "Get container stats based on resource usage"
  3476. description: |
  3477. This endpoint returns a live stream of a container’s resource usage
  3478. statistics.
  3479. The `precpu_stats` is the CPU statistic of last read, which is used
  3480. for calculating the CPU usage percentage. It is not the same as the
  3481. `cpu_stats` field.
  3482. If either `precpu_stats.online_cpus` or `cpu_stats.online_cpus` is
  3483. nil then for compatibility with older daemons the length of the
  3484. corresponding `cpu_usage.percpu_usage` array should be used.
  3485. operationId: "ContainerStats"
  3486. produces: ["application/json"]
  3487. responses:
  3488. 200:
  3489. description: "no error"
  3490. schema:
  3491. type: "object"
  3492. examples:
  3493. application/json:
  3494. read: "2015-01-08T22:57:31.547920715Z"
  3495. pids_stats:
  3496. current: 3
  3497. networks:
  3498. eth0:
  3499. rx_bytes: 5338
  3500. rx_dropped: 0
  3501. rx_errors: 0
  3502. rx_packets: 36
  3503. tx_bytes: 648
  3504. tx_dropped: 0
  3505. tx_errors: 0
  3506. tx_packets: 8
  3507. eth5:
  3508. rx_bytes: 4641
  3509. rx_dropped: 0
  3510. rx_errors: 0
  3511. rx_packets: 26
  3512. tx_bytes: 690
  3513. tx_dropped: 0
  3514. tx_errors: 0
  3515. tx_packets: 9
  3516. memory_stats:
  3517. stats:
  3518. total_pgmajfault: 0
  3519. cache: 0
  3520. mapped_file: 0
  3521. total_inactive_file: 0
  3522. pgpgout: 414
  3523. rss: 6537216
  3524. total_mapped_file: 0
  3525. writeback: 0
  3526. unevictable: 0
  3527. pgpgin: 477
  3528. total_unevictable: 0
  3529. pgmajfault: 0
  3530. total_rss: 6537216
  3531. total_rss_huge: 6291456
  3532. total_writeback: 0
  3533. total_inactive_anon: 0
  3534. rss_huge: 6291456
  3535. hierarchical_memory_limit: 67108864
  3536. total_pgfault: 964
  3537. total_active_file: 0
  3538. active_anon: 6537216
  3539. total_active_anon: 6537216
  3540. total_pgpgout: 414
  3541. total_cache: 0
  3542. inactive_anon: 0
  3543. active_file: 0
  3544. pgfault: 964
  3545. inactive_file: 0
  3546. total_pgpgin: 477
  3547. max_usage: 6651904
  3548. usage: 6537216
  3549. failcnt: 0
  3550. limit: 67108864
  3551. blkio_stats: {}
  3552. cpu_stats:
  3553. cpu_usage:
  3554. percpu_usage:
  3555. - 8646879
  3556. - 24472255
  3557. - 36438778
  3558. - 30657443
  3559. usage_in_usermode: 50000000
  3560. total_usage: 100215355
  3561. usage_in_kernelmode: 30000000
  3562. system_cpu_usage: 739306590000000
  3563. online_cpus: 4
  3564. throttling_data:
  3565. periods: 0
  3566. throttled_periods: 0
  3567. throttled_time: 0
  3568. precpu_stats:
  3569. cpu_usage:
  3570. percpu_usage:
  3571. - 8646879
  3572. - 24350896
  3573. - 36438778
  3574. - 30657443
  3575. usage_in_usermode: 50000000
  3576. total_usage: 100093996
  3577. usage_in_kernelmode: 30000000
  3578. system_cpu_usage: 9492140000000
  3579. online_cpus: 4
  3580. throttling_data:
  3581. periods: 0
  3582. throttled_periods: 0
  3583. throttled_time: 0
  3584. 404:
  3585. description: "no such container"
  3586. schema:
  3587. $ref: "#/definitions/ErrorResponse"
  3588. examples:
  3589. application/json:
  3590. message: "No such container: c2ada9df5af8"
  3591. 500:
  3592. description: "server error"
  3593. schema:
  3594. $ref: "#/definitions/ErrorResponse"
  3595. parameters:
  3596. - name: "id"
  3597. in: "path"
  3598. required: true
  3599. description: "ID or name of the container"
  3600. type: "string"
  3601. - name: "stream"
  3602. in: "query"
  3603. description: "Stream the output. If false, the stats will be output once and then it will disconnect."
  3604. type: "boolean"
  3605. default: true
  3606. tags: ["Container"]
  3607. /containers/{id}/resize:
  3608. post:
  3609. summary: "Resize a container TTY"
  3610. description: "Resize the TTY for a container. You must restart the container for the resize to take effect."
  3611. operationId: "ContainerResize"
  3612. consumes:
  3613. - "application/octet-stream"
  3614. produces:
  3615. - "text/plain"
  3616. responses:
  3617. 200:
  3618. description: "no error"
  3619. 404:
  3620. description: "no such container"
  3621. schema:
  3622. $ref: "#/definitions/ErrorResponse"
  3623. examples:
  3624. application/json:
  3625. message: "No such container: c2ada9df5af8"
  3626. 500:
  3627. description: "cannot resize container"
  3628. schema:
  3629. $ref: "#/definitions/ErrorResponse"
  3630. parameters:
  3631. - name: "id"
  3632. in: "path"
  3633. required: true
  3634. description: "ID or name of the container"
  3635. type: "string"
  3636. - name: "h"
  3637. in: "query"
  3638. description: "Height of the tty session in characters"
  3639. type: "integer"
  3640. - name: "w"
  3641. in: "query"
  3642. description: "Width of the tty session in characters"
  3643. type: "integer"
  3644. tags: ["Container"]
  3645. /containers/{id}/start:
  3646. post:
  3647. summary: "Start a container"
  3648. operationId: "ContainerStart"
  3649. responses:
  3650. 204:
  3651. description: "no error"
  3652. 304:
  3653. description: "container already started"
  3654. schema:
  3655. $ref: "#/definitions/ErrorResponse"
  3656. 404:
  3657. description: "no such container"
  3658. schema:
  3659. $ref: "#/definitions/ErrorResponse"
  3660. examples:
  3661. application/json:
  3662. message: "No such container: c2ada9df5af8"
  3663. 500:
  3664. description: "server error"
  3665. schema:
  3666. $ref: "#/definitions/ErrorResponse"
  3667. parameters:
  3668. - name: "id"
  3669. in: "path"
  3670. required: true
  3671. description: "ID or name of the container"
  3672. type: "string"
  3673. - name: "detachKeys"
  3674. in: "query"
  3675. description: "Override the key sequence for detaching a container. Format is a single character `[a-Z]` or `ctrl-<value>` where `<value>` is one of: `a-z`, `@`, `^`, `[`, `,` or `_`."
  3676. type: "string"
  3677. tags: ["Container"]
  3678. /containers/{id}/stop:
  3679. post:
  3680. summary: "Stop a container"
  3681. operationId: "ContainerStop"
  3682. responses:
  3683. 204:
  3684. description: "no error"
  3685. 304:
  3686. description: "container already stopped"
  3687. schema:
  3688. $ref: "#/definitions/ErrorResponse"
  3689. 404:
  3690. description: "no such container"
  3691. schema:
  3692. $ref: "#/definitions/ErrorResponse"
  3693. examples:
  3694. application/json:
  3695. message: "No such container: c2ada9df5af8"
  3696. 500:
  3697. description: "server error"
  3698. schema:
  3699. $ref: "#/definitions/ErrorResponse"
  3700. parameters:
  3701. - name: "id"
  3702. in: "path"
  3703. required: true
  3704. description: "ID or name of the container"
  3705. type: "string"
  3706. - name: "t"
  3707. in: "query"
  3708. description: "Number of seconds to wait before killing the container"
  3709. type: "integer"
  3710. tags: ["Container"]
  3711. /containers/{id}/restart:
  3712. post:
  3713. summary: "Restart a container"
  3714. operationId: "ContainerRestart"
  3715. responses:
  3716. 204:
  3717. description: "no error"
  3718. 404:
  3719. description: "no such container"
  3720. schema:
  3721. $ref: "#/definitions/ErrorResponse"
  3722. examples:
  3723. application/json:
  3724. message: "No such container: c2ada9df5af8"
  3725. 500:
  3726. description: "server error"
  3727. schema:
  3728. $ref: "#/definitions/ErrorResponse"
  3729. parameters:
  3730. - name: "id"
  3731. in: "path"
  3732. required: true
  3733. description: "ID or name of the container"
  3734. type: "string"
  3735. - name: "t"
  3736. in: "query"
  3737. description: "Number of seconds to wait before killing the container"
  3738. type: "integer"
  3739. tags: ["Container"]
  3740. /containers/{id}/kill:
  3741. post:
  3742. summary: "Kill a container"
  3743. description: "Send a POSIX signal to a container, defaulting to killing to the container."
  3744. operationId: "ContainerKill"
  3745. responses:
  3746. 204:
  3747. description: "no error"
  3748. 404:
  3749. description: "no such container"
  3750. schema:
  3751. $ref: "#/definitions/ErrorResponse"
  3752. examples:
  3753. application/json:
  3754. message: "No such container: c2ada9df5af8"
  3755. 500:
  3756. description: "server error"
  3757. schema:
  3758. $ref: "#/definitions/ErrorResponse"
  3759. parameters:
  3760. - name: "id"
  3761. in: "path"
  3762. required: true
  3763. description: "ID or name of the container"
  3764. type: "string"
  3765. - name: "signal"
  3766. in: "query"
  3767. description: "Signal to send to the container as an integer or string (e.g. `SIGINT`)"
  3768. type: "string"
  3769. default: "SIGKILL"
  3770. tags: ["Container"]
  3771. /containers/{id}/update:
  3772. post:
  3773. summary: "Update a container"
  3774. description: "Change various configuration options of a container without having to recreate it."
  3775. operationId: "ContainerUpdate"
  3776. consumes: ["application/json"]
  3777. produces: ["application/json"]
  3778. responses:
  3779. 200:
  3780. description: "The container has been updated."
  3781. schema:
  3782. type: "object"
  3783. properties:
  3784. Warnings:
  3785. type: "array"
  3786. items:
  3787. type: "string"
  3788. 404:
  3789. description: "no such container"
  3790. schema:
  3791. $ref: "#/definitions/ErrorResponse"
  3792. examples:
  3793. application/json:
  3794. message: "No such container: c2ada9df5af8"
  3795. 500:
  3796. description: "server error"
  3797. schema:
  3798. $ref: "#/definitions/ErrorResponse"
  3799. parameters:
  3800. - name: "id"
  3801. in: "path"
  3802. required: true
  3803. description: "ID or name of the container"
  3804. type: "string"
  3805. - name: "update"
  3806. in: "body"
  3807. required: true
  3808. schema:
  3809. allOf:
  3810. - $ref: "#/definitions/Resources"
  3811. - type: "object"
  3812. properties:
  3813. RestartPolicy:
  3814. $ref: "#/definitions/RestartPolicy"
  3815. example:
  3816. BlkioWeight: 300
  3817. CpuShares: 512
  3818. CpuPeriod: 100000
  3819. CpuQuota: 50000
  3820. CpuRealtimePeriod: 1000000
  3821. CpuRealtimeRuntime: 10000
  3822. CpusetCpus: "0,1"
  3823. CpusetMems: "0"
  3824. Memory: 314572800
  3825. MemorySwap: 514288000
  3826. MemoryReservation: 209715200
  3827. KernelMemory: 52428800
  3828. RestartPolicy:
  3829. MaximumRetryCount: 4
  3830. Name: "on-failure"
  3831. tags: ["Container"]
  3832. /containers/{id}/rename:
  3833. post:
  3834. summary: "Rename a container"
  3835. operationId: "ContainerRename"
  3836. responses:
  3837. 204:
  3838. description: "no error"
  3839. 404:
  3840. description: "no such container"
  3841. schema:
  3842. $ref: "#/definitions/ErrorResponse"
  3843. examples:
  3844. application/json:
  3845. message: "No such container: c2ada9df5af8"
  3846. 409:
  3847. description: "name already in use"
  3848. schema:
  3849. $ref: "#/definitions/ErrorResponse"
  3850. 500:
  3851. description: "server error"
  3852. schema:
  3853. $ref: "#/definitions/ErrorResponse"
  3854. parameters:
  3855. - name: "id"
  3856. in: "path"
  3857. required: true
  3858. description: "ID or name of the container"
  3859. type: "string"
  3860. - name: "name"
  3861. in: "query"
  3862. required: true
  3863. description: "New name for the container"
  3864. type: "string"
  3865. tags: ["Container"]
  3866. /containers/{id}/pause:
  3867. post:
  3868. summary: "Pause a container"
  3869. description: |
  3870. Use the cgroups freezer to suspend all processes in a container.
  3871. Traditionally, when suspending a process the `SIGSTOP` signal is used, which is observable by the process being suspended. With the cgroups freezer the process is unaware, and unable to capture, that it is being suspended, and subsequently resumed.
  3872. operationId: "ContainerPause"
  3873. responses:
  3874. 204:
  3875. description: "no error"
  3876. 404:
  3877. description: "no such container"
  3878. schema:
  3879. $ref: "#/definitions/ErrorResponse"
  3880. examples:
  3881. application/json:
  3882. message: "No such container: c2ada9df5af8"
  3883. 500:
  3884. description: "server error"
  3885. schema:
  3886. $ref: "#/definitions/ErrorResponse"
  3887. parameters:
  3888. - name: "id"
  3889. in: "path"
  3890. required: true
  3891. description: "ID or name of the container"
  3892. type: "string"
  3893. tags: ["Container"]
  3894. /containers/{id}/unpause:
  3895. post:
  3896. summary: "Unpause a container"
  3897. description: "Resume a container which has been paused."
  3898. operationId: "ContainerUnpause"
  3899. responses:
  3900. 204:
  3901. description: "no error"
  3902. 404:
  3903. description: "no such container"
  3904. schema:
  3905. $ref: "#/definitions/ErrorResponse"
  3906. examples:
  3907. application/json:
  3908. message: "No such container: c2ada9df5af8"
  3909. 500:
  3910. description: "server error"
  3911. schema:
  3912. $ref: "#/definitions/ErrorResponse"
  3913. parameters:
  3914. - name: "id"
  3915. in: "path"
  3916. required: true
  3917. description: "ID or name of the container"
  3918. type: "string"
  3919. tags: ["Container"]
  3920. /containers/{id}/attach:
  3921. post:
  3922. summary: "Attach to a container"
  3923. description: |
  3924. Attach to a container to read its output or send it input. You can attach to the same container multiple times and you can reattach to containers that have been detached.
  3925. Either the `stream` or `logs` parameter must be `true` for this endpoint to do anything.
  3926. See [the documentation for the `docker attach` command](https://docs.docker.com/engine/reference/commandline/attach/) for more details.
  3927. ### Hijacking
  3928. This endpoint hijacks the HTTP connection to transport `stdin`, `stdout`, and `stderr` on the same socket.
  3929. This is the response from the daemon for an attach request:
  3930. ```
  3931. HTTP/1.1 200 OK
  3932. Content-Type: application/vnd.docker.raw-stream
  3933. [STREAM]
  3934. ```
  3935. After the headers and two new lines, the TCP connection can now be used for raw, bidirectional communication between the client and server.
  3936. To hint potential proxies about connection hijacking, the Docker client can also optionally send connection upgrade headers.
  3937. For example, the client sends this request to upgrade the connection:
  3938. ```
  3939. POST /containers/16253994b7c4/attach?stream=1&stdout=1 HTTP/1.1
  3940. Upgrade: tcp
  3941. Connection: Upgrade
  3942. ```
  3943. The Docker daemon will respond with a `101 UPGRADED` response, and will similarly follow with the raw stream:
  3944. ```
  3945. HTTP/1.1 101 UPGRADED
  3946. Content-Type: application/vnd.docker.raw-stream
  3947. Connection: Upgrade
  3948. Upgrade: tcp
  3949. [STREAM]
  3950. ```
  3951. ### Stream format
  3952. When the TTY setting is disabled in [`POST /containers/create`](#operation/ContainerCreate), the stream over the hijacked connected is multiplexed to separate out `stdout` and `stderr`. The stream consists of a series of frames, each containing a header and a payload.
  3953. The header contains the information which the stream writes (`stdout` or `stderr`). It also contains the size of the associated frame encoded in the last four bytes (`uint32`).
  3954. It is encoded on the first eight bytes like this:
  3955. ```go
  3956. header := [8]byte{STREAM_TYPE, 0, 0, 0, SIZE1, SIZE2, SIZE3, SIZE4}
  3957. ```
  3958. `STREAM_TYPE` can be:
  3959. - 0: `stdin` (is written on `stdout`)
  3960. - 1: `stdout`
  3961. - 2: `stderr`
  3962. `SIZE1, SIZE2, SIZE3, SIZE4` are the four bytes of the `uint32` size encoded as big endian.
  3963. Following the header is the payload, which is the specified number of bytes of `STREAM_TYPE`.
  3964. The simplest way to implement this protocol is the following:
  3965. 1. Read 8 bytes.
  3966. 2. Choose `stdout` or `stderr` depending on the first byte.
  3967. 3. Extract the frame size from the last four bytes.
  3968. 4. Read the extracted size and output it on the correct output.
  3969. 5. Goto 1.
  3970. ### Stream format when using a TTY
  3971. When the TTY setting is enabled in [`POST /containers/create`](#operation/ContainerCreate), the stream is not multiplexed. The data exchanged over the hijacked connection is simply the raw data from the process PTY and client's `stdin`.
  3972. operationId: "ContainerAttach"
  3973. produces:
  3974. - "application/vnd.docker.raw-stream"
  3975. responses:
  3976. 101:
  3977. description: "no error, hints proxy about hijacking"
  3978. 200:
  3979. description: "no error, no upgrade header found"
  3980. 400:
  3981. description: "bad parameter"
  3982. schema:
  3983. $ref: "#/definitions/ErrorResponse"
  3984. 404:
  3985. description: "no such container"
  3986. schema:
  3987. $ref: "#/definitions/ErrorResponse"
  3988. examples:
  3989. application/json:
  3990. message: "No such container: c2ada9df5af8"
  3991. 500:
  3992. description: "server error"
  3993. schema:
  3994. $ref: "#/definitions/ErrorResponse"
  3995. parameters:
  3996. - name: "id"
  3997. in: "path"
  3998. required: true
  3999. description: "ID or name of the container"
  4000. type: "string"
  4001. - name: "detachKeys"
  4002. in: "query"
  4003. description: "Override the key sequence for detaching a container.Format is a single character `[a-Z]` or `ctrl-<value>` where `<value>` is one of: `a-z`, `@`, `^`, `[`, `,` or `_`."
  4004. type: "string"
  4005. - name: "logs"
  4006. in: "query"
  4007. description: |
  4008. Replay previous logs from the container.
  4009. This is useful for attaching to a container that has started and you want to output everything since the container started.
  4010. If `stream` is also enabled, once all the previous output has been returned, it will seamlessly transition into streaming current output.
  4011. type: "boolean"
  4012. default: false
  4013. - name: "stream"
  4014. in: "query"
  4015. description: "Stream attached streams from the time the request was made onwards"
  4016. type: "boolean"
  4017. default: false
  4018. - name: "stdin"
  4019. in: "query"
  4020. description: "Attach to `stdin`"
  4021. type: "boolean"
  4022. default: false
  4023. - name: "stdout"
  4024. in: "query"
  4025. description: "Attach to `stdout`"
  4026. type: "boolean"
  4027. default: false
  4028. - name: "stderr"
  4029. in: "query"
  4030. description: "Attach to `stderr`"
  4031. type: "boolean"
  4032. default: false
  4033. tags: ["Container"]
  4034. /containers/{id}/attach/ws:
  4035. get:
  4036. summary: "Attach to a container via a websocket"
  4037. operationId: "ContainerAttachWebsocket"
  4038. responses:
  4039. 101:
  4040. description: "no error, hints proxy about hijacking"
  4041. 200:
  4042. description: "no error, no upgrade header found"
  4043. 400:
  4044. description: "bad parameter"
  4045. schema:
  4046. $ref: "#/definitions/ErrorResponse"
  4047. 404:
  4048. description: "no such container"
  4049. schema:
  4050. $ref: "#/definitions/ErrorResponse"
  4051. examples:
  4052. application/json:
  4053. message: "No such container: c2ada9df5af8"
  4054. 500:
  4055. description: "server error"
  4056. schema:
  4057. $ref: "#/definitions/ErrorResponse"
  4058. parameters:
  4059. - name: "id"
  4060. in: "path"
  4061. required: true
  4062. description: "ID or name of the container"
  4063. type: "string"
  4064. - name: "detachKeys"
  4065. in: "query"
  4066. description: "Override the key sequence for detaching a container.Format is a single character `[a-Z]` or `ctrl-<value>` where `<value>` is one of: `a-z`, `@`, `^`, `[`, `,`, or `_`."
  4067. type: "string"
  4068. - name: "logs"
  4069. in: "query"
  4070. description: "Return logs"
  4071. type: "boolean"
  4072. default: false
  4073. - name: "stream"
  4074. in: "query"
  4075. description: "Return stream"
  4076. type: "boolean"
  4077. default: false
  4078. tags: ["Container"]
  4079. /containers/{id}/wait:
  4080. post:
  4081. summary: "Wait for a container"
  4082. description: "Block until a container stops, then returns the exit code."
  4083. operationId: "ContainerWait"
  4084. produces: ["application/json"]
  4085. responses:
  4086. 200:
  4087. description: "The container has exit."
  4088. schema:
  4089. type: "object"
  4090. required: [StatusCode]
  4091. properties:
  4092. StatusCode:
  4093. description: "Exit code of the container"
  4094. type: "integer"
  4095. x-nullable: false
  4096. 404:
  4097. description: "no such container"
  4098. schema:
  4099. $ref: "#/definitions/ErrorResponse"
  4100. examples:
  4101. application/json:
  4102. message: "No such container: c2ada9df5af8"
  4103. 500:
  4104. description: "server error"
  4105. schema:
  4106. $ref: "#/definitions/ErrorResponse"
  4107. parameters:
  4108. - name: "id"
  4109. in: "path"
  4110. required: true
  4111. description: "ID or name of the container"
  4112. type: "string"
  4113. tags: ["Container"]
  4114. /containers/{id}:
  4115. delete:
  4116. summary: "Remove a container"
  4117. operationId: "ContainerDelete"
  4118. responses:
  4119. 204:
  4120. description: "no error"
  4121. 400:
  4122. description: "bad parameter"
  4123. schema:
  4124. $ref: "#/definitions/ErrorResponse"
  4125. 404:
  4126. description: "no such container"
  4127. schema:
  4128. $ref: "#/definitions/ErrorResponse"
  4129. examples:
  4130. application/json:
  4131. message: "No such container: c2ada9df5af8"
  4132. 409:
  4133. description: "conflict"
  4134. schema:
  4135. $ref: "#/definitions/ErrorResponse"
  4136. examples:
  4137. application/json:
  4138. message: "You cannot remove a running container: c2ada9df5af8. Stop the container before attempting removal or force remove"
  4139. 500:
  4140. description: "server error"
  4141. schema:
  4142. $ref: "#/definitions/ErrorResponse"
  4143. parameters:
  4144. - name: "id"
  4145. in: "path"
  4146. required: true
  4147. description: "ID or name of the container"
  4148. type: "string"
  4149. - name: "v"
  4150. in: "query"
  4151. description: "Remove anonymous volumes associated with the container."
  4152. type: "boolean"
  4153. default: false
  4154. - name: "force"
  4155. in: "query"
  4156. description: "If the container is running, kill it before removing it."
  4157. type: "boolean"
  4158. default: false
  4159. - name: "link"
  4160. in: "query"
  4161. description: "Remove the specified link associated with the container."
  4162. type: "boolean"
  4163. default: false
  4164. tags: ["Container"]
  4165. /containers/{id}/archive:
  4166. head:
  4167. summary: "Get information about files in a container"
  4168. description: "A response header `X-Docker-Container-Path-Stat` is return containing a base64 - encoded JSON object with some filesystem header information about the path."
  4169. operationId: "ContainerArchiveInfo"
  4170. responses:
  4171. 200:
  4172. description: "no error"
  4173. headers:
  4174. X-Docker-Container-Path-Stat:
  4175. type: "string"
  4176. description: "TODO"
  4177. 400:
  4178. description: "Bad parameter"
  4179. schema:
  4180. $ref: "#/definitions/ErrorResponse"
  4181. 404:
  4182. description: "Container or path does not exist"
  4183. schema:
  4184. $ref: "#/definitions/ErrorResponse"
  4185. examples:
  4186. application/json:
  4187. message: "No such container: c2ada9df5af8"
  4188. 500:
  4189. description: "Server error"
  4190. schema:
  4191. $ref: "#/definitions/ErrorResponse"
  4192. parameters:
  4193. - name: "id"
  4194. in: "path"
  4195. required: true
  4196. description: "ID or name of the container"
  4197. type: "string"
  4198. - name: "path"
  4199. in: "query"
  4200. required: true
  4201. description: "Resource in the container’s filesystem to archive."
  4202. type: "string"
  4203. tags: ["Container"]
  4204. get:
  4205. summary: "Get an archive of a filesystem resource in a container"
  4206. description: "Get a tar archive of a resource in the filesystem of container id."
  4207. operationId: "ContainerArchive"
  4208. produces: ["application/x-tar"]
  4209. responses:
  4210. 200:
  4211. description: "no error"
  4212. 400:
  4213. description: "Bad parameter"
  4214. schema:
  4215. $ref: "#/definitions/ErrorResponse"
  4216. 404:
  4217. description: "Container or path does not exist"
  4218. schema:
  4219. $ref: "#/definitions/ErrorResponse"
  4220. examples:
  4221. application/json:
  4222. message: "No such container: c2ada9df5af8"
  4223. 500:
  4224. description: "server error"
  4225. schema:
  4226. $ref: "#/definitions/ErrorResponse"
  4227. parameters:
  4228. - name: "id"
  4229. in: "path"
  4230. required: true
  4231. description: "ID or name of the container"
  4232. type: "string"
  4233. - name: "path"
  4234. in: "query"
  4235. required: true
  4236. description: "Resource in the container’s filesystem to archive."
  4237. type: "string"
  4238. tags: ["Container"]
  4239. put:
  4240. summary: "Extract an archive of files or folders to a directory in a container"
  4241. description: |
  4242. Upload a tar archive to be extracted to a path in the filesystem of container id.
  4243. `path` parameter is asserted to be a directory. If it exists as a file, 400 error
  4244. will be returned with message "not a directory".
  4245. operationId: "PutContainerArchive"
  4246. consumes: ["application/x-tar", "application/octet-stream"]
  4247. responses:
  4248. 200:
  4249. description: "The content was extracted successfully"
  4250. 400:
  4251. description: "Bad parameter"
  4252. schema:
  4253. $ref: "#/definitions/ErrorResponse"
  4254. examples:
  4255. application/json:
  4256. message: "not a directory"
  4257. 403:
  4258. description: "Permission denied, the volume or container rootfs is marked as read-only."
  4259. schema:
  4260. $ref: "#/definitions/ErrorResponse"
  4261. 404:
  4262. description: "No such container or path does not exist inside the container"
  4263. schema:
  4264. $ref: "#/definitions/ErrorResponse"
  4265. examples:
  4266. application/json:
  4267. message: "No such container: c2ada9df5af8"
  4268. 500:
  4269. description: "Server error"
  4270. schema:
  4271. $ref: "#/definitions/ErrorResponse"
  4272. parameters:
  4273. - name: "id"
  4274. in: "path"
  4275. required: true
  4276. description: "ID or name of the container"
  4277. type: "string"
  4278. - name: "path"
  4279. in: "query"
  4280. required: true
  4281. description: "Path to a directory in the container to extract the archive’s contents into. "
  4282. type: "string"
  4283. - name: "noOverwriteDirNonDir"
  4284. in: "query"
  4285. description: "If “1”, “true”, or “True” then it will be an error if unpacking the given content would cause an existing directory to be replaced with a non-directory and vice versa."
  4286. type: "string"
  4287. - name: "inputStream"
  4288. in: "body"
  4289. required: true
  4290. description: "The input stream must be a tar archive compressed with one of the following algorithms: identity (no compression), gzip, bzip2, xz."
  4291. schema:
  4292. type: "string"
  4293. tags: ["Container"]
  4294. /containers/prune:
  4295. post:
  4296. summary: "Delete stopped containers"
  4297. produces:
  4298. - "application/json"
  4299. operationId: "ContainerPrune"
  4300. parameters:
  4301. - name: "filters"
  4302. in: "query"
  4303. description: |
  4304. Filters to process on the prune list, encoded as JSON (a `map[string][]string`).
  4305. Available filters:
  4306. - `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.
  4307. type: "string"
  4308. responses:
  4309. 200:
  4310. description: "No error"
  4311. schema:
  4312. type: "object"
  4313. properties:
  4314. ContainersDeleted:
  4315. description: "Container IDs that were deleted"
  4316. type: "array"
  4317. items:
  4318. type: "string"
  4319. SpaceReclaimed:
  4320. description: "Disk space reclaimed in bytes"
  4321. type: "integer"
  4322. format: "int64"
  4323. 500:
  4324. description: "Server error"
  4325. schema:
  4326. $ref: "#/definitions/ErrorResponse"
  4327. tags: ["Container"]
  4328. /images/json:
  4329. get:
  4330. summary: "List Images"
  4331. 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."
  4332. operationId: "ImageList"
  4333. produces:
  4334. - "application/json"
  4335. responses:
  4336. 200:
  4337. description: "Summary image data for the images matching the query"
  4338. schema:
  4339. type: "array"
  4340. items:
  4341. $ref: "#/definitions/ImageSummary"
  4342. examples:
  4343. application/json:
  4344. - Id: "sha256:e216a057b1cb1efc11f8a268f37ef62083e70b1b38323ba252e25ac88904a7e8"
  4345. ParentId: ""
  4346. RepoTags:
  4347. - "ubuntu:12.04"
  4348. - "ubuntu:precise"
  4349. RepoDigests:
  4350. - "ubuntu@sha256:992069aee4016783df6345315302fa59681aae51a8eeb2f889dea59290f21787"
  4351. Created: 1474925151
  4352. Size: 103579269
  4353. VirtualSize: 103579269
  4354. SharedSize: 0
  4355. Labels: {}
  4356. Containers: 2
  4357. - Id: "sha256:3e314f95dcace0f5e4fd37b10862fe8398e3c60ed36600bc0ca5fda78b087175"
  4358. ParentId: ""
  4359. RepoTags:
  4360. - "ubuntu:12.10"
  4361. - "ubuntu:quantal"
  4362. RepoDigests:
  4363. - "ubuntu@sha256:002fba3e3255af10be97ea26e476692a7ebed0bb074a9ab960b2e7a1526b15d7"
  4364. - "ubuntu@sha256:68ea0200f0b90df725d99d823905b04cf844f6039ef60c60bf3e019915017bd3"
  4365. Created: 1403128455
  4366. Size: 172064416
  4367. VirtualSize: 172064416
  4368. SharedSize: 0
  4369. Labels: {}
  4370. Containers: 5
  4371. 500:
  4372. description: "server error"
  4373. schema:
  4374. $ref: "#/definitions/ErrorResponse"
  4375. parameters:
  4376. - name: "all"
  4377. in: "query"
  4378. description: "Show all images. Only images from a final layer (no children) are shown by default."
  4379. type: "boolean"
  4380. default: false
  4381. - name: "filters"
  4382. in: "query"
  4383. description: |
  4384. A JSON encoded value of the filters (a `map[string][]string`) to process on the images list. Available filters:
  4385. - `before`=(`<image-name>[:<tag>]`, `<image id>` or `<image@digest>`)
  4386. - `dangling=true`
  4387. - `label=key` or `label="key=value"` of an image label
  4388. - `reference`=(`<image-name>[:<tag>]`)
  4389. - `since`=(`<image-name>[:<tag>]`, `<image id>` or `<image@digest>`)
  4390. type: "string"
  4391. - name: "digests"
  4392. in: "query"
  4393. description: "Show digest information as a `RepoDigests` field on each image."
  4394. type: "boolean"
  4395. default: false
  4396. tags: ["Image"]
  4397. /build:
  4398. post:
  4399. summary: "Build an image"
  4400. description: |
  4401. Build an image from a tar archive with a `Dockerfile` in it.
  4402. 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/).
  4403. 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.
  4404. The build is canceled if the client drops the connection by quitting or being killed.
  4405. operationId: "ImageBuild"
  4406. consumes:
  4407. - "application/octet-stream"
  4408. produces:
  4409. - "application/json"
  4410. parameters:
  4411. - name: "inputStream"
  4412. in: "body"
  4413. description: "A tar archive compressed with one of the following algorithms: identity (no compression), gzip, bzip2, xz."
  4414. schema:
  4415. type: "string"
  4416. format: "binary"
  4417. - name: "dockerfile"
  4418. in: "query"
  4419. description: "Path within the build context to the `Dockerfile`. This is ignored if `remote` is specified and points to an external `Dockerfile`."
  4420. type: "string"
  4421. default: "Dockerfile"
  4422. - name: "t"
  4423. in: "query"
  4424. 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."
  4425. type: "string"
  4426. - name: "extrahosts"
  4427. in: "query"
  4428. description: "Extra hosts to add to /etc/hosts"
  4429. type: "string"
  4430. - name: "remote"
  4431. in: "query"
  4432. 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."
  4433. type: "string"
  4434. - name: "q"
  4435. in: "query"
  4436. description: "Suppress verbose build output."
  4437. type: "boolean"
  4438. default: false
  4439. - name: "nocache"
  4440. in: "query"
  4441. description: "Do not use the cache when building the image."
  4442. type: "boolean"
  4443. default: false
  4444. - name: "cachefrom"
  4445. in: "query"
  4446. description: "JSON array of images used for build cache resolution."
  4447. type: "string"
  4448. - name: "pull"
  4449. in: "query"
  4450. description: "Attempt to pull the image even if an older image exists locally."
  4451. type: "string"
  4452. - name: "rm"
  4453. in: "query"
  4454. description: "Remove intermediate containers after a successful build."
  4455. type: "boolean"
  4456. default: true
  4457. - name: "forcerm"
  4458. in: "query"
  4459. description: "Always remove intermediate containers, even upon failure."
  4460. type: "boolean"
  4461. default: false
  4462. - name: "memory"
  4463. in: "query"
  4464. description: "Set memory limit for build."
  4465. type: "integer"
  4466. - name: "memswap"
  4467. in: "query"
  4468. description: "Total memory (memory + swap). Set as `-1` to disable swap."
  4469. type: "integer"
  4470. - name: "cpushares"
  4471. in: "query"
  4472. description: "CPU shares (relative weight)."
  4473. type: "integer"
  4474. - name: "cpusetcpus"
  4475. in: "query"
  4476. description: "CPUs in which to allow execution (e.g., `0-3`, `0,1`)."
  4477. type: "string"
  4478. - name: "cpuperiod"
  4479. in: "query"
  4480. description: "The length of a CPU period in microseconds."
  4481. type: "integer"
  4482. - name: "cpuquota"
  4483. in: "query"
  4484. description: "Microseconds of CPU time that the container can get in a CPU period."
  4485. type: "integer"
  4486. - name: "buildargs"
  4487. in: "query"
  4488. description: "JSON map of string pairs for build-time variables. Users pass these values at build-time. Docker uses the buildargs as the environment context for commands run via the `Dockerfile` RUN instruction, or for variable expansion in other `Dockerfile` instructions. This is not meant for passing secret values. [Read more about the buildargs instruction.](https://docs.docker.com/engine/reference/builder/#arg)"
  4489. type: "integer"
  4490. - name: "shmsize"
  4491. in: "query"
  4492. description: "Size of `/dev/shm` in bytes. The size must be greater than 0. If omitted the system uses 64MB."
  4493. type: "integer"
  4494. - name: "squash"
  4495. in: "query"
  4496. description: "Squash the resulting images layers into a single layer. *(Experimental release only.)*"
  4497. type: "boolean"
  4498. - name: "labels"
  4499. in: "query"
  4500. description: "Arbitrary key/value labels to set on the image, as a JSON map of string pairs."
  4501. type: "string"
  4502. - name: "networkmode"
  4503. in: "query"
  4504. description: "Sets the networking mode for the run commands during
  4505. build. Supported standard values are: `bridge`, `host`, `none`, and
  4506. `container:<name|id>`. Any other value is taken as a custom network's
  4507. name to which this container should connect to."
  4508. type: "string"
  4509. - name: "Content-type"
  4510. in: "header"
  4511. type: "string"
  4512. enum:
  4513. - "application/x-tar"
  4514. default: "application/x-tar"
  4515. - name: "X-Registry-Config"
  4516. in: "header"
  4517. description: |
  4518. This is a base64-encoded JSON object with auth configurations for multiple registries that a build may refer to.
  4519. The key is a registry URL, and the value is an auth configuration object, [as described in the authentication section](#section/Authentication). For example:
  4520. ```
  4521. {
  4522. "docker.example.com": {
  4523. "username": "janedoe",
  4524. "password": "hunter2"
  4525. },
  4526. "https://index.docker.io/v1/": {
  4527. "username": "mobydock",
  4528. "password": "conta1n3rize14"
  4529. }
  4530. }
  4531. ```
  4532. 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.
  4533. type: "string"
  4534. responses:
  4535. 200:
  4536. description: "no error"
  4537. 400:
  4538. description: "Bad parameter"
  4539. schema:
  4540. $ref: "#/definitions/ErrorResponse"
  4541. 500:
  4542. description: "server error"
  4543. schema:
  4544. $ref: "#/definitions/ErrorResponse"
  4545. tags: ["Image"]
  4546. /images/create:
  4547. post:
  4548. summary: "Create an image"
  4549. description: "Create an image by either pulling it from a registry or importing it."
  4550. operationId: "ImageCreate"
  4551. consumes:
  4552. - "text/plain"
  4553. - "application/octet-stream"
  4554. produces:
  4555. - "application/json"
  4556. responses:
  4557. 200:
  4558. description: "no error"
  4559. 404:
  4560. description: "repository does not exist or no read access"
  4561. schema:
  4562. $ref: "#/definitions/ErrorResponse"
  4563. 500:
  4564. description: "server error"
  4565. schema:
  4566. $ref: "#/definitions/ErrorResponse"
  4567. parameters:
  4568. - name: "fromImage"
  4569. in: "query"
  4570. 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."
  4571. type: "string"
  4572. - name: "fromSrc"
  4573. in: "query"
  4574. 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."
  4575. type: "string"
  4576. - name: "repo"
  4577. in: "query"
  4578. 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."
  4579. type: "string"
  4580. - name: "tag"
  4581. in: "query"
  4582. description: "Tag or digest. If empty when pulling an image, this causes all tags for the given image to be pulled."
  4583. type: "string"
  4584. - name: "inputImage"
  4585. in: "body"
  4586. description: "Image content if the value `-` has been specified in fromSrc query parameter"
  4587. schema:
  4588. type: "string"
  4589. required: false
  4590. - name: "X-Registry-Auth"
  4591. in: "header"
  4592. description: "A base64-encoded auth configuration. [See the authentication section for details.](#section/Authentication)"
  4593. type: "string"
  4594. tags: ["Image"]
  4595. /images/{name}/json:
  4596. get:
  4597. summary: "Inspect an image"
  4598. description: "Return low-level information about an image."
  4599. operationId: "ImageInspect"
  4600. produces:
  4601. - "application/json"
  4602. responses:
  4603. 200:
  4604. description: "No error"
  4605. schema:
  4606. $ref: "#/definitions/Image"
  4607. examples:
  4608. application/json:
  4609. Id: "sha256:85f05633ddc1c50679be2b16a0479ab6f7637f8884e0cfe0f4d20e1ebb3d6e7c"
  4610. Container: "cb91e48a60d01f1e27028b4fc6819f4f290b3cf12496c8176ec714d0d390984a"
  4611. Comment: ""
  4612. Os: "linux"
  4613. Architecture: "amd64"
  4614. Parent: "sha256:91e54dfb11794fad694460162bf0cb0a4fa710cfa3f60979c177d920813e267c"
  4615. ContainerConfig:
  4616. Tty: false
  4617. Hostname: "e611e15f9c9d"
  4618. Domainname: ""
  4619. AttachStdout: false
  4620. PublishService: ""
  4621. AttachStdin: false
  4622. OpenStdin: false
  4623. StdinOnce: false
  4624. NetworkDisabled: false
  4625. OnBuild: []
  4626. Image: "91e54dfb11794fad694460162bf0cb0a4fa710cfa3f60979c177d920813e267c"
  4627. User: ""
  4628. WorkingDir: ""
  4629. MacAddress: ""
  4630. AttachStderr: false
  4631. Labels:
  4632. com.example.license: "GPL"
  4633. com.example.version: "1.0"
  4634. com.example.vendor: "Acme"
  4635. Env:
  4636. - "PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
  4637. Cmd:
  4638. - "/bin/sh"
  4639. - "-c"
  4640. - "#(nop) LABEL com.example.vendor=Acme com.example.license=GPL com.example.version=1.0"
  4641. DockerVersion: "1.9.0-dev"
  4642. VirtualSize: 188359297
  4643. Size: 0
  4644. Author: ""
  4645. Created: "2015-09-10T08:30:53.26995814Z"
  4646. GraphDriver:
  4647. Name: "aufs"
  4648. Data: {}
  4649. RepoDigests:
  4650. - "localhost:5000/test/busybox/example@sha256:cbbf2f9a99b47fc460d422812b6a5adff7dfee951d8fa2e4a98caa0382cfbdbf"
  4651. RepoTags:
  4652. - "example:1.0"
  4653. - "example:latest"
  4654. - "example:stable"
  4655. Config:
  4656. Image: "91e54dfb11794fad694460162bf0cb0a4fa710cfa3f60979c177d920813e267c"
  4657. NetworkDisabled: false
  4658. OnBuild: []
  4659. StdinOnce: false
  4660. PublishService: ""
  4661. AttachStdin: false
  4662. OpenStdin: false
  4663. Domainname: ""
  4664. AttachStdout: false
  4665. Tty: false
  4666. Hostname: "e611e15f9c9d"
  4667. Cmd:
  4668. - "/bin/bash"
  4669. Env:
  4670. - "PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
  4671. Labels:
  4672. com.example.vendor: "Acme"
  4673. com.example.version: "1.0"
  4674. com.example.license: "GPL"
  4675. MacAddress: ""
  4676. AttachStderr: false
  4677. WorkingDir: ""
  4678. User: ""
  4679. RootFS:
  4680. Type: "layers"
  4681. Layers:
  4682. - "sha256:1834950e52ce4d5a88a1bbd131c537f4d0e56d10ff0dd69e66be3b7dfa9df7e6"
  4683. - "sha256:5f70bf18a086007016e948b04aed3b82103a36bea41755b6cddfaf10ace3c6ef"
  4684. 404:
  4685. description: "No such image"
  4686. schema:
  4687. $ref: "#/definitions/ErrorResponse"
  4688. examples:
  4689. application/json:
  4690. message: "No such image: someimage (tag: latest)"
  4691. 500:
  4692. description: "Server error"
  4693. schema:
  4694. $ref: "#/definitions/ErrorResponse"
  4695. parameters:
  4696. - name: "name"
  4697. in: "path"
  4698. description: "Image name or id"
  4699. type: "string"
  4700. required: true
  4701. tags: ["Image"]
  4702. /images/{name}/history:
  4703. get:
  4704. summary: "Get the history of an image"
  4705. description: "Return parent layers of an image."
  4706. operationId: "ImageHistory"
  4707. produces: ["application/json"]
  4708. responses:
  4709. 200:
  4710. description: "List of image layers"
  4711. schema:
  4712. type: "array"
  4713. items:
  4714. type: "object"
  4715. x-go-name: HistoryResponseItem
  4716. required: [Id, Created, CreatedBy, Tags, Size, Comment]
  4717. properties:
  4718. Id:
  4719. type: "string"
  4720. x-nullable: false
  4721. Created:
  4722. type: "integer"
  4723. format: "int64"
  4724. x-nullable: false
  4725. CreatedBy:
  4726. type: "string"
  4727. x-nullable: false
  4728. Tags:
  4729. type: "array"
  4730. items:
  4731. type: "string"
  4732. Size:
  4733. type: "integer"
  4734. format: "int64"
  4735. x-nullable: false
  4736. Comment:
  4737. type: "string"
  4738. x-nullable: false
  4739. examples:
  4740. application/json:
  4741. - Id: "3db9c44f45209632d6050b35958829c3a2aa256d81b9a7be45b362ff85c54710"
  4742. Created: 1398108230
  4743. CreatedBy: "/bin/sh -c #(nop) ADD file:eb15dbd63394e063b805a3c32ca7bf0266ef64676d5a6fab4801f2e81e2a5148 in /"
  4744. Tags:
  4745. - "ubuntu:lucid"
  4746. - "ubuntu:10.04"
  4747. Size: 182964289
  4748. Comment: ""
  4749. - Id: "6cfa4d1f33fb861d4d114f43b25abd0ac737509268065cdfd69d544a59c85ab8"
  4750. Created: 1398108222
  4751. 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/"
  4752. Tags: []
  4753. Size: 0
  4754. Comment: ""
  4755. - Id: "511136ea3c5a64f264b78b5433614aec563103b4d4702f3ba7d4d2698e22c158"
  4756. Created: 1371157430
  4757. CreatedBy: ""
  4758. Tags:
  4759. - "scratch12:latest"
  4760. - "scratch:latest"
  4761. Size: 0
  4762. Comment: "Imported from -"
  4763. 404:
  4764. description: "No such image"
  4765. schema:
  4766. $ref: "#/definitions/ErrorResponse"
  4767. 500:
  4768. description: "Server error"
  4769. schema:
  4770. $ref: "#/definitions/ErrorResponse"
  4771. parameters:
  4772. - name: "name"
  4773. in: "path"
  4774. description: "Image name or ID"
  4775. type: "string"
  4776. required: true
  4777. tags: ["Image"]
  4778. /images/{name}/push:
  4779. post:
  4780. summary: "Push an image"
  4781. description: |
  4782. Push an image to a registry.
  4783. If you wish to push an image on to a private registry, that image must already have a tag which references the registry. For example, `registry.example.com/myimage:latest`.
  4784. The push is cancelled if the HTTP connection is closed.
  4785. operationId: "ImagePush"
  4786. consumes:
  4787. - "application/octet-stream"
  4788. responses:
  4789. 200:
  4790. description: "No error"
  4791. 404:
  4792. description: "No such image"
  4793. schema:
  4794. $ref: "#/definitions/ErrorResponse"
  4795. 500:
  4796. description: "Server error"
  4797. schema:
  4798. $ref: "#/definitions/ErrorResponse"
  4799. parameters:
  4800. - name: "name"
  4801. in: "path"
  4802. description: "Image name or ID."
  4803. type: "string"
  4804. required: true
  4805. - name: "tag"
  4806. in: "query"
  4807. description: "The tag to associate with the image on the registry."
  4808. type: "string"
  4809. - name: "X-Registry-Auth"
  4810. in: "header"
  4811. description: "A base64-encoded auth configuration. [See the authentication section for details.](#section/Authentication)"
  4812. type: "string"
  4813. required: true
  4814. tags: ["Image"]
  4815. /images/{name}/tag:
  4816. post:
  4817. summary: "Tag an image"
  4818. description: "Tag an image so that it becomes part of a repository."
  4819. operationId: "ImageTag"
  4820. responses:
  4821. 201:
  4822. description: "No error"
  4823. 400:
  4824. description: "Bad parameter"
  4825. schema:
  4826. $ref: "#/definitions/ErrorResponse"
  4827. 404:
  4828. description: "No such image"
  4829. schema:
  4830. $ref: "#/definitions/ErrorResponse"
  4831. 409:
  4832. description: "Conflict"
  4833. schema:
  4834. $ref: "#/definitions/ErrorResponse"
  4835. 500:
  4836. description: "Server error"
  4837. schema:
  4838. $ref: "#/definitions/ErrorResponse"
  4839. parameters:
  4840. - name: "name"
  4841. in: "path"
  4842. description: "Image name or ID to tag."
  4843. type: "string"
  4844. required: true
  4845. - name: "repo"
  4846. in: "query"
  4847. description: "The repository to tag in. For example, `someuser/someimage`."
  4848. type: "string"
  4849. - name: "tag"
  4850. in: "query"
  4851. description: "The name of the new tag."
  4852. type: "string"
  4853. tags: ["Image"]
  4854. /images/{name}:
  4855. delete:
  4856. summary: "Remove an image"
  4857. description: |
  4858. Remove an image, along with any untagged parent images that were
  4859. referenced by that image.
  4860. Images can't be removed if they have descendant images, are being
  4861. used by a running container or are being used by a build.
  4862. operationId: "ImageDelete"
  4863. produces: ["application/json"]
  4864. responses:
  4865. 200:
  4866. description: "The image was deleted successfully"
  4867. schema:
  4868. type: "array"
  4869. items:
  4870. $ref: "#/definitions/ImageDeleteResponseItem"
  4871. examples:
  4872. application/json:
  4873. - Untagged: "3e2f21a89f"
  4874. - Deleted: "3e2f21a89f"
  4875. - Deleted: "53b4f83ac9"
  4876. 404:
  4877. description: "No such image"
  4878. schema:
  4879. $ref: "#/definitions/ErrorResponse"
  4880. 409:
  4881. description: "Conflict"
  4882. schema:
  4883. $ref: "#/definitions/ErrorResponse"
  4884. 500:
  4885. description: "Server error"
  4886. schema:
  4887. $ref: "#/definitions/ErrorResponse"
  4888. parameters:
  4889. - name: "name"
  4890. in: "path"
  4891. description: "Image name or ID"
  4892. type: "string"
  4893. required: true
  4894. - name: "force"
  4895. in: "query"
  4896. description: "Remove the image even if it is being used by stopped containers or has other tags"
  4897. type: "boolean"
  4898. default: false
  4899. - name: "noprune"
  4900. in: "query"
  4901. description: "Do not delete untagged parent images"
  4902. type: "boolean"
  4903. default: false
  4904. tags: ["Image"]
  4905. /images/search:
  4906. get:
  4907. summary: "Search images"
  4908. description: "Search for an image on Docker Hub."
  4909. operationId: "ImageSearch"
  4910. produces:
  4911. - "application/json"
  4912. responses:
  4913. 200:
  4914. description: "No error"
  4915. schema:
  4916. type: "array"
  4917. items:
  4918. type: "object"
  4919. properties:
  4920. description:
  4921. type: "string"
  4922. is_official:
  4923. type: "boolean"
  4924. is_automated:
  4925. type: "boolean"
  4926. name:
  4927. type: "string"
  4928. star_count:
  4929. type: "integer"
  4930. examples:
  4931. application/json:
  4932. - description: ""
  4933. is_official: false
  4934. is_automated: false
  4935. name: "wma55/u1210sshd"
  4936. star_count: 0
  4937. - description: ""
  4938. is_official: false
  4939. is_automated: false
  4940. name: "jdswinbank/sshd"
  4941. star_count: 0
  4942. - description: ""
  4943. is_official: false
  4944. is_automated: false
  4945. name: "vgauthier/sshd"
  4946. star_count: 0
  4947. 500:
  4948. description: "Server error"
  4949. schema:
  4950. $ref: "#/definitions/ErrorResponse"
  4951. parameters:
  4952. - name: "term"
  4953. in: "query"
  4954. description: "Term to search"
  4955. type: "string"
  4956. required: true
  4957. - name: "limit"
  4958. in: "query"
  4959. description: "Maximum number of results to return"
  4960. type: "integer"
  4961. - name: "filters"
  4962. in: "query"
  4963. description: |
  4964. A JSON encoded value of the filters (a `map[string][]string`) to process on the images list. Available filters:
  4965. - `is-automated=(true|false)`
  4966. - `is-official=(true|false)`
  4967. - `stars=<number>` Matches images that has at least 'number' stars.
  4968. type: "string"
  4969. tags: ["Image"]
  4970. /images/prune:
  4971. post:
  4972. summary: "Delete unused images"
  4973. produces:
  4974. - "application/json"
  4975. operationId: "ImagePrune"
  4976. parameters:
  4977. - name: "filters"
  4978. in: "query"
  4979. description: |
  4980. Filters to process on the prune list, encoded as JSON (a `map[string][]string`). Available filters:
  4981. - `dangling=<boolean>` When set to `true` (or `1`), prune only
  4982. unused *and* untagged images. When set to `false`
  4983. (or `0`), all unused images are pruned.
  4984. - `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.
  4985. type: "string"
  4986. responses:
  4987. 200:
  4988. description: "No error"
  4989. schema:
  4990. type: "object"
  4991. properties:
  4992. ImagesDeleted:
  4993. description: "Images that were deleted"
  4994. type: "array"
  4995. items:
  4996. $ref: "#/definitions/ImageDeleteResponseItem"
  4997. SpaceReclaimed:
  4998. description: "Disk space reclaimed in bytes"
  4999. type: "integer"
  5000. format: "int64"
  5001. 500:
  5002. description: "Server error"
  5003. schema:
  5004. $ref: "#/definitions/ErrorResponse"
  5005. tags: ["Image"]
  5006. /auth:
  5007. post:
  5008. summary: "Check auth configuration"
  5009. description: "Validate credentials for a registry and, if available, get an identity token for accessing the registry without password."
  5010. operationId: "SystemAuth"
  5011. consumes: ["application/json"]
  5012. produces: ["application/json"]
  5013. responses:
  5014. 200:
  5015. description: "An identity token was generated successfully."
  5016. schema:
  5017. type: "object"
  5018. required: [Status]
  5019. properties:
  5020. Status:
  5021. description: "The status of the authentication"
  5022. type: "string"
  5023. x-nullable: false
  5024. IdentityToken:
  5025. description: "An opaque token used to authenticate a user after a successful login"
  5026. type: "string"
  5027. x-nullable: false
  5028. examples:
  5029. application/json:
  5030. Status: "Login Succeeded"
  5031. IdentityToken: "9cbaf023786cd7..."
  5032. 204:
  5033. description: "No error"
  5034. 500:
  5035. description: "Server error"
  5036. schema:
  5037. $ref: "#/definitions/ErrorResponse"
  5038. parameters:
  5039. - name: "authConfig"
  5040. in: "body"
  5041. description: "Authentication to check"
  5042. schema:
  5043. $ref: "#/definitions/AuthConfig"
  5044. tags: ["System"]
  5045. /info:
  5046. get:
  5047. summary: "Get system information"
  5048. operationId: "SystemInfo"
  5049. produces:
  5050. - "application/json"
  5051. responses:
  5052. 200:
  5053. description: "No error"
  5054. schema:
  5055. type: "object"
  5056. properties:
  5057. Architecture:
  5058. type: "string"
  5059. Containers:
  5060. type: "integer"
  5061. ContainersRunning:
  5062. type: "integer"
  5063. ContainersStopped:
  5064. type: "integer"
  5065. ContainersPaused:
  5066. type: "integer"
  5067. CpuCfsPeriod:
  5068. type: "boolean"
  5069. CpuCfsQuota:
  5070. type: "boolean"
  5071. Debug:
  5072. type: "boolean"
  5073. DiscoveryBackend:
  5074. type: "string"
  5075. DockerRootDir:
  5076. type: "string"
  5077. Driver:
  5078. type: "string"
  5079. DriverStatus:
  5080. type: "array"
  5081. items:
  5082. type: "array"
  5083. items:
  5084. type: "string"
  5085. SystemStatus:
  5086. type: "array"
  5087. items:
  5088. type: "array"
  5089. items:
  5090. type: "string"
  5091. Plugins:
  5092. type: "object"
  5093. properties:
  5094. Volume:
  5095. type: "array"
  5096. items:
  5097. type: "string"
  5098. Network:
  5099. type: "array"
  5100. items:
  5101. type: "string"
  5102. ExperimentalBuild:
  5103. type: "boolean"
  5104. HttpProxy:
  5105. type: "string"
  5106. HttpsProxy:
  5107. type: "string"
  5108. ID:
  5109. type: "string"
  5110. IPv4Forwarding:
  5111. type: "boolean"
  5112. Images:
  5113. type: "integer"
  5114. IndexServerAddress:
  5115. type: "string"
  5116. InitPath:
  5117. type: "string"
  5118. InitSha1:
  5119. type: "string"
  5120. KernelVersion:
  5121. type: "string"
  5122. Labels:
  5123. type: "array"
  5124. items:
  5125. type: "string"
  5126. MemTotal:
  5127. type: "integer"
  5128. MemoryLimit:
  5129. type: "boolean"
  5130. NCPU:
  5131. type: "integer"
  5132. NEventsListener:
  5133. type: "integer"
  5134. NFd:
  5135. type: "integer"
  5136. NGoroutines:
  5137. type: "integer"
  5138. Name:
  5139. type: "string"
  5140. NoProxy:
  5141. type: "string"
  5142. OomKillDisable:
  5143. type: "boolean"
  5144. OSType:
  5145. type: "string"
  5146. OomScoreAdj:
  5147. type: "integer"
  5148. OperatingSystem:
  5149. type: "string"
  5150. RegistryConfig:
  5151. type: "object"
  5152. properties:
  5153. IndexConfigs:
  5154. type: "object"
  5155. additionalProperties:
  5156. type: "object"
  5157. properties:
  5158. Mirrors:
  5159. type: "array"
  5160. items:
  5161. type: "string"
  5162. Name:
  5163. type: "string"
  5164. Official:
  5165. type: "boolean"
  5166. Secure:
  5167. type: "boolean"
  5168. InsecureRegistryCIDRs:
  5169. type: "array"
  5170. items:
  5171. type: "string"
  5172. SwapLimit:
  5173. type: "boolean"
  5174. SystemTime:
  5175. type: "string"
  5176. ServerVersion:
  5177. type: "string"
  5178. examples:
  5179. application/json:
  5180. Architecture: "x86_64"
  5181. ClusterStore: "etcd://localhost:2379"
  5182. CgroupDriver: "cgroupfs"
  5183. Containers: 11
  5184. ContainersRunning: 7
  5185. ContainersStopped: 3
  5186. ContainersPaused: 1
  5187. CpuCfsPeriod: true
  5188. CpuCfsQuota: true
  5189. Debug: false
  5190. DockerRootDir: "/var/lib/docker"
  5191. Driver: "btrfs"
  5192. DriverStatus:
  5193. -
  5194. - ""
  5195. ExperimentalBuild: false
  5196. HttpProxy: "http://test:test@localhost:8080"
  5197. HttpsProxy: "https://test:test@localhost:8080"
  5198. ID: "7TRN:IPZB:QYBB:VPBQ:UMPP:KARE:6ZNR:XE6T:7EWV:PKF4:ZOJD:TPYS"
  5199. IPv4Forwarding: true
  5200. Images: 16
  5201. IndexServerAddress: "https://index.docker.io/v1/"
  5202. InitPath: "/usr/bin/docker"
  5203. InitSha1: ""
  5204. KernelMemory: true
  5205. KernelVersion: "3.12.0-1-amd64"
  5206. Labels:
  5207. - "storage=ssd"
  5208. MemTotal: 2099236864
  5209. MemoryLimit: true
  5210. NCPU: 1
  5211. NEventsListener: 0
  5212. NFd: 11
  5213. NGoroutines: 21
  5214. Name: "prod-server-42"
  5215. NoProxy: "9.81.1.160"
  5216. OomKillDisable: true
  5217. OSType: "linux"
  5218. OperatingSystem: "Boot2Docker"
  5219. Plugins:
  5220. Volume:
  5221. - "local"
  5222. Network:
  5223. - "null"
  5224. - "host"
  5225. - "bridge"
  5226. RegistryConfig:
  5227. IndexConfigs:
  5228. docker.io:
  5229. Name: "docker.io"
  5230. Official: true
  5231. Secure: true
  5232. InsecureRegistryCIDRs:
  5233. - "127.0.0.0/8"
  5234. SecurityOptions:
  5235. - Key: "Name"
  5236. Value: "seccomp"
  5237. - Key: "Profile"
  5238. Value: "default"
  5239. - Key: "Name"
  5240. Value: "apparmor"
  5241. - Key: "Name"
  5242. Value: "selinux"
  5243. - Key: "Name"
  5244. Value: "userns"
  5245. ServerVersion: "1.9.0"
  5246. SwapLimit: false
  5247. SystemStatus:
  5248. -
  5249. - "State"
  5250. - "Healthy"
  5251. SystemTime: "2015-03-10T11:11:23.730591467-07:00"
  5252. 500:
  5253. description: "Server error"
  5254. schema:
  5255. $ref: "#/definitions/ErrorResponse"
  5256. tags: ["System"]
  5257. /version:
  5258. get:
  5259. summary: "Get version"
  5260. description: "Returns the version of Docker that is running and various information about the system that Docker is running on."
  5261. operationId: "SystemVersion"
  5262. produces: ["application/json"]
  5263. responses:
  5264. 200:
  5265. description: "no error"
  5266. schema:
  5267. type: "object"
  5268. properties:
  5269. Version:
  5270. type: "string"
  5271. ApiVersion:
  5272. type: "string"
  5273. MinAPIVersion:
  5274. type: "string"
  5275. GitCommit:
  5276. type: "string"
  5277. GoVersion:
  5278. type: "string"
  5279. Os:
  5280. type: "string"
  5281. Arch:
  5282. type: "string"
  5283. KernelVersion:
  5284. type: "string"
  5285. Experimental:
  5286. type: "boolean"
  5287. BuildTime:
  5288. type: "string"
  5289. examples:
  5290. application/json:
  5291. Version: "17.04.0"
  5292. Os: "linux"
  5293. KernelVersion: "3.19.0-23-generic"
  5294. GoVersion: "go1.7.5"
  5295. GitCommit: "deadbee"
  5296. Arch: "amd64"
  5297. ApiVersion: "1.27"
  5298. MinAPIVersion: "1.12"
  5299. BuildTime: "2016-06-14T07:09:13.444803460+00:00"
  5300. Experimental: true
  5301. 500:
  5302. description: "server error"
  5303. schema:
  5304. $ref: "#/definitions/ErrorResponse"
  5305. tags: ["System"]
  5306. /_ping:
  5307. get:
  5308. summary: "Ping"
  5309. description: "This is a dummy endpoint you can use to test if the server is accessible."
  5310. operationId: "SystemPing"
  5311. produces: ["text/plain"]
  5312. responses:
  5313. 200:
  5314. description: "no error"
  5315. schema:
  5316. type: "string"
  5317. example: "OK"
  5318. headers:
  5319. API-Version:
  5320. type: "string"
  5321. description: "Max API Version the server supports"
  5322. Docker-Experimental:
  5323. type: "boolean"
  5324. description: "If the server is running with experimental mode enabled"
  5325. 500:
  5326. description: "server error"
  5327. schema:
  5328. $ref: "#/definitions/ErrorResponse"
  5329. tags: ["System"]
  5330. /commit:
  5331. post:
  5332. summary: "Create a new image from a container"
  5333. operationId: "ImageCommit"
  5334. consumes:
  5335. - "application/json"
  5336. produces:
  5337. - "application/json"
  5338. responses:
  5339. 201:
  5340. description: "no error"
  5341. schema:
  5342. $ref: "#/definitions/IdResponse"
  5343. 404:
  5344. description: "no such container"
  5345. schema:
  5346. $ref: "#/definitions/ErrorResponse"
  5347. examples:
  5348. application/json:
  5349. message: "No such container: c2ada9df5af8"
  5350. 500:
  5351. description: "server error"
  5352. schema:
  5353. $ref: "#/definitions/ErrorResponse"
  5354. parameters:
  5355. - name: "containerConfig"
  5356. in: "body"
  5357. description: "The container configuration"
  5358. schema:
  5359. $ref: "#/definitions/Config"
  5360. - name: "container"
  5361. in: "query"
  5362. description: "The ID or name of the container to commit"
  5363. type: "string"
  5364. - name: "repo"
  5365. in: "query"
  5366. description: "Repository name for the created image"
  5367. type: "string"
  5368. - name: "tag"
  5369. in: "query"
  5370. description: "Tag name for the create image"
  5371. type: "string"
  5372. - name: "comment"
  5373. in: "query"
  5374. description: "Commit message"
  5375. type: "string"
  5376. - name: "author"
  5377. in: "query"
  5378. description: "Author of the image (e.g., `John Hannibal Smith <hannibal@a-team.com>`)"
  5379. type: "string"
  5380. - name: "pause"
  5381. in: "query"
  5382. description: "Whether to pause the container before committing"
  5383. type: "boolean"
  5384. default: true
  5385. - name: "changes"
  5386. in: "query"
  5387. description: "`Dockerfile` instructions to apply while committing"
  5388. type: "string"
  5389. tags: ["Image"]
  5390. /events:
  5391. get:
  5392. summary: "Monitor events"
  5393. description: |
  5394. Stream real-time events from the server.
  5395. Various objects within Docker report events when something happens to them.
  5396. Containers report these events: `attach, commit, copy, create, destroy, detach, die, exec_create, exec_detach, exec_start, export, health_status, kill, oom, pause, rename, resize, restart, start, stop, top, unpause, update`
  5397. Images report these events: `delete, import, load, pull, push, save, tag, untag`
  5398. Volumes report these events: `create, mount, unmount, destroy`
  5399. Networks report these events: `create, connect, disconnect, destroy`
  5400. The Docker daemon reports these events: `reload`
  5401. operationId: "SystemEvents"
  5402. produces:
  5403. - "application/json"
  5404. responses:
  5405. 200:
  5406. description: "no error"
  5407. schema:
  5408. type: "object"
  5409. properties:
  5410. Type:
  5411. description: "The type of object emitting the event"
  5412. type: "string"
  5413. Action:
  5414. description: "The type of event"
  5415. type: "string"
  5416. Actor:
  5417. type: "object"
  5418. properties:
  5419. ID:
  5420. description: "The ID of the object emitting the event"
  5421. type: "string"
  5422. Attributes:
  5423. description: "Various key/value attributes of the object, depending on its type"
  5424. type: "object"
  5425. additionalProperties:
  5426. type: "string"
  5427. time:
  5428. description: "Timestamp of event"
  5429. type: "integer"
  5430. timeNano:
  5431. description: "Timestamp of event, with nanosecond accuracy"
  5432. type: "integer"
  5433. format: "int64"
  5434. examples:
  5435. application/json:
  5436. Type: "container"
  5437. Action: "create"
  5438. Actor:
  5439. ID: "ede54ee1afda366ab42f824e8a5ffd195155d853ceaec74a927f249ea270c743"
  5440. Attributes:
  5441. com.example.some-label: "some-label-value"
  5442. image: "alpine"
  5443. name: "my-container"
  5444. time: 1461943101
  5445. 400:
  5446. description: "bad parameter"
  5447. schema:
  5448. $ref: "#/definitions/ErrorResponse"
  5449. 500:
  5450. description: "server error"
  5451. schema:
  5452. $ref: "#/definitions/ErrorResponse"
  5453. parameters:
  5454. - name: "since"
  5455. in: "query"
  5456. description: "Show events created since this timestamp then stream new events."
  5457. type: "string"
  5458. - name: "until"
  5459. in: "query"
  5460. description: "Show events created until this timestamp then stop streaming."
  5461. type: "string"
  5462. - name: "filters"
  5463. in: "query"
  5464. description: |
  5465. A JSON encoded value of filters (a `map[string][]string`) to process on the event list. Available filters:
  5466. - `container=<string>` container name or ID
  5467. - `daemon=<string>` daemon name or ID
  5468. - `event=<string>` event type
  5469. - `image=<string>` image name or ID
  5470. - `label=<string>` image or container label
  5471. - `network=<string>` network name or ID
  5472. - `plugin`=<string> plugin name or ID
  5473. - `type=<string>` object to filter by, one of `container`, `image`, `volume`, `network`, or `daemon`
  5474. - `volume=<string>` volume name or ID
  5475. type: "string"
  5476. tags: ["System"]
  5477. /system/df:
  5478. get:
  5479. summary: "Get data usage information"
  5480. operationId: "SystemDataUsage"
  5481. responses:
  5482. 200:
  5483. description: "no error"
  5484. schema:
  5485. type: "object"
  5486. properties:
  5487. LayersSize:
  5488. type: "integer"
  5489. format: "int64"
  5490. Images:
  5491. type: "array"
  5492. items:
  5493. $ref: "#/definitions/ImageSummary"
  5494. Containers:
  5495. type: "array"
  5496. items:
  5497. $ref: "#/definitions/ContainerSummary"
  5498. Volumes:
  5499. type: "array"
  5500. items:
  5501. $ref: "#/definitions/Volume"
  5502. example:
  5503. LayersSize: 1092588
  5504. Images:
  5505. -
  5506. Id: "sha256:2b8fd9751c4c0f5dd266fcae00707e67a2545ef34f9a29354585f93dac906749"
  5507. ParentId: ""
  5508. RepoTags:
  5509. - "busybox:latest"
  5510. RepoDigests:
  5511. - "busybox@sha256:a59906e33509d14c036c8678d687bd4eec81ed7c4b8ce907b888c607f6a1e0e6"
  5512. Created: 1466724217
  5513. Size: 1092588
  5514. SharedSize: 0
  5515. VirtualSize: 1092588
  5516. Labels: {}
  5517. Containers: 1
  5518. Containers:
  5519. -
  5520. Id: "e575172ed11dc01bfce087fb27bee502db149e1a0fad7c296ad300bbff178148"
  5521. Names:
  5522. - "/top"
  5523. Image: "busybox"
  5524. ImageID: "sha256:2b8fd9751c4c0f5dd266fcae00707e67a2545ef34f9a29354585f93dac906749"
  5525. Command: "top"
  5526. Created: 1472592424
  5527. Ports: []
  5528. SizeRootFs: 1092588
  5529. Labels: {}
  5530. State: "exited"
  5531. Status: "Exited (0) 56 minutes ago"
  5532. HostConfig:
  5533. NetworkMode: "default"
  5534. NetworkSettings:
  5535. Networks:
  5536. bridge:
  5537. IPAMConfig: null
  5538. Links: null
  5539. Aliases: null
  5540. NetworkID: "d687bc59335f0e5c9ee8193e5612e8aee000c8c62ea170cfb99c098f95899d92"
  5541. EndpointID: "8ed5115aeaad9abb174f68dcf135b49f11daf597678315231a32ca28441dec6a"
  5542. Gateway: "172.18.0.1"
  5543. IPAddress: "172.18.0.2"
  5544. IPPrefixLen: 16
  5545. IPv6Gateway: ""
  5546. GlobalIPv6Address: ""
  5547. GlobalIPv6PrefixLen: 0
  5548. MacAddress: "02:42:ac:12:00:02"
  5549. Mounts: []
  5550. Volumes:
  5551. -
  5552. Name: "my-volume"
  5553. Driver: "local"
  5554. Mountpoint: ""
  5555. Labels: null
  5556. Scope: ""
  5557. Options: null
  5558. UsageData:
  5559. Size: 0
  5560. RefCount: 0
  5561. 500:
  5562. description: "server error"
  5563. schema:
  5564. $ref: "#/definitions/ErrorResponse"
  5565. tags: ["System"]
  5566. /images/{name}/get:
  5567. get:
  5568. summary: "Export an image"
  5569. description: |
  5570. Get a tarball containing all images and metadata for a repository.
  5571. 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.
  5572. ### Image tarball format
  5573. An image tarball contains one directory per image layer (named using its long ID), each containing these files:
  5574. - `VERSION`: currently `1.0` - the file format version
  5575. - `json`: detailed layer information, similar to `docker inspect layer_id`
  5576. - `layer.tar`: A tarfile containing the filesystem changes in this layer
  5577. The `layer.tar` file contains `aufs` style `.wh..wh.aufs` files and directories for storing attribute changes and deletions.
  5578. 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.
  5579. ```json
  5580. {
  5581. "hello-world": {
  5582. "latest": "565a9d68a73f6706862bfe8409a7f659776d4d60a8d096eb4a3cbce6999cc2a1"
  5583. }
  5584. }
  5585. ```
  5586. operationId: "ImageGet"
  5587. produces:
  5588. - "application/x-tar"
  5589. responses:
  5590. 200:
  5591. description: "no error"
  5592. schema:
  5593. type: "string"
  5594. format: "binary"
  5595. 500:
  5596. description: "server error"
  5597. schema:
  5598. $ref: "#/definitions/ErrorResponse"
  5599. parameters:
  5600. - name: "name"
  5601. in: "path"
  5602. description: "Image name or ID"
  5603. type: "string"
  5604. required: true
  5605. tags: ["Image"]
  5606. /images/get:
  5607. get:
  5608. summary: "Export several images"
  5609. description: |
  5610. Get a tarball containing all images and metadata for several image repositories.
  5611. For each value of the `names` parameter: if it is a specific name and tag (e.g. `ubuntu:latest`), then only that image (and its parents) are returned; if it is an image ID, similarly only that image (and its parents) are returned and there would be no names referenced in the 'repositories' file for this image ID.
  5612. For details on the format, see [the export image endpoint](#operation/ImageGet).
  5613. operationId: "ImageGetAll"
  5614. produces:
  5615. - "application/x-tar"
  5616. responses:
  5617. 200:
  5618. description: "no error"
  5619. schema:
  5620. type: "string"
  5621. format: "binary"
  5622. 500:
  5623. description: "server error"
  5624. schema:
  5625. $ref: "#/definitions/ErrorResponse"
  5626. parameters:
  5627. - name: "names"
  5628. in: "query"
  5629. description: "Image names to filter by"
  5630. type: "array"
  5631. items:
  5632. type: "string"
  5633. tags: ["Image"]
  5634. /images/load:
  5635. post:
  5636. summary: "Import images"
  5637. description: |
  5638. Load a set of images and tags into a repository.
  5639. For details on the format, see [the export image endpoint](#operation/ImageGet).
  5640. operationId: "ImageLoad"
  5641. consumes:
  5642. - "application/x-tar"
  5643. produces:
  5644. - "application/json"
  5645. responses:
  5646. 200:
  5647. description: "no error"
  5648. 500:
  5649. description: "server error"
  5650. schema:
  5651. $ref: "#/definitions/ErrorResponse"
  5652. parameters:
  5653. - name: "imagesTarball"
  5654. in: "body"
  5655. description: "Tar archive containing images"
  5656. schema:
  5657. type: "string"
  5658. format: "binary"
  5659. - name: "quiet"
  5660. in: "query"
  5661. description: "Suppress progress details during load."
  5662. type: "boolean"
  5663. default: false
  5664. tags: ["Image"]
  5665. /containers/{id}/exec:
  5666. post:
  5667. summary: "Create an exec instance"
  5668. description: "Run a command inside a running container."
  5669. operationId: "ContainerExec"
  5670. consumes:
  5671. - "application/json"
  5672. produces:
  5673. - "application/json"
  5674. responses:
  5675. 201:
  5676. description: "no error"
  5677. schema:
  5678. $ref: "#/definitions/IdResponse"
  5679. 404:
  5680. description: "no such container"
  5681. schema:
  5682. $ref: "#/definitions/ErrorResponse"
  5683. examples:
  5684. application/json:
  5685. message: "No such container: c2ada9df5af8"
  5686. 409:
  5687. description: "container is paused"
  5688. schema:
  5689. $ref: "#/definitions/ErrorResponse"
  5690. 500:
  5691. description: "Server error"
  5692. schema:
  5693. $ref: "#/definitions/ErrorResponse"
  5694. parameters:
  5695. - name: "execConfig"
  5696. in: "body"
  5697. description: "Exec configuration"
  5698. schema:
  5699. type: "object"
  5700. properties:
  5701. AttachStdin:
  5702. type: "boolean"
  5703. description: "Attach to `stdin` of the exec command."
  5704. AttachStdout:
  5705. type: "boolean"
  5706. description: "Attach to `stdout` of the exec command."
  5707. AttachStderr:
  5708. type: "boolean"
  5709. description: "Attach to `stderr` of the exec command."
  5710. DetachKeys:
  5711. type: "string"
  5712. description: "Override the key sequence for detaching a container. Format is a single character `[a-Z]` or `ctrl-<value>` where `<value>` is one of: `a-z`, `@`, `^`, `[`, `,` or `_`."
  5713. Tty:
  5714. type: "boolean"
  5715. description: "Allocate a pseudo-TTY."
  5716. Env:
  5717. description: "A list of environment variables in the form `[\"VAR=value\", ...]`."
  5718. type: "array"
  5719. items:
  5720. type: "string"
  5721. Cmd:
  5722. type: "array"
  5723. description: "Command to run, as a string or array of strings."
  5724. items:
  5725. type: "string"
  5726. Privileged:
  5727. type: "boolean"
  5728. description: "Runs the exec process with extended privileges."
  5729. default: false
  5730. User:
  5731. type: "string"
  5732. description: "The user, and optionally, group to run the exec process inside the container. Format is one of: `user`, `user:group`, `uid`, or `uid:gid`."
  5733. example:
  5734. AttachStdin: false
  5735. AttachStdout: true
  5736. AttachStderr: true
  5737. DetachKeys: "ctrl-p,ctrl-q"
  5738. Tty: false
  5739. Cmd:
  5740. - "date"
  5741. Env:
  5742. - "FOO=bar"
  5743. - "BAZ=quux"
  5744. required: true
  5745. - name: "id"
  5746. in: "path"
  5747. description: "ID or name of container"
  5748. type: "string"
  5749. required: true
  5750. tags: ["Exec"]
  5751. /exec/{id}/start:
  5752. post:
  5753. summary: "Start an exec instance"
  5754. description: "Starts a previously set up exec instance. If detach is true, this endpoint returns immediately after starting the command. Otherwise, it sets up an interactive session with the command."
  5755. operationId: "ExecStart"
  5756. consumes:
  5757. - "application/json"
  5758. produces:
  5759. - "application/vnd.docker.raw-stream"
  5760. responses:
  5761. 200:
  5762. description: "No error"
  5763. 404:
  5764. description: "No such exec instance"
  5765. schema:
  5766. $ref: "#/definitions/ErrorResponse"
  5767. 409:
  5768. description: "Container is stopped or paused"
  5769. schema:
  5770. $ref: "#/definitions/ErrorResponse"
  5771. parameters:
  5772. - name: "execStartConfig"
  5773. in: "body"
  5774. schema:
  5775. type: "object"
  5776. properties:
  5777. Detach:
  5778. type: "boolean"
  5779. description: "Detach from the command."
  5780. Tty:
  5781. type: "boolean"
  5782. description: "Allocate a pseudo-TTY."
  5783. example:
  5784. Detach: false
  5785. Tty: false
  5786. - name: "id"
  5787. in: "path"
  5788. description: "Exec instance ID"
  5789. required: true
  5790. type: "string"
  5791. tags: ["Exec"]
  5792. /exec/{id}/resize:
  5793. post:
  5794. summary: "Resize an exec instance"
  5795. description: "Resize the TTY session used by an exec instance. This endpoint only works if `tty` was specified as part of creating and starting the exec instance."
  5796. operationId: "ExecResize"
  5797. responses:
  5798. 200:
  5799. description: "No error"
  5800. 400:
  5801. description: "bad parameter"
  5802. schema:
  5803. $ref: "#/definitions/ErrorResponse"
  5804. 404:
  5805. description: "No such exec instance"
  5806. schema:
  5807. $ref: "#/definitions/ErrorResponse"
  5808. 500:
  5809. description: "Server error"
  5810. schema:
  5811. $ref: "#/definitions/ErrorResponse"
  5812. parameters:
  5813. - name: "id"
  5814. in: "path"
  5815. description: "Exec instance ID"
  5816. required: true
  5817. type: "string"
  5818. - name: "h"
  5819. in: "query"
  5820. description: "Height of the TTY session in characters"
  5821. type: "integer"
  5822. - name: "w"
  5823. in: "query"
  5824. description: "Width of the TTY session in characters"
  5825. type: "integer"
  5826. tags: ["Exec"]
  5827. /exec/{id}/json:
  5828. get:
  5829. summary: "Inspect an exec instance"
  5830. description: "Return low-level information about an exec instance."
  5831. operationId: "ExecInspect"
  5832. produces:
  5833. - "application/json"
  5834. responses:
  5835. 200:
  5836. description: "No error"
  5837. schema:
  5838. type: "object"
  5839. properties:
  5840. ID:
  5841. type: "string"
  5842. Running:
  5843. type: "boolean"
  5844. ExitCode:
  5845. type: "integer"
  5846. ProcessConfig:
  5847. $ref: "#/definitions/ProcessConfig"
  5848. OpenStdin:
  5849. type: "boolean"
  5850. OpenStderr:
  5851. type: "boolean"
  5852. OpenStdout:
  5853. type: "boolean"
  5854. ContainerID:
  5855. type: "string"
  5856. Pid:
  5857. type: "integer"
  5858. description: "The system process ID for the exec process."
  5859. examples:
  5860. application/json:
  5861. CanRemove: false
  5862. ContainerID: "b53ee82b53a40c7dca428523e34f741f3abc51d9f297a14ff874bf761b995126"
  5863. DetachKeys: ""
  5864. ExitCode: 2
  5865. ID: "f33bbfb39f5b142420f4759b2348913bd4a8d1a6d7fd56499cb41a1bb91d7b3b"
  5866. OpenStderr: true
  5867. OpenStdin: true
  5868. OpenStdout: true
  5869. ProcessConfig:
  5870. arguments:
  5871. - "-c"
  5872. - "exit 2"
  5873. entrypoint: "sh"
  5874. privileged: false
  5875. tty: true
  5876. user: "1000"
  5877. Running: false
  5878. Pid: 42000
  5879. 404:
  5880. description: "No such exec instance"
  5881. schema:
  5882. $ref: "#/definitions/ErrorResponse"
  5883. 500:
  5884. description: "Server error"
  5885. schema:
  5886. $ref: "#/definitions/ErrorResponse"
  5887. parameters:
  5888. - name: "id"
  5889. in: "path"
  5890. description: "Exec instance ID"
  5891. required: true
  5892. type: "string"
  5893. tags: ["Exec"]
  5894. /volumes:
  5895. get:
  5896. summary: "List volumes"
  5897. operationId: "VolumeList"
  5898. produces: ["application/json"]
  5899. responses:
  5900. 200:
  5901. description: "Summary volume data that matches the query"
  5902. schema:
  5903. type: "object"
  5904. required: [Volumes, Warnings]
  5905. properties:
  5906. Volumes:
  5907. type: "array"
  5908. x-nullable: false
  5909. description: "List of volumes"
  5910. items:
  5911. $ref: "#/definitions/Volume"
  5912. Warnings:
  5913. type: "array"
  5914. x-nullable: false
  5915. description: "Warnings that occurred when fetching the list of volumes"
  5916. items:
  5917. type: "string"
  5918. examples:
  5919. application/json:
  5920. Volumes:
  5921. - Name: "tardis"
  5922. Driver: "local"
  5923. Mountpoint: "/var/lib/docker/volumes/tardis"
  5924. Labels:
  5925. com.example.some-label: "some-value"
  5926. com.example.some-other-label: "some-other-value"
  5927. Scope: "local"
  5928. Options:
  5929. device: "tmpfs"
  5930. o: "size=100m,uid=1000"
  5931. type: "tmpfs"
  5932. Warnings: []
  5933. 500:
  5934. description: "Server error"
  5935. schema:
  5936. $ref: "#/definitions/ErrorResponse"
  5937. parameters:
  5938. - name: "filters"
  5939. in: "query"
  5940. description: |
  5941. JSON encoded value of the filters (a `map[string][]string`) to
  5942. process on the volumes list. Available filters:
  5943. - `dangling=<boolean>` When set to `true` (or `1`), returns all
  5944. volumes that are not in use by a container. When set to `false`
  5945. (or `0`), only volumes that are in use by one or more
  5946. containers are returned.
  5947. - `driver=<volume-driver-name>` Matches volumes based on their driver.
  5948. - `label=<key>` or `label=<key>:<value>` Matches volumes based on
  5949. the presence of a `label` alone or a `label` and a value.
  5950. - `name=<volume-name>` Matches all or part of a volume name.
  5951. type: "string"
  5952. format: "json"
  5953. tags: ["Volume"]
  5954. /volumes/create:
  5955. post:
  5956. summary: "Create a volume"
  5957. operationId: "VolumeCreate"
  5958. consumes: ["application/json"]
  5959. produces: ["application/json"]
  5960. responses:
  5961. 201:
  5962. description: "The volume was created successfully"
  5963. schema:
  5964. $ref: "#/definitions/Volume"
  5965. 500:
  5966. description: "Server error"
  5967. schema:
  5968. $ref: "#/definitions/ErrorResponse"
  5969. parameters:
  5970. - name: "volumeConfig"
  5971. in: "body"
  5972. required: true
  5973. description: "Volume configuration"
  5974. schema:
  5975. type: "object"
  5976. properties:
  5977. Name:
  5978. description: "The new volume's name. If not specified, Docker generates a name."
  5979. type: "string"
  5980. x-nullable: false
  5981. Driver:
  5982. description: "Name of the volume driver to use."
  5983. type: "string"
  5984. default: "local"
  5985. x-nullable: false
  5986. DriverOpts:
  5987. description: "A mapping of driver options and values. These options are passed directly to the driver and are driver specific."
  5988. type: "object"
  5989. additionalProperties:
  5990. type: "string"
  5991. Labels:
  5992. description: "User-defined key/value metadata."
  5993. type: "object"
  5994. additionalProperties:
  5995. type: "string"
  5996. example:
  5997. Name: "tardis"
  5998. Labels:
  5999. com.example.some-label: "some-value"
  6000. com.example.some-other-label: "some-other-value"
  6001. Driver: "custom"
  6002. tags: ["Volume"]
  6003. /volumes/{name}:
  6004. get:
  6005. summary: "Inspect a volume"
  6006. operationId: "VolumeInspect"
  6007. produces: ["application/json"]
  6008. responses:
  6009. 200:
  6010. description: "No error"
  6011. schema:
  6012. $ref: "#/definitions/Volume"
  6013. 404:
  6014. description: "No such volume"
  6015. schema:
  6016. $ref: "#/definitions/ErrorResponse"
  6017. 500:
  6018. description: "Server error"
  6019. schema:
  6020. $ref: "#/definitions/ErrorResponse"
  6021. parameters:
  6022. - name: "name"
  6023. in: "path"
  6024. required: true
  6025. description: "Volume name or ID"
  6026. type: "string"
  6027. tags: ["Volume"]
  6028. delete:
  6029. summary: "Remove a volume"
  6030. description: "Instruct the driver to remove the volume."
  6031. operationId: "VolumeDelete"
  6032. responses:
  6033. 204:
  6034. description: "The volume was removed"
  6035. 404:
  6036. description: "No such volume or volume driver"
  6037. schema:
  6038. $ref: "#/definitions/ErrorResponse"
  6039. 409:
  6040. description: "Volume is in use and cannot be removed"
  6041. schema:
  6042. $ref: "#/definitions/ErrorResponse"
  6043. 500:
  6044. description: "Server error"
  6045. schema:
  6046. $ref: "#/definitions/ErrorResponse"
  6047. parameters:
  6048. - name: "name"
  6049. in: "path"
  6050. required: true
  6051. description: "Volume name or ID"
  6052. type: "string"
  6053. - name: "force"
  6054. in: "query"
  6055. description: "Force the removal of the volume"
  6056. type: "boolean"
  6057. default: false
  6058. tags: ["Volume"]
  6059. /volumes/prune:
  6060. post:
  6061. summary: "Delete unused volumes"
  6062. produces:
  6063. - "application/json"
  6064. operationId: "VolumePrune"
  6065. parameters:
  6066. - name: "filters"
  6067. in: "query"
  6068. description: |
  6069. Filters to process on the prune list, encoded as JSON (a `map[string][]string`).
  6070. Available filters:
  6071. type: "string"
  6072. responses:
  6073. 200:
  6074. description: "No error"
  6075. schema:
  6076. type: "object"
  6077. properties:
  6078. VolumesDeleted:
  6079. description: "Volumes that were deleted"
  6080. type: "array"
  6081. items:
  6082. type: "string"
  6083. SpaceReclaimed:
  6084. description: "Disk space reclaimed in bytes"
  6085. type: "integer"
  6086. format: "int64"
  6087. 500:
  6088. description: "Server error"
  6089. schema:
  6090. $ref: "#/definitions/ErrorResponse"
  6091. tags: ["Volume"]
  6092. /networks:
  6093. get:
  6094. summary: "List networks"
  6095. operationId: "NetworkList"
  6096. produces:
  6097. - "application/json"
  6098. responses:
  6099. 200:
  6100. description: "No error"
  6101. schema:
  6102. type: "array"
  6103. items:
  6104. $ref: "#/definitions/Network"
  6105. examples:
  6106. application/json:
  6107. - Name: "bridge"
  6108. Id: "f2de39df4171b0dc801e8002d1d999b77256983dfc63041c0f34030aa3977566"
  6109. Created: "2016-10-19T06:21:00.416543526Z"
  6110. Scope: "local"
  6111. Driver: "bridge"
  6112. EnableIPv6: false
  6113. Internal: false
  6114. Attachable: false
  6115. Ingress: false
  6116. IPAM:
  6117. Driver: "default"
  6118. Config:
  6119. -
  6120. Subnet: "172.17.0.0/16"
  6121. Containers:
  6122. 39b69226f9d79f5634485fb236a23b2fe4e96a0a94128390a7fbbcc167065867:
  6123. EndpointID: "ed2419a97c1d9954d05b46e462e7002ea552f216e9b136b80a7db8d98b442eda"
  6124. MacAddress: "02:42:ac:11:00:02"
  6125. IPv4Address: "172.17.0.2/16"
  6126. IPv6Address: ""
  6127. Options:
  6128. com.docker.network.bridge.default_bridge: "true"
  6129. com.docker.network.bridge.enable_icc: "true"
  6130. com.docker.network.bridge.enable_ip_masquerade: "true"
  6131. com.docker.network.bridge.host_binding_ipv4: "0.0.0.0"
  6132. com.docker.network.bridge.name: "docker0"
  6133. com.docker.network.driver.mtu: "1500"
  6134. - Name: "none"
  6135. Id: "e086a3893b05ab69242d3c44e49483a3bbbd3a26b46baa8f61ab797c1088d794"
  6136. Created: "0001-01-01T00:00:00Z"
  6137. Scope: "local"
  6138. Driver: "null"
  6139. EnableIPv6: false
  6140. Internal: false
  6141. Attachable: false
  6142. Ingress: false
  6143. IPAM:
  6144. Driver: "default"
  6145. Config: []
  6146. Containers: {}
  6147. Options: {}
  6148. - Name: "host"
  6149. Id: "13e871235c677f196c4e1ecebb9dc733b9b2d2ab589e30c539efeda84a24215e"
  6150. Created: "0001-01-01T00:00:00Z"
  6151. Scope: "local"
  6152. Driver: "host"
  6153. EnableIPv6: false
  6154. Internal: false
  6155. Attachable: false
  6156. Ingress: false
  6157. IPAM:
  6158. Driver: "default"
  6159. Config: []
  6160. Containers: {}
  6161. Options: {}
  6162. 500:
  6163. description: "Server error"
  6164. schema:
  6165. $ref: "#/definitions/ErrorResponse"
  6166. parameters:
  6167. - name: "filters"
  6168. in: "query"
  6169. description: |
  6170. JSON encoded value of the filters (a `map[string][]string`) to process on the networks list. Available filters:
  6171. - `driver=<driver-name>` Matches a network's driver.
  6172. - `id=<network-id>` Matches all or part of a network ID.
  6173. - `label=<key>` or `label=<key>=<value>` of a network label.
  6174. - `name=<network-name>` Matches all or part of a network name.
  6175. - `scope=["swarm"|"global"|"local"]` Filters networks by scope (`swarm`, `global`, or `local`).
  6176. - `type=["custom"|"builtin"]` Filters networks by type. The `custom` keyword returns all user-defined networks.
  6177. type: "string"
  6178. tags: ["Network"]
  6179. /networks/{id}:
  6180. get:
  6181. summary: "Inspect a network"
  6182. operationId: "NetworkInspect"
  6183. produces:
  6184. - "application/json"
  6185. responses:
  6186. 200:
  6187. description: "No error"
  6188. schema:
  6189. $ref: "#/definitions/Network"
  6190. 404:
  6191. description: "Network not found"
  6192. schema:
  6193. $ref: "#/definitions/ErrorResponse"
  6194. parameters:
  6195. - name: "id"
  6196. in: "path"
  6197. description: "Network ID or name"
  6198. required: true
  6199. type: "string"
  6200. - name: "verbose"
  6201. in: "query"
  6202. description: "Detailed inspect output for troubleshooting"
  6203. type: "boolean"
  6204. default: false
  6205. tags: ["Network"]
  6206. delete:
  6207. summary: "Remove a network"
  6208. operationId: "NetworkDelete"
  6209. responses:
  6210. 204:
  6211. description: "No error"
  6212. 404:
  6213. description: "no such network"
  6214. schema:
  6215. $ref: "#/definitions/ErrorResponse"
  6216. 500:
  6217. description: "Server error"
  6218. schema:
  6219. $ref: "#/definitions/ErrorResponse"
  6220. parameters:
  6221. - name: "id"
  6222. in: "path"
  6223. description: "Network ID or name"
  6224. required: true
  6225. type: "string"
  6226. tags: ["Network"]
  6227. /networks/create:
  6228. post:
  6229. summary: "Create a network"
  6230. operationId: "NetworkCreate"
  6231. consumes:
  6232. - "application/json"
  6233. produces:
  6234. - "application/json"
  6235. responses:
  6236. 201:
  6237. description: "No error"
  6238. schema:
  6239. type: "object"
  6240. properties:
  6241. Id:
  6242. description: "The ID of the created network."
  6243. type: "string"
  6244. Warning:
  6245. type: "string"
  6246. example:
  6247. Id: "22be93d5babb089c5aab8dbc369042fad48ff791584ca2da2100db837a1c7c30"
  6248. Warning: ""
  6249. 400:
  6250. description: "bad parameter"
  6251. schema:
  6252. $ref: "#/definitions/ErrorResponse"
  6253. 403:
  6254. description: "operation not supported for pre-defined networks"
  6255. schema:
  6256. $ref: "#/definitions/ErrorResponse"
  6257. 404:
  6258. description: "plugin not found"
  6259. schema:
  6260. $ref: "#/definitions/ErrorResponse"
  6261. 500:
  6262. description: "Server error"
  6263. schema:
  6264. $ref: "#/definitions/ErrorResponse"
  6265. parameters:
  6266. - name: "networkConfig"
  6267. in: "body"
  6268. description: "Network configuration"
  6269. required: true
  6270. schema:
  6271. type: "object"
  6272. required: ["Name"]
  6273. properties:
  6274. Name:
  6275. description: "The network's name."
  6276. type: "string"
  6277. CheckDuplicate:
  6278. description: "Check for networks with duplicate names. Since Network is primarily keyed based on a random ID and not on the name, and network name is strictly a user-friendly alias to the network which is uniquely identified using ID, there is no guaranteed way to check for duplicates. CheckDuplicate is there to provide a best effort checking of any networks which has the same name but it is not guaranteed to catch all name collisions."
  6279. type: "boolean"
  6280. Driver:
  6281. description: "Name of the network driver plugin to use."
  6282. type: "string"
  6283. default: "bridge"
  6284. Internal:
  6285. description: "Restrict external access to the network."
  6286. type: "boolean"
  6287. Attachable:
  6288. description: "Globally scoped network is manually attachable by regular containers from workers in swarm mode."
  6289. type: "boolean"
  6290. Ingress:
  6291. description: "Ingress network is the network which provides the routing-mesh in swarm mode."
  6292. type: "boolean"
  6293. IPAM:
  6294. description: "Optional custom IP scheme for the network."
  6295. $ref: "#/definitions/IPAM"
  6296. EnableIPv6:
  6297. description: "Enable IPv6 on the network."
  6298. type: "boolean"
  6299. Options:
  6300. description: "Network specific options to be used by the drivers."
  6301. type: "object"
  6302. additionalProperties:
  6303. type: "string"
  6304. Labels:
  6305. description: "User-defined key/value metadata."
  6306. type: "object"
  6307. additionalProperties:
  6308. type: "string"
  6309. example:
  6310. Name: "isolated_nw"
  6311. CheckDuplicate: false
  6312. Driver: "bridge"
  6313. EnableIPv6: true
  6314. IPAM:
  6315. Driver: "default"
  6316. Config:
  6317. - Subnet: "172.20.0.0/16"
  6318. IPRange: "172.20.10.0/24"
  6319. Gateway: "172.20.10.11"
  6320. - Subnet: "2001:db8:abcd::/64"
  6321. Gateway: "2001:db8:abcd::1011"
  6322. Options:
  6323. foo: "bar"
  6324. Internal: true
  6325. Attachable: false
  6326. Ingress: false
  6327. Options:
  6328. com.docker.network.bridge.default_bridge: "true"
  6329. com.docker.network.bridge.enable_icc: "true"
  6330. com.docker.network.bridge.enable_ip_masquerade: "true"
  6331. com.docker.network.bridge.host_binding_ipv4: "0.0.0.0"
  6332. com.docker.network.bridge.name: "docker0"
  6333. com.docker.network.driver.mtu: "1500"
  6334. Labels:
  6335. com.example.some-label: "some-value"
  6336. com.example.some-other-label: "some-other-value"
  6337. tags: ["Network"]
  6338. /networks/{id}/connect:
  6339. post:
  6340. summary: "Connect a container to a network"
  6341. operationId: "NetworkConnect"
  6342. consumes:
  6343. - "application/octet-stream"
  6344. responses:
  6345. 200:
  6346. description: "No error"
  6347. 403:
  6348. description: "Operation not supported for swarm scoped networks"
  6349. schema:
  6350. $ref: "#/definitions/ErrorResponse"
  6351. 404:
  6352. description: "Network or container not found"
  6353. schema:
  6354. $ref: "#/definitions/ErrorResponse"
  6355. 500:
  6356. description: "Server error"
  6357. schema:
  6358. $ref: "#/definitions/ErrorResponse"
  6359. parameters:
  6360. - name: "id"
  6361. in: "path"
  6362. description: "Network ID or name"
  6363. required: true
  6364. type: "string"
  6365. - name: "container"
  6366. in: "body"
  6367. required: true
  6368. schema:
  6369. type: "object"
  6370. properties:
  6371. Container:
  6372. type: "string"
  6373. description: "The ID or name of the container to connect to the network."
  6374. EndpointConfig:
  6375. $ref: "#/definitions/EndpointSettings"
  6376. example:
  6377. Container: "3613f73ba0e4"
  6378. EndpointConfig:
  6379. IPAMConfig:
  6380. IPv4Address: "172.24.56.89"
  6381. IPv6Address: "2001:db8::5689"
  6382. tags: ["Network"]
  6383. /networks/{id}/disconnect:
  6384. post:
  6385. summary: "Disconnect a container from a network"
  6386. operationId: "NetworkDisconnect"
  6387. consumes:
  6388. - "application/json"
  6389. responses:
  6390. 200:
  6391. description: "No error"
  6392. 403:
  6393. description: "Operation not supported for swarm scoped networks"
  6394. schema:
  6395. $ref: "#/definitions/ErrorResponse"
  6396. 404:
  6397. description: "Network or container not found"
  6398. schema:
  6399. $ref: "#/definitions/ErrorResponse"
  6400. 500:
  6401. description: "Server error"
  6402. schema:
  6403. $ref: "#/definitions/ErrorResponse"
  6404. parameters:
  6405. - name: "id"
  6406. in: "path"
  6407. description: "Network ID or name"
  6408. required: true
  6409. type: "string"
  6410. - name: "container"
  6411. in: "body"
  6412. required: true
  6413. schema:
  6414. type: "object"
  6415. properties:
  6416. Container:
  6417. type: "string"
  6418. description: "The ID or name of the container to disconnect from the network."
  6419. Force:
  6420. type: "boolean"
  6421. description: "Force the container to disconnect from the network."
  6422. tags: ["Network"]
  6423. /networks/prune:
  6424. post:
  6425. summary: "Delete unused networks"
  6426. produces:
  6427. - "application/json"
  6428. operationId: "NetworkPrune"
  6429. parameters:
  6430. - name: "filters"
  6431. in: "query"
  6432. description: |
  6433. Filters to process on the prune list, encoded as JSON (a `map[string][]string`).
  6434. Available filters:
  6435. - `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.
  6436. type: "string"
  6437. responses:
  6438. 200:
  6439. description: "No error"
  6440. schema:
  6441. type: "object"
  6442. properties:
  6443. NetworksDeleted:
  6444. description: "Networks that were deleted"
  6445. type: "array"
  6446. items:
  6447. type: "string"
  6448. 500:
  6449. description: "Server error"
  6450. schema:
  6451. $ref: "#/definitions/ErrorResponse"
  6452. tags: ["Network"]
  6453. /plugins:
  6454. get:
  6455. summary: "List plugins"
  6456. operationId: "PluginList"
  6457. description: "Returns information about installed plugins."
  6458. produces: ["application/json"]
  6459. responses:
  6460. 200:
  6461. description: "No error"
  6462. schema:
  6463. type: "array"
  6464. items:
  6465. $ref: "#/definitions/Plugin"
  6466. example:
  6467. - Id: "5724e2c8652da337ab2eedd19fc6fc0ec908e4bd907c7421bf6a8dfc70c4c078"
  6468. Name: "tiborvass/sample-volume-plugin"
  6469. Tag: "latest"
  6470. Active: true
  6471. Settings:
  6472. Env:
  6473. - "DEBUG=0"
  6474. Args: null
  6475. Devices: null
  6476. Config:
  6477. Description: "A sample volume plugin for Docker"
  6478. Documentation: "https://docs.docker.com/engine/extend/plugins/"
  6479. Interface:
  6480. Types:
  6481. - "docker.volumedriver/1.0"
  6482. Socket: "plugins.sock"
  6483. Entrypoint:
  6484. - "/usr/bin/sample-volume-plugin"
  6485. - "/data"
  6486. WorkDir: ""
  6487. User: {}
  6488. Network:
  6489. Type: ""
  6490. Linux:
  6491. Capabilities: null
  6492. AllowAllDevices: false
  6493. Devices: null
  6494. Mounts: null
  6495. PropagatedMount: "/data"
  6496. Env:
  6497. - Name: "DEBUG"
  6498. Description: "If set, prints debug messages"
  6499. Settable: null
  6500. Value: "0"
  6501. Args:
  6502. Name: "args"
  6503. Description: "command line arguments"
  6504. Settable: null
  6505. Value: []
  6506. 500:
  6507. description: "Server error"
  6508. schema:
  6509. $ref: "#/definitions/ErrorResponse"
  6510. parameters:
  6511. - name: "filters"
  6512. in: "query"
  6513. type: "string"
  6514. description: |
  6515. A JSON encoded value of the filters (a `map[string][]string`) to process on the plugin list. Available filters:
  6516. - `capability=<capability name>`
  6517. - `enable=<true>|<false>`
  6518. tags: ["Plugin"]
  6519. /plugins/privileges:
  6520. get:
  6521. summary: "Get plugin privileges"
  6522. operationId: "GetPluginPrivileges"
  6523. responses:
  6524. 200:
  6525. description: "no error"
  6526. schema:
  6527. type: "array"
  6528. items:
  6529. description: "Describes a permission the user has to accept upon installing the plugin."
  6530. type: "object"
  6531. properties:
  6532. Name:
  6533. type: "string"
  6534. Description:
  6535. type: "string"
  6536. Value:
  6537. type: "array"
  6538. items:
  6539. type: "string"
  6540. example:
  6541. - Name: "network"
  6542. Description: ""
  6543. Value:
  6544. - "host"
  6545. - Name: "mount"
  6546. Description: ""
  6547. Value:
  6548. - "/data"
  6549. - Name: "device"
  6550. Description: ""
  6551. Value:
  6552. - "/dev/cpu_dma_latency"
  6553. 500:
  6554. description: "server error"
  6555. schema:
  6556. $ref: "#/definitions/ErrorResponse"
  6557. parameters:
  6558. - name: "remote"
  6559. in: "query"
  6560. description: "The name of the plugin. The `:latest` tag is optional, and is the default if omitted."
  6561. required: true
  6562. type: "string"
  6563. tags:
  6564. - "Plugin"
  6565. /plugins/pull:
  6566. post:
  6567. summary: "Install a plugin"
  6568. operationId: "PluginPull"
  6569. description: |
  6570. Pulls and installs a plugin. After the plugin is installed, it can be enabled using the [`POST /plugins/{name}/enable` endpoint](#operation/PostPluginsEnable).
  6571. produces:
  6572. - "application/json"
  6573. responses:
  6574. 204:
  6575. description: "no error"
  6576. 500:
  6577. description: "server error"
  6578. schema:
  6579. $ref: "#/definitions/ErrorResponse"
  6580. parameters:
  6581. - name: "remote"
  6582. in: "query"
  6583. description: |
  6584. Remote reference for plugin to install.
  6585. The `:latest` tag is optional, and is used as the default if omitted.
  6586. required: true
  6587. type: "string"
  6588. - name: "name"
  6589. in: "query"
  6590. description: |
  6591. Local name for the pulled plugin.
  6592. The `:latest` tag is optional, and is used as the default if omitted.
  6593. required: false
  6594. type: "string"
  6595. - name: "X-Registry-Auth"
  6596. in: "header"
  6597. description: "A base64-encoded auth configuration to use when pulling a plugin from a registry. [See the authentication section for details.](#section/Authentication)"
  6598. type: "string"
  6599. - name: "body"
  6600. in: "body"
  6601. schema:
  6602. type: "array"
  6603. items:
  6604. description: "Describes a permission accepted by the user upon installing the plugin."
  6605. type: "object"
  6606. properties:
  6607. Name:
  6608. type: "string"
  6609. Description:
  6610. type: "string"
  6611. Value:
  6612. type: "array"
  6613. items:
  6614. type: "string"
  6615. example:
  6616. - Name: "network"
  6617. Description: ""
  6618. Value:
  6619. - "host"
  6620. - Name: "mount"
  6621. Description: ""
  6622. Value:
  6623. - "/data"
  6624. - Name: "device"
  6625. Description: ""
  6626. Value:
  6627. - "/dev/cpu_dma_latency"
  6628. tags: ["Plugin"]
  6629. /plugins/{name}/json:
  6630. get:
  6631. summary: "Inspect a plugin"
  6632. operationId: "PluginInspect"
  6633. responses:
  6634. 200:
  6635. description: "no error"
  6636. schema:
  6637. $ref: "#/definitions/Plugin"
  6638. 404:
  6639. description: "plugin is not installed"
  6640. schema:
  6641. $ref: "#/definitions/ErrorResponse"
  6642. 500:
  6643. description: "server error"
  6644. schema:
  6645. $ref: "#/definitions/ErrorResponse"
  6646. parameters:
  6647. - name: "name"
  6648. in: "path"
  6649. description: "The name of the plugin. The `:latest` tag is optional, and is the default if omitted."
  6650. required: true
  6651. type: "string"
  6652. tags: ["Plugin"]
  6653. /plugins/{name}:
  6654. delete:
  6655. summary: "Remove a plugin"
  6656. operationId: "PluginDelete"
  6657. responses:
  6658. 200:
  6659. description: "no error"
  6660. schema:
  6661. $ref: "#/definitions/Plugin"
  6662. 404:
  6663. description: "plugin is not installed"
  6664. schema:
  6665. $ref: "#/definitions/ErrorResponse"
  6666. 500:
  6667. description: "server error"
  6668. schema:
  6669. $ref: "#/definitions/ErrorResponse"
  6670. parameters:
  6671. - name: "name"
  6672. in: "path"
  6673. description: "The name of the plugin. The `:latest` tag is optional, and is the default if omitted."
  6674. required: true
  6675. type: "string"
  6676. - name: "force"
  6677. in: "query"
  6678. description: "Disable the plugin before removing. This may result in issues if the plugin is in use by a container."
  6679. type: "boolean"
  6680. default: false
  6681. tags: ["Plugin"]
  6682. /plugins/{name}/enable:
  6683. post:
  6684. summary: "Enable a plugin"
  6685. operationId: "PluginEnable"
  6686. responses:
  6687. 200:
  6688. description: "no error"
  6689. 404:
  6690. description: "plugin is not installed"
  6691. schema:
  6692. $ref: "#/definitions/ErrorResponse"
  6693. 500:
  6694. description: "server error"
  6695. schema:
  6696. $ref: "#/definitions/ErrorResponse"
  6697. parameters:
  6698. - name: "name"
  6699. in: "path"
  6700. description: "The name of the plugin. The `:latest` tag is optional, and is the default if omitted."
  6701. required: true
  6702. type: "string"
  6703. - name: "timeout"
  6704. in: "query"
  6705. description: "Set the HTTP client timeout (in seconds)"
  6706. type: "integer"
  6707. default: 0
  6708. tags: ["Plugin"]
  6709. /plugins/{name}/disable:
  6710. post:
  6711. summary: "Disable a plugin"
  6712. operationId: "PluginDisable"
  6713. responses:
  6714. 200:
  6715. description: "no error"
  6716. 404:
  6717. description: "plugin is not installed"
  6718. schema:
  6719. $ref: "#/definitions/ErrorResponse"
  6720. 500:
  6721. description: "server error"
  6722. schema:
  6723. $ref: "#/definitions/ErrorResponse"
  6724. parameters:
  6725. - name: "name"
  6726. in: "path"
  6727. description: "The name of the plugin. The `:latest` tag is optional, and is the default if omitted."
  6728. required: true
  6729. type: "string"
  6730. - name: "force"
  6731. in: "query"
  6732. description: |
  6733. Force disable a plugin even if still in use.
  6734. required: false
  6735. type: "boolean"
  6736. tags: ["Plugin"]
  6737. /plugins/{name}/upgrade:
  6738. post:
  6739. summary: "Upgrade a plugin"
  6740. operationId: "PluginUpgrade"
  6741. responses:
  6742. 204:
  6743. description: "no error"
  6744. 404:
  6745. description: "plugin not installed"
  6746. schema:
  6747. $ref: "#/definitions/ErrorResponse"
  6748. 500:
  6749. description: "server error"
  6750. schema:
  6751. $ref: "#/definitions/ErrorResponse"
  6752. parameters:
  6753. - name: "name"
  6754. in: "path"
  6755. description: "The name of the plugin. The `:latest` tag is optional, and is the default if omitted."
  6756. required: true
  6757. type: "string"
  6758. - name: "remote"
  6759. in: "query"
  6760. description: |
  6761. Remote reference to upgrade to.
  6762. The `:latest` tag is optional, and is used as the default if omitted.
  6763. required: true
  6764. type: "string"
  6765. - name: "X-Registry-Auth"
  6766. in: "header"
  6767. description: "A base64-encoded auth configuration to use when pulling a plugin from a registry. [See the authentication section for details.](#section/Authentication)"
  6768. type: "string"
  6769. - name: "body"
  6770. in: "body"
  6771. schema:
  6772. type: "array"
  6773. items:
  6774. description: "Describes a permission accepted by the user upon installing the plugin."
  6775. type: "object"
  6776. properties:
  6777. Name:
  6778. type: "string"
  6779. Description:
  6780. type: "string"
  6781. Value:
  6782. type: "array"
  6783. items:
  6784. type: "string"
  6785. example:
  6786. - Name: "network"
  6787. Description: ""
  6788. Value:
  6789. - "host"
  6790. - Name: "mount"
  6791. Description: ""
  6792. Value:
  6793. - "/data"
  6794. - Name: "device"
  6795. Description: ""
  6796. Value:
  6797. - "/dev/cpu_dma_latency"
  6798. tags: ["Plugin"]
  6799. /plugins/create:
  6800. post:
  6801. summary: "Create a plugin"
  6802. operationId: "PluginCreate"
  6803. consumes:
  6804. - "application/x-tar"
  6805. responses:
  6806. 204:
  6807. description: "no error"
  6808. 500:
  6809. description: "server error"
  6810. schema:
  6811. $ref: "#/definitions/ErrorResponse"
  6812. parameters:
  6813. - name: "name"
  6814. in: "query"
  6815. description: "The name of the plugin. The `:latest` tag is optional, and is the default if omitted."
  6816. required: true
  6817. type: "string"
  6818. - name: "tarContext"
  6819. in: "body"
  6820. description: "Path to tar containing plugin rootfs and manifest"
  6821. schema:
  6822. type: "string"
  6823. format: "binary"
  6824. tags: ["Plugin"]
  6825. /plugins/{name}/push:
  6826. post:
  6827. summary: "Push a plugin"
  6828. operationId: "PluginPush"
  6829. description: |
  6830. Push a plugin to the registry.
  6831. parameters:
  6832. - name: "name"
  6833. in: "path"
  6834. description: "The name of the plugin. The `:latest` tag is optional, and is the default if omitted."
  6835. required: true
  6836. type: "string"
  6837. responses:
  6838. 200:
  6839. description: "no error"
  6840. 404:
  6841. description: "plugin not installed"
  6842. schema:
  6843. $ref: "#/definitions/ErrorResponse"
  6844. 500:
  6845. description: "server error"
  6846. schema:
  6847. $ref: "#/definitions/ErrorResponse"
  6848. tags: ["Plugin"]
  6849. /plugins/{name}/set:
  6850. post:
  6851. summary: "Configure a plugin"
  6852. operationId: "PluginSet"
  6853. consumes:
  6854. - "application/json"
  6855. parameters:
  6856. - name: "name"
  6857. in: "path"
  6858. description: "The name of the plugin. The `:latest` tag is optional, and is the default if omitted."
  6859. required: true
  6860. type: "string"
  6861. - name: "body"
  6862. in: "body"
  6863. schema:
  6864. type: "array"
  6865. items:
  6866. type: "string"
  6867. example: ["DEBUG=1"]
  6868. responses:
  6869. 204:
  6870. description: "No error"
  6871. 404:
  6872. description: "Plugin not installed"
  6873. schema:
  6874. $ref: "#/definitions/ErrorResponse"
  6875. 500:
  6876. description: "Server error"
  6877. schema:
  6878. $ref: "#/definitions/ErrorResponse"
  6879. tags: ["Plugin"]
  6880. /nodes:
  6881. get:
  6882. summary: "List nodes"
  6883. operationId: "NodeList"
  6884. responses:
  6885. 200:
  6886. description: "no error"
  6887. schema:
  6888. type: "array"
  6889. items:
  6890. $ref: "#/definitions/Node"
  6891. 500:
  6892. description: "server error"
  6893. schema:
  6894. $ref: "#/definitions/ErrorResponse"
  6895. 503:
  6896. description: "node is not part of a swarm"
  6897. schema:
  6898. $ref: "#/definitions/ErrorResponse"
  6899. parameters:
  6900. - name: "filters"
  6901. in: "query"
  6902. description: |
  6903. Filters to process on the nodes list, encoded as JSON (a `map[string][]string`).
  6904. Available filters:
  6905. - `id=<node id>`
  6906. - `label=<engine label>`
  6907. - `membership=`(`accepted`|`pending`)`
  6908. - `name=<node name>`
  6909. - `role=`(`manager`|`worker`)`
  6910. type: "string"
  6911. tags: ["Node"]
  6912. /nodes/{id}:
  6913. get:
  6914. summary: "Inspect a node"
  6915. operationId: "NodeInspect"
  6916. responses:
  6917. 200:
  6918. description: "no error"
  6919. schema:
  6920. $ref: "#/definitions/Node"
  6921. 404:
  6922. description: "no such node"
  6923. schema:
  6924. $ref: "#/definitions/ErrorResponse"
  6925. 500:
  6926. description: "server error"
  6927. schema:
  6928. $ref: "#/definitions/ErrorResponse"
  6929. 503:
  6930. description: "node is not part of a swarm"
  6931. schema:
  6932. $ref: "#/definitions/ErrorResponse"
  6933. parameters:
  6934. - name: "id"
  6935. in: "path"
  6936. description: "The ID or name of the node"
  6937. type: "string"
  6938. required: true
  6939. tags: ["Node"]
  6940. delete:
  6941. summary: "Delete a node"
  6942. operationId: "NodeDelete"
  6943. responses:
  6944. 200:
  6945. description: "no error"
  6946. 404:
  6947. description: "no such node"
  6948. schema:
  6949. $ref: "#/definitions/ErrorResponse"
  6950. 500:
  6951. description: "server error"
  6952. schema:
  6953. $ref: "#/definitions/ErrorResponse"
  6954. 503:
  6955. description: "node is not part of a swarm"
  6956. schema:
  6957. $ref: "#/definitions/ErrorResponse"
  6958. parameters:
  6959. - name: "id"
  6960. in: "path"
  6961. description: "The ID or name of the node"
  6962. type: "string"
  6963. required: true
  6964. - name: "force"
  6965. in: "query"
  6966. description: "Force remove a node from the swarm"
  6967. default: false
  6968. type: "boolean"
  6969. tags: ["Node"]
  6970. /nodes/{id}/update:
  6971. post:
  6972. summary: "Update a node"
  6973. operationId: "NodeUpdate"
  6974. responses:
  6975. 200:
  6976. description: "no error"
  6977. 404:
  6978. description: "no such node"
  6979. schema:
  6980. $ref: "#/definitions/ErrorResponse"
  6981. 500:
  6982. description: "server error"
  6983. schema:
  6984. $ref: "#/definitions/ErrorResponse"
  6985. 503:
  6986. description: "node is not part of a swarm"
  6987. schema:
  6988. $ref: "#/definitions/ErrorResponse"
  6989. parameters:
  6990. - name: "id"
  6991. in: "path"
  6992. description: "The ID of the node"
  6993. type: "string"
  6994. required: true
  6995. - name: "body"
  6996. in: "body"
  6997. schema:
  6998. $ref: "#/definitions/NodeSpec"
  6999. - name: "version"
  7000. in: "query"
  7001. description: "The version number of the node object being updated. This is required to avoid conflicting writes."
  7002. type: "integer"
  7003. format: "int64"
  7004. required: true
  7005. tags: ["Node"]
  7006. /swarm:
  7007. get:
  7008. summary: "Inspect swarm"
  7009. operationId: "SwarmInspect"
  7010. responses:
  7011. 200:
  7012. description: "no error"
  7013. schema:
  7014. allOf:
  7015. - $ref: "#/definitions/ClusterInfo"
  7016. - type: "object"
  7017. properties:
  7018. JoinTokens:
  7019. description: "The tokens workers and managers need to join the swarm."
  7020. type: "object"
  7021. properties:
  7022. Worker:
  7023. description: "The token workers can use to join the swarm."
  7024. type: "string"
  7025. Manager:
  7026. description: "The token managers can use to join the swarm."
  7027. type: "string"
  7028. example:
  7029. CreatedAt: "2016-08-15T16:00:20.349727406Z"
  7030. Spec:
  7031. Dispatcher:
  7032. HeartbeatPeriod: 5000000000
  7033. Orchestration:
  7034. TaskHistoryRetentionLimit: 10
  7035. CAConfig:
  7036. NodeCertExpiry: 7776000000000000
  7037. Raft:
  7038. LogEntriesForSlowFollowers: 500
  7039. HeartbeatTick: 1
  7040. SnapshotInterval: 10000
  7041. ElectionTick: 3
  7042. TaskDefaults: {}
  7043. EncryptionConfig:
  7044. AutoLockManagers: false
  7045. Name: "default"
  7046. JoinTokens:
  7047. Worker: "SWMTKN-1-1h8aps2yszaiqmz2l3oc5392pgk8e49qhx2aj3nyv0ui0hez2a-6qmn92w6bu3jdvnglku58u11a"
  7048. Manager: "SWMTKN-1-1h8aps2yszaiqmz2l3oc5392pgk8e49qhx2aj3nyv0ui0hez2a-8llk83c4wm9lwioey2s316r9l"
  7049. ID: "70ilmkj2f6sp2137c753w2nmt"
  7050. UpdatedAt: "2016-08-15T16:32:09.623207604Z"
  7051. Version:
  7052. Index: 51
  7053. 404:
  7054. description: "no such swarm"
  7055. schema:
  7056. $ref: "#/definitions/ErrorResponse"
  7057. 500:
  7058. description: "server error"
  7059. schema:
  7060. $ref: "#/definitions/ErrorResponse"
  7061. 503:
  7062. description: "node is not part of a swarm"
  7063. schema:
  7064. $ref: "#/definitions/ErrorResponse"
  7065. tags: ["Swarm"]
  7066. /swarm/init:
  7067. post:
  7068. summary: "Initialize a new swarm"
  7069. operationId: "SwarmInit"
  7070. produces:
  7071. - "application/json"
  7072. - "text/plain"
  7073. responses:
  7074. 200:
  7075. description: "no error"
  7076. schema:
  7077. description: "The node ID"
  7078. type: "string"
  7079. example: "7v2t30z9blmxuhnyo6s4cpenp"
  7080. 400:
  7081. description: "bad parameter"
  7082. schema:
  7083. $ref: "#/definitions/ErrorResponse"
  7084. 500:
  7085. description: "server error"
  7086. schema:
  7087. $ref: "#/definitions/ErrorResponse"
  7088. 503:
  7089. description: "node is already part of a swarm"
  7090. schema:
  7091. $ref: "#/definitions/ErrorResponse"
  7092. parameters:
  7093. - name: "body"
  7094. in: "body"
  7095. required: true
  7096. schema:
  7097. type: "object"
  7098. properties:
  7099. ListenAddr:
  7100. description: "Listen address used for inter-manager communication, as well as determining the networking interface used for the VXLAN Tunnel Endpoint (VTEP). This can either be an address/port combination in the form `192.168.1.1:4567`, or an interface followed by a port number, like `eth0:4567`. If the port number is omitted, the default swarm listening port is used."
  7101. type: "string"
  7102. AdvertiseAddr:
  7103. description: "Externally reachable address advertised to other nodes. This can either be an address/port combination in the form `192.168.1.1:4567`, or an interface followed by a port number, like `eth0:4567`. If the port number is omitted, the port number from the listen address is used. If `AdvertiseAddr` is not specified, it will be automatically detected when possible."
  7104. type: "string"
  7105. ForceNewCluster:
  7106. description: "Force creation of a new swarm."
  7107. type: "boolean"
  7108. Spec:
  7109. $ref: "#/definitions/SwarmSpec"
  7110. example:
  7111. ListenAddr: "0.0.0.0:2377"
  7112. AdvertiseAddr: "192.168.1.1:2377"
  7113. ForceNewCluster: false
  7114. Spec:
  7115. Orchestration: {}
  7116. Raft: {}
  7117. Dispatcher: {}
  7118. CAConfig: {}
  7119. EncryptionConfig:
  7120. AutoLockManagers: false
  7121. tags: ["Swarm"]
  7122. /swarm/join:
  7123. post:
  7124. summary: "Join an existing swarm"
  7125. operationId: "SwarmJoin"
  7126. responses:
  7127. 200:
  7128. description: "no error"
  7129. 400:
  7130. description: "bad parameter"
  7131. schema:
  7132. $ref: "#/definitions/ErrorResponse"
  7133. 500:
  7134. description: "server error"
  7135. schema:
  7136. $ref: "#/definitions/ErrorResponse"
  7137. 503:
  7138. description: "node is already part of a swarm"
  7139. schema:
  7140. $ref: "#/definitions/ErrorResponse"
  7141. parameters:
  7142. - name: "body"
  7143. in: "body"
  7144. required: true
  7145. schema:
  7146. type: "object"
  7147. properties:
  7148. ListenAddr:
  7149. description: "Listen address used for inter-manager communication if the node gets promoted to manager, as well as determining the networking interface used for the VXLAN Tunnel Endpoint (VTEP)."
  7150. type: "string"
  7151. AdvertiseAddr:
  7152. description: "Externally reachable address advertised to other nodes. This can either be an address/port combination in the form `192.168.1.1:4567`, or an interface followed by a port number, like `eth0:4567`. If the port number is omitted, the port number from the listen address is used. If `AdvertiseAddr` is not specified, it will be automatically detected when possible."
  7153. type: "string"
  7154. RemoteAddrs:
  7155. description: "Addresses of manager nodes already participating in the swarm."
  7156. type: "string"
  7157. JoinToken:
  7158. description: "Secret token for joining this swarm."
  7159. type: "string"
  7160. example:
  7161. ListenAddr: "0.0.0.0:2377"
  7162. AdvertiseAddr: "192.168.1.1:2377"
  7163. RemoteAddrs:
  7164. - "node1:2377"
  7165. JoinToken: "SWMTKN-1-3pu6hszjas19xyp7ghgosyx9k8atbfcr8p2is99znpy26u2lkl-7p73s1dx5in4tatdymyhg9hu2"
  7166. tags: ["Swarm"]
  7167. /swarm/leave:
  7168. post:
  7169. summary: "Leave a swarm"
  7170. operationId: "SwarmLeave"
  7171. responses:
  7172. 200:
  7173. description: "no error"
  7174. 500:
  7175. description: "server error"
  7176. schema:
  7177. $ref: "#/definitions/ErrorResponse"
  7178. 503:
  7179. description: "node is not part of a swarm"
  7180. schema:
  7181. $ref: "#/definitions/ErrorResponse"
  7182. parameters:
  7183. - name: "force"
  7184. description: "Force leave swarm, even if this is the last manager or that it will break the cluster."
  7185. in: "query"
  7186. type: "boolean"
  7187. default: false
  7188. tags: ["Swarm"]
  7189. /swarm/update:
  7190. post:
  7191. summary: "Update a swarm"
  7192. operationId: "SwarmUpdate"
  7193. responses:
  7194. 200:
  7195. description: "no error"
  7196. 400:
  7197. description: "bad parameter"
  7198. schema:
  7199. $ref: "#/definitions/ErrorResponse"
  7200. 500:
  7201. description: "server error"
  7202. schema:
  7203. $ref: "#/definitions/ErrorResponse"
  7204. 503:
  7205. description: "node is not part of a swarm"
  7206. schema:
  7207. $ref: "#/definitions/ErrorResponse"
  7208. parameters:
  7209. - name: "body"
  7210. in: "body"
  7211. required: true
  7212. schema:
  7213. $ref: "#/definitions/SwarmSpec"
  7214. - name: "version"
  7215. in: "query"
  7216. description: "The version number of the swarm object being updated. This is required to avoid conflicting writes."
  7217. type: "integer"
  7218. format: "int64"
  7219. required: true
  7220. - name: "rotateWorkerToken"
  7221. in: "query"
  7222. description: "Rotate the worker join token."
  7223. type: "boolean"
  7224. default: false
  7225. - name: "rotateManagerToken"
  7226. in: "query"
  7227. description: "Rotate the manager join token."
  7228. type: "boolean"
  7229. default: false
  7230. - name: "rotateManagerUnlockKey"
  7231. in: "query"
  7232. description: "Rotate the manager unlock key."
  7233. type: "boolean"
  7234. default: false
  7235. tags: ["Swarm"]
  7236. /swarm/unlockkey:
  7237. get:
  7238. summary: "Get the unlock key"
  7239. operationId: "SwarmUnlockkey"
  7240. consumes:
  7241. - "application/json"
  7242. responses:
  7243. 200:
  7244. description: "no error"
  7245. schema:
  7246. type: "object"
  7247. properties:
  7248. UnlockKey:
  7249. description: "The swarm's unlock key."
  7250. type: "string"
  7251. example:
  7252. UnlockKey: "SWMKEY-1-7c37Cc8654o6p38HnroywCi19pllOnGtbdZEgtKxZu8"
  7253. 500:
  7254. description: "server error"
  7255. schema:
  7256. $ref: "#/definitions/ErrorResponse"
  7257. 503:
  7258. description: "node is not part of a swarm"
  7259. schema:
  7260. $ref: "#/definitions/ErrorResponse"
  7261. tags: ["Swarm"]
  7262. /swarm/unlock:
  7263. post:
  7264. summary: "Unlock a locked manager"
  7265. operationId: "SwarmUnlock"
  7266. consumes:
  7267. - "application/json"
  7268. produces:
  7269. - "application/json"
  7270. parameters:
  7271. - name: "body"
  7272. in: "body"
  7273. required: true
  7274. schema:
  7275. type: "object"
  7276. properties:
  7277. UnlockKey:
  7278. description: "The swarm's unlock key."
  7279. type: "string"
  7280. example:
  7281. UnlockKey: "SWMKEY-1-7c37Cc8654o6p38HnroywCi19pllOnGtbdZEgtKxZu8"
  7282. responses:
  7283. 200:
  7284. description: "no error"
  7285. 500:
  7286. description: "server error"
  7287. schema:
  7288. $ref: "#/definitions/ErrorResponse"
  7289. 503:
  7290. description: "node is not part of a swarm"
  7291. schema:
  7292. $ref: "#/definitions/ErrorResponse"
  7293. tags: ["Swarm"]
  7294. /services:
  7295. get:
  7296. summary: "List services"
  7297. operationId: "ServiceList"
  7298. responses:
  7299. 200:
  7300. description: "no error"
  7301. schema:
  7302. type: "array"
  7303. items:
  7304. $ref: "#/definitions/Service"
  7305. 500:
  7306. description: "server error"
  7307. schema:
  7308. $ref: "#/definitions/ErrorResponse"
  7309. 503:
  7310. description: "node is not part of a swarm"
  7311. schema:
  7312. $ref: "#/definitions/ErrorResponse"
  7313. parameters:
  7314. - name: "filters"
  7315. in: "query"
  7316. type: "string"
  7317. description: |
  7318. A JSON encoded value of the filters (a `map[string][]string`) to process on the services list. Available filters:
  7319. - `id=<service id>`
  7320. - `label=<service label>`
  7321. - `mode=["replicated"|"global"]`
  7322. - `name=<service name>`
  7323. tags: ["Service"]
  7324. /services/create:
  7325. post:
  7326. summary: "Create a service"
  7327. operationId: "ServiceCreate"
  7328. consumes:
  7329. - "application/json"
  7330. produces:
  7331. - "application/json"
  7332. responses:
  7333. 201:
  7334. description: "no error"
  7335. schema:
  7336. type: "object"
  7337. properties:
  7338. ID:
  7339. description: "The ID of the created service."
  7340. type: "string"
  7341. Warning:
  7342. description: "Optional warning message"
  7343. type: "string"
  7344. example:
  7345. ID: "ak7w3gjqoa3kuz8xcpnyy0pvl"
  7346. Warning: "unable to pin image doesnotexist:latest to digest: image library/doesnotexist:latest not found"
  7347. 400:
  7348. description: "bad parameter"
  7349. schema:
  7350. $ref: "#/definitions/ErrorResponse"
  7351. 403:
  7352. description: "network is not eligible for services"
  7353. schema:
  7354. $ref: "#/definitions/ErrorResponse"
  7355. 409:
  7356. description: "name conflicts with an existing service"
  7357. schema:
  7358. $ref: "#/definitions/ErrorResponse"
  7359. 500:
  7360. description: "server error"
  7361. schema:
  7362. $ref: "#/definitions/ErrorResponse"
  7363. 503:
  7364. description: "node is not part of a swarm"
  7365. schema:
  7366. $ref: "#/definitions/ErrorResponse"
  7367. parameters:
  7368. - name: "body"
  7369. in: "body"
  7370. required: true
  7371. schema:
  7372. allOf:
  7373. - $ref: "#/definitions/ServiceSpec"
  7374. - type: "object"
  7375. example:
  7376. Name: "web"
  7377. TaskTemplate:
  7378. ContainerSpec:
  7379. Image: "nginx:alpine"
  7380. Mounts:
  7381. -
  7382. ReadOnly: true
  7383. Source: "web-data"
  7384. Target: "/usr/share/nginx/html"
  7385. Type: "volume"
  7386. VolumeOptions:
  7387. DriverConfig: {}
  7388. Labels:
  7389. com.example.something: "something-value"
  7390. Hosts: ["10.10.10.10 host1", "ABCD:EF01:2345:6789:ABCD:EF01:2345:6789 host2"]
  7391. User: "33"
  7392. DNSConfig:
  7393. Nameservers: ["8.8.8.8"]
  7394. Search: ["example.org"]
  7395. Options: ["timeout:3"]
  7396. LogDriver:
  7397. Name: "json-file"
  7398. Options:
  7399. max-file: "3"
  7400. max-size: "10M"
  7401. Placement: {}
  7402. Resources:
  7403. Limits:
  7404. MemoryBytes: 104857600
  7405. Reservations: {}
  7406. RestartPolicy:
  7407. Condition: "on-failure"
  7408. Delay: 10000000000
  7409. MaxAttempts: 10
  7410. Mode:
  7411. Replicated:
  7412. Replicas: 4
  7413. UpdateConfig:
  7414. Parallelism: 2
  7415. Delay: 1000000000
  7416. FailureAction: "pause"
  7417. Monitor: 15000000000
  7418. MaxFailureRatio: 0.15
  7419. RollbackConfig:
  7420. Parallelism: 1
  7421. Delay: 1000000000
  7422. FailureAction: "pause"
  7423. Monitor: 15000000000
  7424. MaxFailureRatio: 0.15
  7425. EndpointSpec:
  7426. Ports:
  7427. -
  7428. Protocol: "tcp"
  7429. PublishedPort: 8080
  7430. TargetPort: 80
  7431. Labels:
  7432. foo: "bar"
  7433. - name: "X-Registry-Auth"
  7434. in: "header"
  7435. description: "A base64-encoded auth configuration for pulling from private registries. [See the authentication section for details.](#section/Authentication)"
  7436. type: "string"
  7437. tags: ["Service"]
  7438. /services/{id}:
  7439. get:
  7440. summary: "Inspect a service"
  7441. operationId: "ServiceInspect"
  7442. responses:
  7443. 200:
  7444. description: "no error"
  7445. schema:
  7446. $ref: "#/definitions/Service"
  7447. 404:
  7448. description: "no such service"
  7449. schema:
  7450. $ref: "#/definitions/ErrorResponse"
  7451. 500:
  7452. description: "server error"
  7453. schema:
  7454. $ref: "#/definitions/ErrorResponse"
  7455. 503:
  7456. description: "node is not part of a swarm"
  7457. schema:
  7458. $ref: "#/definitions/ErrorResponse"
  7459. parameters:
  7460. - name: "id"
  7461. in: "path"
  7462. description: "ID or name of service."
  7463. required: true
  7464. type: "string"
  7465. - name: "insertDefaults"
  7466. in: "query"
  7467. description: "Fill empty fields with default values."
  7468. type: "boolean"
  7469. default: false
  7470. tags: ["Service"]
  7471. delete:
  7472. summary: "Delete a service"
  7473. operationId: "ServiceDelete"
  7474. responses:
  7475. 200:
  7476. description: "no error"
  7477. 404:
  7478. description: "no such service"
  7479. schema:
  7480. $ref: "#/definitions/ErrorResponse"
  7481. 500:
  7482. description: "server error"
  7483. schema:
  7484. $ref: "#/definitions/ErrorResponse"
  7485. 503:
  7486. description: "node is not part of a swarm"
  7487. schema:
  7488. $ref: "#/definitions/ErrorResponse"
  7489. parameters:
  7490. - name: "id"
  7491. in: "path"
  7492. description: "ID or name of service."
  7493. required: true
  7494. type: "string"
  7495. tags: ["Service"]
  7496. /services/{id}/update:
  7497. post:
  7498. summary: "Update a service"
  7499. operationId: "ServiceUpdate"
  7500. consumes: ["application/json"]
  7501. produces: ["application/json"]
  7502. responses:
  7503. 200:
  7504. description: "no error"
  7505. schema:
  7506. $ref: "#/definitions/ServiceUpdateResponse"
  7507. 400:
  7508. description: "bad parameter"
  7509. schema:
  7510. $ref: "#/definitions/ErrorResponse"
  7511. 404:
  7512. description: "no such service"
  7513. schema:
  7514. $ref: "#/definitions/ErrorResponse"
  7515. 500:
  7516. description: "server error"
  7517. schema:
  7518. $ref: "#/definitions/ErrorResponse"
  7519. 503:
  7520. description: "node is not part of a swarm"
  7521. schema:
  7522. $ref: "#/definitions/ErrorResponse"
  7523. parameters:
  7524. - name: "id"
  7525. in: "path"
  7526. description: "ID or name of service."
  7527. required: true
  7528. type: "string"
  7529. - name: "body"
  7530. in: "body"
  7531. required: true
  7532. schema:
  7533. allOf:
  7534. - $ref: "#/definitions/ServiceSpec"
  7535. - type: "object"
  7536. example:
  7537. Name: "top"
  7538. TaskTemplate:
  7539. ContainerSpec:
  7540. Image: "busybox"
  7541. Args:
  7542. - "top"
  7543. Resources:
  7544. Limits: {}
  7545. Reservations: {}
  7546. RestartPolicy:
  7547. Condition: "any"
  7548. MaxAttempts: 0
  7549. Placement: {}
  7550. ForceUpdate: 0
  7551. Mode:
  7552. Replicated:
  7553. Replicas: 1
  7554. UpdateConfig:
  7555. Parallelism: 2
  7556. Delay: 1000000000
  7557. FailureAction: "pause"
  7558. Monitor: 15000000000
  7559. MaxFailureRatio: 0.15
  7560. RollbackConfig:
  7561. Parallelism: 1
  7562. Delay: 1000000000
  7563. FailureAction: "pause"
  7564. Monitor: 15000000000
  7565. MaxFailureRatio: 0.15
  7566. EndpointSpec:
  7567. Mode: "vip"
  7568. - name: "version"
  7569. in: "query"
  7570. description: "The version number of the service object being updated. This is required to avoid conflicting writes."
  7571. required: true
  7572. type: "integer"
  7573. - name: "registryAuthFrom"
  7574. in: "query"
  7575. type: "string"
  7576. description: "If the X-Registry-Auth header is not specified, this
  7577. parameter indicates where to find registry authorization credentials. The
  7578. valid values are `spec` and `previous-spec`."
  7579. default: "spec"
  7580. - name: "rollback"
  7581. in: "query"
  7582. type: "string"
  7583. description: "Set to this parameter to `previous` to cause a
  7584. server-side rollback to the previous service spec. The supplied spec will be
  7585. ignored in this case."
  7586. - name: "X-Registry-Auth"
  7587. in: "header"
  7588. description: "A base64-encoded auth configuration for pulling from private registries. [See the authentication section for details.](#section/Authentication)"
  7589. type: "string"
  7590. tags: ["Service"]
  7591. /services/{id}/logs:
  7592. get:
  7593. summary: "Get service logs"
  7594. description: |
  7595. Get `stdout` and `stderr` logs from a service.
  7596. **Note**: This endpoint works only for services with the `json-file` or `journald` logging drivers.
  7597. operationId: "ServiceLogs"
  7598. produces:
  7599. - "application/vnd.docker.raw-stream"
  7600. - "application/json"
  7601. responses:
  7602. 101:
  7603. description: "logs returned as a stream"
  7604. schema:
  7605. type: "string"
  7606. format: "binary"
  7607. 200:
  7608. description: "logs returned as a string in response body"
  7609. schema:
  7610. type: "string"
  7611. 404:
  7612. description: "no such service"
  7613. schema:
  7614. $ref: "#/definitions/ErrorResponse"
  7615. examples:
  7616. application/json:
  7617. message: "No such service: c2ada9df5af8"
  7618. 500:
  7619. description: "server error"
  7620. schema:
  7621. $ref: "#/definitions/ErrorResponse"
  7622. 503:
  7623. description: "node is not part of a swarm"
  7624. schema:
  7625. $ref: "#/definitions/ErrorResponse"
  7626. parameters:
  7627. - name: "id"
  7628. in: "path"
  7629. required: true
  7630. description: "ID or name of the service"
  7631. type: "string"
  7632. - name: "details"
  7633. in: "query"
  7634. description: "Show service context and extra details provided to logs."
  7635. type: "boolean"
  7636. default: false
  7637. - name: "follow"
  7638. in: "query"
  7639. description: |
  7640. Return the logs as a stream.
  7641. This will return a `101` HTTP response with a `Connection: upgrade` header, then hijack the HTTP connection to send raw output. For more information about hijacking and the stream format, [see the documentation for the attach endpoint](#operation/ContainerAttach).
  7642. type: "boolean"
  7643. default: false
  7644. - name: "stdout"
  7645. in: "query"
  7646. description: "Return logs from `stdout`"
  7647. type: "boolean"
  7648. default: false
  7649. - name: "stderr"
  7650. in: "query"
  7651. description: "Return logs from `stderr`"
  7652. type: "boolean"
  7653. default: false
  7654. - name: "since"
  7655. in: "query"
  7656. description: "Only return logs since this time, as a UNIX timestamp"
  7657. type: "integer"
  7658. default: 0
  7659. - name: "timestamps"
  7660. in: "query"
  7661. description: "Add timestamps to every log line"
  7662. type: "boolean"
  7663. default: false
  7664. - name: "tail"
  7665. in: "query"
  7666. description: "Only return this number of log lines from the end of the logs. Specify as an integer or `all` to output all log lines."
  7667. type: "string"
  7668. default: "all"
  7669. tags: ["Service"]
  7670. /tasks:
  7671. get:
  7672. summary: "List tasks"
  7673. operationId: "TaskList"
  7674. produces:
  7675. - "application/json"
  7676. responses:
  7677. 200:
  7678. description: "no error"
  7679. schema:
  7680. type: "array"
  7681. items:
  7682. $ref: "#/definitions/Task"
  7683. example:
  7684. - ID: "0kzzo1i0y4jz6027t0k7aezc7"
  7685. Version:
  7686. Index: 71
  7687. CreatedAt: "2016-06-07T21:07:31.171892745Z"
  7688. UpdatedAt: "2016-06-07T21:07:31.376370513Z"
  7689. Spec:
  7690. ContainerSpec:
  7691. Image: "redis"
  7692. Resources:
  7693. Limits: {}
  7694. Reservations: {}
  7695. RestartPolicy:
  7696. Condition: "any"
  7697. MaxAttempts: 0
  7698. Placement: {}
  7699. ServiceID: "9mnpnzenvg8p8tdbtq4wvbkcz"
  7700. Slot: 1
  7701. NodeID: "60gvrl6tm78dmak4yl7srz94v"
  7702. Status:
  7703. Timestamp: "2016-06-07T21:07:31.290032978Z"
  7704. State: "running"
  7705. Message: "started"
  7706. ContainerStatus:
  7707. ContainerID: "e5d62702a1b48d01c3e02ca1e0212a250801fa8d67caca0b6f35919ebc12f035"
  7708. PID: 677
  7709. DesiredState: "running"
  7710. NetworksAttachments:
  7711. - Network:
  7712. ID: "4qvuz4ko70xaltuqbt8956gd1"
  7713. Version:
  7714. Index: 18
  7715. CreatedAt: "2016-06-07T20:31:11.912919752Z"
  7716. UpdatedAt: "2016-06-07T21:07:29.955277358Z"
  7717. Spec:
  7718. Name: "ingress"
  7719. Labels:
  7720. com.docker.swarm.internal: "true"
  7721. DriverConfiguration: {}
  7722. IPAMOptions:
  7723. Driver: {}
  7724. Configs:
  7725. - Subnet: "10.255.0.0/16"
  7726. Gateway: "10.255.0.1"
  7727. DriverState:
  7728. Name: "overlay"
  7729. Options:
  7730. com.docker.network.driver.overlay.vxlanid_list: "256"
  7731. IPAMOptions:
  7732. Driver:
  7733. Name: "default"
  7734. Configs:
  7735. - Subnet: "10.255.0.0/16"
  7736. Gateway: "10.255.0.1"
  7737. Addresses:
  7738. - "10.255.0.10/16"
  7739. - ID: "1yljwbmlr8er2waf8orvqpwms"
  7740. Version:
  7741. Index: 30
  7742. CreatedAt: "2016-06-07T21:07:30.019104782Z"
  7743. UpdatedAt: "2016-06-07T21:07:30.231958098Z"
  7744. Name: "hopeful_cori"
  7745. Spec:
  7746. ContainerSpec:
  7747. Image: "redis"
  7748. Resources:
  7749. Limits: {}
  7750. Reservations: {}
  7751. RestartPolicy:
  7752. Condition: "any"
  7753. MaxAttempts: 0
  7754. Placement: {}
  7755. ServiceID: "9mnpnzenvg8p8tdbtq4wvbkcz"
  7756. Slot: 1
  7757. NodeID: "60gvrl6tm78dmak4yl7srz94v"
  7758. Status:
  7759. Timestamp: "2016-06-07T21:07:30.202183143Z"
  7760. State: "shutdown"
  7761. Message: "shutdown"
  7762. ContainerStatus:
  7763. ContainerID: "1cf8d63d18e79668b0004a4be4c6ee58cddfad2dae29506d8781581d0688a213"
  7764. DesiredState: "shutdown"
  7765. NetworksAttachments:
  7766. - Network:
  7767. ID: "4qvuz4ko70xaltuqbt8956gd1"
  7768. Version:
  7769. Index: 18
  7770. CreatedAt: "2016-06-07T20:31:11.912919752Z"
  7771. UpdatedAt: "2016-06-07T21:07:29.955277358Z"
  7772. Spec:
  7773. Name: "ingress"
  7774. Labels:
  7775. com.docker.swarm.internal: "true"
  7776. DriverConfiguration: {}
  7777. IPAMOptions:
  7778. Driver: {}
  7779. Configs:
  7780. - Subnet: "10.255.0.0/16"
  7781. Gateway: "10.255.0.1"
  7782. DriverState:
  7783. Name: "overlay"
  7784. Options:
  7785. com.docker.network.driver.overlay.vxlanid_list: "256"
  7786. IPAMOptions:
  7787. Driver:
  7788. Name: "default"
  7789. Configs:
  7790. - Subnet: "10.255.0.0/16"
  7791. Gateway: "10.255.0.1"
  7792. Addresses:
  7793. - "10.255.0.5/16"
  7794. 500:
  7795. description: "server error"
  7796. schema:
  7797. $ref: "#/definitions/ErrorResponse"
  7798. 503:
  7799. description: "node is not part of a swarm"
  7800. schema:
  7801. $ref: "#/definitions/ErrorResponse"
  7802. parameters:
  7803. - name: "filters"
  7804. in: "query"
  7805. type: "string"
  7806. description: |
  7807. A JSON encoded value of the filters (a `map[string][]string`) to process on the tasks list. Available filters:
  7808. - `desired-state=(running | shutdown | accepted)`
  7809. - `id=<task id>`
  7810. - `label=key` or `label="key=value"`
  7811. - `name=<task name>`
  7812. - `node=<node id or name>`
  7813. - `service=<service name>`
  7814. tags: ["Task"]
  7815. /tasks/{id}:
  7816. get:
  7817. summary: "Inspect a task"
  7818. operationId: "TaskInspect"
  7819. produces:
  7820. - "application/json"
  7821. responses:
  7822. 200:
  7823. description: "no error"
  7824. schema:
  7825. $ref: "#/definitions/Task"
  7826. 404:
  7827. description: "no such task"
  7828. schema:
  7829. $ref: "#/definitions/ErrorResponse"
  7830. 500:
  7831. description: "server error"
  7832. schema:
  7833. $ref: "#/definitions/ErrorResponse"
  7834. 503:
  7835. description: "node is not part of a swarm"
  7836. schema:
  7837. $ref: "#/definitions/ErrorResponse"
  7838. parameters:
  7839. - name: "id"
  7840. in: "path"
  7841. description: "ID of the task"
  7842. required: true
  7843. type: "string"
  7844. tags: ["Task"]
  7845. /tasks/{id}/logs:
  7846. get:
  7847. summary: "Get task logs"
  7848. description: |
  7849. Get `stdout` and `stderr` logs from a task.
  7850. **Note**: This endpoint works only for services with the `json-file` or `journald` logging drivers.
  7851. operationId: "TaskLogs"
  7852. produces:
  7853. - "application/vnd.docker.raw-stream"
  7854. - "application/json"
  7855. responses:
  7856. 101:
  7857. description: "logs returned as a stream"
  7858. schema:
  7859. type: "string"
  7860. format: "binary"
  7861. 200:
  7862. description: "logs returned as a string in response body"
  7863. schema:
  7864. type: "string"
  7865. 404:
  7866. description: "no such task"
  7867. schema:
  7868. $ref: "#/definitions/ErrorResponse"
  7869. examples:
  7870. application/json:
  7871. message: "No such task: c2ada9df5af8"
  7872. 500:
  7873. description: "server error"
  7874. schema:
  7875. $ref: "#/definitions/ErrorResponse"
  7876. 503:
  7877. description: "node is not part of a swarm"
  7878. schema:
  7879. $ref: "#/definitions/ErrorResponse"
  7880. parameters:
  7881. - name: "id"
  7882. in: "path"
  7883. required: true
  7884. description: "ID of the task"
  7885. type: "string"
  7886. - name: "details"
  7887. in: "query"
  7888. description: "Show task context and extra details provided to logs."
  7889. type: "boolean"
  7890. default: false
  7891. - name: "follow"
  7892. in: "query"
  7893. description: |
  7894. Return the logs as a stream.
  7895. This will return a `101` HTTP response with a `Connection: upgrade` header, then hijack the HTTP connection to send raw output. For more information about hijacking and the stream format, [see the documentation for the attach endpoint](#operation/ContainerAttach).
  7896. type: "boolean"
  7897. default: false
  7898. - name: "stdout"
  7899. in: "query"
  7900. description: "Return logs from `stdout`"
  7901. type: "boolean"
  7902. default: false
  7903. - name: "stderr"
  7904. in: "query"
  7905. description: "Return logs from `stderr`"
  7906. type: "boolean"
  7907. default: false
  7908. - name: "since"
  7909. in: "query"
  7910. description: "Only return logs since this time, as a UNIX timestamp"
  7911. type: "integer"
  7912. default: 0
  7913. - name: "timestamps"
  7914. in: "query"
  7915. description: "Add timestamps to every log line"
  7916. type: "boolean"
  7917. default: false
  7918. - name: "tail"
  7919. in: "query"
  7920. description: "Only return this number of log lines from the end of the logs. Specify as an integer or `all` to output all log lines."
  7921. type: "string"
  7922. default: "all"
  7923. /secrets:
  7924. get:
  7925. summary: "List secrets"
  7926. operationId: "SecretList"
  7927. produces:
  7928. - "application/json"
  7929. responses:
  7930. 200:
  7931. description: "no error"
  7932. schema:
  7933. type: "array"
  7934. items:
  7935. $ref: "#/definitions/Secret"
  7936. example:
  7937. - ID: "ktnbjxoalbkvbvedmg1urrz8h"
  7938. Version:
  7939. Index: 11
  7940. CreatedAt: "2016-11-05T01:20:17.327670065Z"
  7941. UpdatedAt: "2016-11-05T01:20:17.327670065Z"
  7942. Spec:
  7943. Name: "app-dev.crt"
  7944. 500:
  7945. description: "server error"
  7946. schema:
  7947. $ref: "#/definitions/ErrorResponse"
  7948. 503:
  7949. description: "node is not part of a swarm"
  7950. schema:
  7951. $ref: "#/definitions/ErrorResponse"
  7952. parameters:
  7953. - name: "filters"
  7954. in: "query"
  7955. type: "string"
  7956. description: |
  7957. A JSON encoded value of the filters (a `map[string][]string`) to process on the secrets list. Available filters:
  7958. - `id=<secret id>`
  7959. - `label=<key> or label=<key>=value`
  7960. - `name=<secret name>`
  7961. - `names=<secret name>`
  7962. tags: ["Secret"]
  7963. /secrets/create:
  7964. post:
  7965. summary: "Create a secret"
  7966. operationId: "SecretCreate"
  7967. consumes:
  7968. - "application/json"
  7969. produces:
  7970. - "application/json"
  7971. responses:
  7972. 201:
  7973. description: "no error"
  7974. schema:
  7975. type: "object"
  7976. properties:
  7977. ID:
  7978. description: "The ID of the created secret."
  7979. type: "string"
  7980. example:
  7981. ID: "ktnbjxoalbkvbvedmg1urrz8h"
  7982. 409:
  7983. description: "name conflicts with an existing object"
  7984. schema:
  7985. $ref: "#/definitions/ErrorResponse"
  7986. 500:
  7987. description: "server error"
  7988. schema:
  7989. $ref: "#/definitions/ErrorResponse"
  7990. 503:
  7991. description: "node is not part of a swarm"
  7992. schema:
  7993. $ref: "#/definitions/ErrorResponse"
  7994. parameters:
  7995. - name: "body"
  7996. in: "body"
  7997. schema:
  7998. allOf:
  7999. - $ref: "#/definitions/SecretSpec"
  8000. - type: "object"
  8001. example:
  8002. Name: "app-key.crt"
  8003. Labels:
  8004. foo: "bar"
  8005. Data: "VEhJUyBJUyBOT1QgQSBSRUFMIENFUlRJRklDQVRFCg=="
  8006. tags: ["Secret"]
  8007. /secrets/{id}:
  8008. get:
  8009. summary: "Inspect a secret"
  8010. operationId: "SecretInspect"
  8011. produces:
  8012. - "application/json"
  8013. responses:
  8014. 200:
  8015. description: "no error"
  8016. schema:
  8017. $ref: "#/definitions/Secret"
  8018. example:
  8019. ID: "ktnbjxoalbkvbvedmg1urrz8h"
  8020. Version:
  8021. Index: 11
  8022. CreatedAt: "2016-11-05T01:20:17.327670065Z"
  8023. UpdatedAt: "2016-11-05T01:20:17.327670065Z"
  8024. Spec:
  8025. Name: "app-dev.crt"
  8026. 404:
  8027. description: "secret not found"
  8028. schema:
  8029. $ref: "#/definitions/ErrorResponse"
  8030. 500:
  8031. description: "server error"
  8032. schema:
  8033. $ref: "#/definitions/ErrorResponse"
  8034. 503:
  8035. description: "node is not part of a swarm"
  8036. schema:
  8037. $ref: "#/definitions/ErrorResponse"
  8038. parameters:
  8039. - name: "id"
  8040. in: "path"
  8041. required: true
  8042. type: "string"
  8043. description: "ID of the secret"
  8044. tags: ["Secret"]
  8045. delete:
  8046. summary: "Delete a secret"
  8047. operationId: "SecretDelete"
  8048. produces:
  8049. - "application/json"
  8050. responses:
  8051. 204:
  8052. description: "no error"
  8053. 404:
  8054. description: "secret not found"
  8055. schema:
  8056. $ref: "#/definitions/ErrorResponse"
  8057. 500:
  8058. description: "server error"
  8059. schema:
  8060. $ref: "#/definitions/ErrorResponse"
  8061. 503:
  8062. description: "node is not part of a swarm"
  8063. schema:
  8064. $ref: "#/definitions/ErrorResponse"
  8065. parameters:
  8066. - name: "id"
  8067. in: "path"
  8068. required: true
  8069. type: "string"
  8070. description: "ID of the secret"
  8071. tags: ["Secret"]
  8072. /secrets/{id}/update:
  8073. post:
  8074. summary: "Update a Secret"
  8075. operationId: "SecretUpdate"
  8076. responses:
  8077. 200:
  8078. description: "no error"
  8079. 404:
  8080. description: "no such secret"
  8081. schema:
  8082. $ref: "#/definitions/ErrorResponse"
  8083. 500:
  8084. description: "server error"
  8085. schema:
  8086. $ref: "#/definitions/ErrorResponse"
  8087. 503:
  8088. description: "node is not part of a swarm"
  8089. schema:
  8090. $ref: "#/definitions/ErrorResponse"
  8091. parameters:
  8092. - name: "id"
  8093. in: "path"
  8094. description: "The ID or name of the secret"
  8095. type: "string"
  8096. required: true
  8097. - name: "body"
  8098. in: "body"
  8099. schema:
  8100. $ref: "#/definitions/SecretSpec"
  8101. description: "The spec of the secret to update. Currently, only the Labels field can be updated. All other fields must remain unchanged from the [SecretInspect endpoint](#operation/SecretInspect) response values."
  8102. - name: "version"
  8103. in: "query"
  8104. description: "The version number of the secret object being updated. This is required to avoid conflicting writes."
  8105. type: "integer"
  8106. format: "int64"
  8107. required: true
  8108. tags: ["Secret"]