v1.38.yaml 343 KB

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