v1.26.yaml 254 KB

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