Share via


Birden çok kapsayıcılı uygulama ve hizmet bildirimi örnekleri

Aşağıda, çok kapsayıcılı bir Service Fabric uygulaması için uygulama ve hizmet bildirimleri örnekleri verilmiştir. Bu örneklerin amacı, hangi ayarların kullanılabilir olduğunu ve bunların nasıl kullanılacağını göstermektir. Bu uygulama ve hizmet bildirimleri Windows Server 2016 Kapsayıcı Örneği bildirimlerini temel alır.

Aşağıdaki özellikler gösterilir:

Bildirim Özellikler
Uygulama bildirimi ortam değişkenlerini geçersiz kılma, kapsayıcı bağlantı noktasından ana bilgisayara eşlemeyi yapılandırma, kapsayıcı kayıt defteri kimlik doğrulamasını yapılandırma, kaynak idaresi, yalıtım modunu ayarlama, işletim sistemi derlemesine özgü kapsayıcı görüntülerini belirtme
FrontEndService hizmet bildirimi ortam değişkenlerini ayarlama, uç nokta yapılandırma, komutları kapsayıcıya geçirme, bir sertifikayı kapsayıcıya aktarma
BackEndService hizmet bildirimi ortam değişkenlerini ayarlama, uç nokta yapılandırma, birim sürücüsünü yapılandırma

Belirli XML öğeleri hakkında daha fazla bilgi için bkz. Uygulama bildirim öğeleri, FrontEndService hizmet bildirim öğeleri ve BackEndService hizmet bildirim öğeleri .

Uygulama bildirimi

<?xml version="1.0" encoding="utf-8"?>
<ApplicationManifest ApplicationTypeName="Container.ApplicationType"
                     ApplicationTypeVersion="1.0.0"
                     xmlns="http://schemas.microsoft.com/2011/01/fabric"
                     xmlns:xsd="https://www.w3.org/2001/XMLSchema"
                     xmlns:xsi="https://www.w3.org/2001/XMLSchema-instance">
  <Parameters>
    <Parameter Name="BackEndService_InstanceCount" DefaultValue="-1" />
    <Parameter Name="FrontEndService_InstanceCount" DefaultValue="-1" />
    <Parameter Name="CpuCores" DefaultValue="2" />
    <Parameter Name="BlockIOWeight" DefaultValue="200" />
    <Parameter Name="MaximumIOBandwidth" DefaultValue="1024" />
    <Parameter Name="MemoryReservationInMB" DefaultValue="1024" />
    <Parameter Name="MemorySwapInMB" DefaultValue="4084"/>
    <Parameter Name="MaximumIOps" DefaultValue="20"/>
    <Parameter Name="MemoryFront" DefaultValue="4084" />
    <Parameter Name="MemoryBack" DefaultValue="2048" />
    <Parameter Name="CertThumbprint" DefaultValue=""/>
  </Parameters>
  <!-- Import the ServiceManifest from the ServicePackage. The ServiceManifestName and ServiceManifestVersion 
       should match the Name and Version attributes of the ServiceManifest element defined in the 
       ServiceManifest.xml file. -->
  <ServiceManifestImport>
    <ServiceManifestRef ServiceManifestName="BackEndServicePkg" ServiceManifestVersion="1.0.0" />    
    
    <!-- Policies to be applied to the imported service manifest. -->
    <Policies>
      <!-- Set resource governance at the service package level. -->
      <ServicePackageResourceGovernancePolicy CpuCores="[CpuCores]" MemoryInMB="[MemoryFront]"/>

      <!-- Set resource governance at the code package level. -->
      <ResourceGovernancePolicy CodePackageRef="Code" CpuPercent="10" MemoryInMB="[MemoryFront]" BlockIOWeight="[BlockIOWeight]" MaximumIOBandwidth="[MaximumIOBandwidth]" MaximumIOps="[MaximumIOps]" MemoryReservationInMB="[MemoryReservationInMB]" MemorySwapInMB="[MemorySwapInMB]"/>
      
      <!-- Policies for activating container hosts. -->
      <ContainerHostPolicies CodePackageRef="Code" Isolation="process">
        
        <!-- Credentials for the repository hosting the container image.-->
        <RepositoryCredentials AccountName="sfsamples" Password="ENCRYPTED-PASSWORD" PasswordEncrypted="true"/>
        
        <!-- This binds the port the container is listening on (8905 in this sample) to an endpoint resource named "BackEndServiceTypeEndpoint", which is defined in the service manifest.  -->
        <PortBinding ContainerPort="8905" EndpointRef="BackEndServiceTypeEndpoint"/>
        
        <!-- Configure the Azure Files volume plugin.  Bind the source folder on the host VM or a remote share to the destination folder within the running container. -->
        <Volume Source="azfiles" Destination="c:\VolumeTest\Data" Driver="sfazurefile">
          <!-- Driver options to be passed to driver. The Azure Files volume plugin supports the following driver options:
            shareName (the Azure Files file share that provides the volume for the container), storageAccountName (the Azure storage account
            that contains the Azure Files file share), storageAccountKey (Access key for the Azure storage account that contains the Azure Files file share).
            These three driver options are required. -->
          <DriverOption Name="shareName" Value="" />
          <DriverOption Name="storageAccountName" Value="MY-STORAGE-ACCOUNT-NAME" />
          <DriverOption Name="storageAccountKey" Value="MY-STORAGE-ACCOUNT-KEY" />
        </Volume>
        
        <!-- Windows Server containers may not be compatible across different versions of the OS.  You can specify multiple OS images per container and tag 
        them with the build versions of the OS. Get the build version of the OS by running "winver" at a Windows command prompt. -->
        <ImageOverrides>
          <!-- If the underlying OS is build version 16299 (Windows Server version 1709), Service Fabric picks the container image tagged with Os="16299". -->
          <Image Name="sfsamples.azurecr.io/sfsamples/servicefabricbackendservice_1709" Os="16299" />
          
          <!-- An untagged container image is assumed to work across all versions of the OS and overrides the image specified in the service manifest. -->
          <Image Name="sfsamples.azurecr.io/sfsamples/servicefabricbackendservice_default" />          
        </ImageOverrides>
      </ContainerHostPolicies>
    </Policies>
  </ServiceManifestImport>

  <!-- Policies to be applied to the imported service manifest. -->
  <ServiceManifestImport>
    <ServiceManifestRef ServiceManifestName="FrontEndServicePkg" ServiceManifestVersion="1.0.0" />
    
    <!-- This enables you to provide different values for environment variables when creating a FrontEndService
         Theses environment variables are declared in the FrontEndServiceType service manifest-->
    <EnvironmentOverrides CodePackageRef="Code">
      <EnvironmentVariable Name="BackendServiceName" Value="Container.Application/BackEndService"/>
      <EnvironmentVariable Name="HttpGatewayPort" Value="19080"/>
      <EnvironmentVariable Name="IsContainer" Value="true"/>
    </EnvironmentOverrides>
    
    <!-- This policy maps the  port of the container (80) to the endpoint declared in the service, 
         FrontEndServiceTypeEndpoint which is exposed as port 80 on the host-->    
    <Policies>

      <!-- Set resource governance at the service package level. -->
      <ServicePackageResourceGovernancePolicy CpuCores="[CpuCores]" MemoryInMB="[MemoryBack]"/>

      <!-- Policies for activating container hosts. -->
      <ContainerHostPolicies CodePackageRef="Code" Isolation="process">

        <!-- Credentials for the repository hosting the container image.-->
        <RepositoryCredentials AccountName="sfsamples" Password="ENCRYPTED-PASSWORD" PasswordEncrypted="true"/>

        <!-- Binds an endpoint resource (declared in the service manifest) to the exposed container port. -->
        <PortBinding ContainerPort="80" EndpointRef="FrontEndServiceTypeEndpoint"/>

        <!-- Import a certificate into the container.  The certificate must be installed in the LocalMachine store of all the cluster nodes.
          When the application starts, the runtime reads the certificate and generates a PFX file and password (on Windows) or a PEM file (on Linux).
          The PFX file and password are accessible in the container using the Certificates_ServicePackageName_CodePackageName_CertName_PFX and 
          Certificates_ServicePackageName_CodePackageName_CertName_Password environment variables. The PEM file is accessible in the container using the 
          Certificates_ServicePackageName_CodePackageName_CertName_PEM and Certificates_ServicePackageName_CodePackageName_CertName_PrivateKey environment variables.-->
        <CertificateRef Name="MyCert1" X509StoreName="My" X509FindValue="[CertThumbprint]" />

        <!-- If the certificate is already in PFX or PEM form, you can create a data package inside your application and reference that certificate here. -->
        <CertificateRef Name="MyCert2" DataPackageRef="Data" DataPackageVersion="1.0.0" RelativePath="MyCert2.PFX" Password="ENCRYPTED-PASSWORD" IsPasswordEncrypted="true"/>
      </ContainerHostPolicies>
    </Policies>
  </ServiceManifestImport>
  
  <DefaultServices>
    <!-- The section below creates instances of service types, when an instance of this 
         application type is created. You can also create one or more instances of service type using the 
         ServiceFabric PowerShell module.
         
         The attribute ServiceTypeName below must match the name defined in the imported ServiceManifest.xml file. -->
        
    <Service Name="FrontEndService" >
      <StatelessService ServiceTypeName="FrontEndServiceType" InstanceCount="[FrontEndService_InstanceCount]">
        <SingletonPartition />
      </StatelessService>
    </Service>
        <Service Name="BackEndService" ServicePackageActivationMode="ExclusiveProcess">
      <StatelessService ServiceTypeName="BackEndServiceType" InstanceCount="[BackEndService_InstanceCount]">
        <SingletonPartition />
      </StatelessService>
    </Service>
  </DefaultServices>
</ApplicationManifest>

FrontEndService hizmet bildirimi

<?xml version="1.0" encoding="utf-8"?>
<ServiceManifest Name="FrontEndServicePkg"
                 Version="1.0.0"
                 xmlns="http://schemas.microsoft.com/2011/01/fabric"
                 xmlns:xsd="https://www.w3.org/2001/XMLSchema"
                 xmlns:xsi="https://www.w3.org/2001/XMLSchema-instance">
  <ServiceTypes>
    <!-- This is the name of your ServiceType.
         The UseImplicitHost attribute indicates this is a guest service. -->
    <StatelessServiceType ServiceTypeName="FrontEndServiceType" UseImplicitHost="true" />
  </ServiceTypes>

  <!-- Code package is your service executable. -->
  <CodePackage Name="Code" Version="1.0.0">
    <EntryPoint>
      <ContainerHost>
        <!--The repo and image on https://hub.docker.com or Azure Container Registry. -->
        <ImageName>sfsamples.azurecr.io/sfsamples/servicefabricfrontendservice:v1</ImageName>
      </ContainerHost>
    </EntryPoint>
    <!-- Pass environment variables to your container or exe.  These variables are overridden in the application manifest. -->
    <EnvironmentVariables>
      <EnvironmentVariable Name="BackendServiceName" Value=""/>
      <EnvironmentVariable Name="HttpGatewayPort" Value=""/>
      <EnvironmentVariable Name="IsContainer" Value=""/>
    </EnvironmentVariables>
  </CodePackage>

  <!-- Config package is the contents of the Config directory under PackageRoot that contains an 
       independently-updateable and versioned set of custom configuration settings for your service. -->
  <ConfigPackage Name="Config" Version="1.0.0" />
  
  <!-- Data package is the contents of the Data directory under PackageRoot that contains an 
       independently-updateable and versioned static data that's consumed by the process at runtime. -->
  <DataPackage Name="Data" Version="1.0.0"/>

  <Resources>
    <Endpoints>
      <!-- This endpoint is used by the communication listener to obtain the port on which to 
           listen. For a guest executable is used to register with the NamingService at its REST endpoint
           with http scheme and port 80 -->
      <Endpoint Name="FrontEndServiceTypeEndpoint" UriScheme="http" Port="80"/>
    </Endpoints>
  </Resources>
</ServiceManifest>

BackEndService hizmet bildirimi

<?xml version="1.0" encoding="utf-8"?>
<ServiceManifest Name="BackEndServicePkg"
                 Version="1.0.0"
                 xmlns="http://schemas.microsoft.com/2011/01/fabric"
                 xmlns:xsd="https://www.w3.org/2001/XMLSchema"
                 xmlns:xsi="https://www.w3.org/2001/XMLSchema-instance">
  <ServiceTypes>
    <!-- This is the name of your ServiceType.
         The UseImplicitHost attribute indicates this is a guest service. -->
    <StatelessServiceType ServiceTypeName="BackEndServiceType" UseImplicitHost="true" />
  </ServiceTypes>

  <!-- Code package is your service executable. -->
  <CodePackage Name="Code" Version="1.0.0">
    <EntryPoint>
      <ContainerHost>
        <!--The repo and image on https://hub.docker.com or Azure Container Registry. -->
        <ImageName>sfsamples.azurecr.io/sfsamples/servicefabricbackendservice:v1</ImageName>
        
        <!-- Pass comma delimited commands to your container. -->
        <Commands> dotnet, myproc.dll, 5 </Commands>
      </ContainerHost>
    </EntryPoint>
    <!-- Pass environment variables to your container. These variables are overridden in the application manifest. -->
    <EnvironmentVariables>
      <EnvironmentVariable Name="IsContainer" Value="true"/>
    </EnvironmentVariables>
  </CodePackage>

  <!-- Config package is the contents of the Config directory under PackageRoot that contains an 
       independently-updateable and versioned set of custom configuration settings for your service. -->
  <ConfigPackage Name="Config" Version="1.0.0" />

  <Resources>
    <Endpoints>
      <!-- This endpoint is used by the communication listener to obtain the host port on which to 
           listen. For a guest executable is used to register with the NamingService at its REST endpoint
           with http scheme. In this case since no port is specified, one is created and assigned dynamically
           to the service. This dynamically assigned host port is mapped to the container port (8905 in this sample),
            which was specified in the application manifest.-->
      <Endpoint Name="BackEndServiceTypeEndpoint" UriScheme="http" />
    </Endpoints>
  </Resources>
</ServiceManifest>

Uygulama bildirim öğeleri

ApplicationManifest Öğesi

Uygulama türünü ve sürümünü bildirimli olarak açıklar. Uygulama türü oluşturmak için bir veya daha fazla hizmet bildirimine başvurulur. Bağlı hizmetlerin yapılandırma ayarları, parametreli uygulama ayarları kullanılarak geçersiz kılınabilir. Varsayılan hizmetler, hizmet şablonları, sorumlular, ilkeler, tanılama kurulumu ve sertifikalar da uygulama düzeyinde bildirilebilir. Daha fazla bilgi için bkz. ApplicationManifest Öğesi

Parameters Öğesi

Bu uygulama bildiriminde kullanılan parametreleri bildirir. Bu parametrelerin değeri, uygulama örneği oluşturulurken sağlanabilir ve uygulama veya hizmet yapılandırma ayarlarını geçersiz kılmak için kullanılabilir. Daha fazla bilgi için bkz . Parameters Öğesi

Parameter Öğesi

Bu bildirimde kullanılacak bir uygulama parametresi. Parametre değeri uygulama örneği oluşturma sırasında değiştirilebilir veya değer sağlanmazsa varsayılan değer kullanılır. Daha fazla bilgi için bkz . Parametre Öğesi

ServiceManifestImport Öğesi

Hizmet geliştiricisi tarafından oluşturulan bir hizmet bildirimini içeri aktarır. Uygulamadaki her bir bağlı hizmet için bir hizmet bildirimi içeri aktarılmalıdır. Hizmet bildirimi için yapılandırma geçersiz kılmaları ve ilkeleri bildirilebilir. Daha fazla bilgi için bkz . ServiceManifestImport Öğesi

ServiceManifestRef Öğesi

Hizmet bildirimini başvuruya göre içeri aktarır. Şu anda hizmet bildirim dosyası (ServiceManifest.xml) derleme paketinde mevcut olmalıdır. Daha fazla bilgi için bkz . ServiceManifestRef Öğesi

İlkeler Öğesi

İçeri aktarılan hizmet bildirimine uygulanacak ilkeleri (uç nokta bağlaması, paket paylaşımı, farklı çalıştır ve güvenlik erişimi) açıklar. Daha fazla bilgi için bkz. İlkeler Öğesi

ServicePackageResourceGovernancePolicy Öğesi

Hizmet paketinin tamamı düzeyinde uygulanan kaynak idare ilkesini tanımlar. Daha fazla bilgi için bkz . ServicePackageResourceGovernancePolicy Öğesi

ResourceGovernancePolicy Öğesi

Kod paketi için kaynak sınırlarını belirtir. Daha fazla bilgi için bkz . ResourceGovernancePolicy Öğesi

ContainerHostPolicies Öğesi

Kapsayıcı konaklarını etkinleştirme ilkelerini belirtir. Daha fazla bilgi için bkz . ContainerHostPolicies Öğesi

RepositoryCredentials Öğesi

Görüntüleri çekebilmek için kapsayıcı görüntüsü deposunun kimlik bilgileri. Daha fazla bilgi için bkz . RepositoryCredentials Öğesi

PortBinding Öğesi

Kullanıma sunulan kapsayıcı bağlantı noktasına hangi uç nokta kaynağının bağlanacağını belirtir. Daha fazla bilgi için bkz . PortBinding Öğesi

Volume Öğesi

Kapsayıcıya bağlanacak birimi belirtir. Daha fazla bilgi için bkz . Birim Öğesi

DriverOption Öğesi

Sürücüye geçirilecek sürücü seçenekleri. Daha fazla bilgi için bkz . DriverOption Öğesi

ImageOverrides Öğesi

Windows Server kapsayıcıları, işletim sisteminin farklı sürümleri arasında uyumlu olmayabilir. Kapsayıcı başına birden çok işletim sistemi görüntüsü belirtebilir ve bunları işletim sisteminin derleme sürümleriyle etiketleyebilirsiniz. Windows komut isteminde "winver" komutunu çalıştırarak işletim sisteminin derleme sürümünü alın. Temel alınan işletim sistemi derleme sürümü 16299 (Windows Server sürüm 1709) ise, Service Fabric Os="16299" ile etiketlenen kapsayıcı görüntüsünü seçer. Etiketsiz bir kapsayıcı görüntüsünün işletim sisteminin tüm sürümlerinde çalıştığı varsayılır ve hizmet bildiriminde belirtilen görüntüyü geçersiz kılar. Daha fazla bilgi için bkz . ImageOverrides Öğesi

Image Öğesi

Başlatılacak işletim sistemi derleme sürüm numarasına karşılık gelen kapsayıcı görüntüsü. İşletim sistemi özniteliği belirtilmezse, kapsayıcı görüntüsünün işletim sisteminin tüm sürümlerinde çalıştığı varsayılır ve hizmet bildiriminde belirtilen görüntüyü geçersiz kılar. Daha fazla bilgi için bkz . Görüntü Öğesi

EnvironmentOverrides Öğesi

Daha fazla bilgi için bkz . EnvironmentOverrides Öğesi

EnvironmentVariable Öğesi

Ortam değişkeni. Daha fazla bilgi için bkz . EnvironmentVariable Öğesi

CertificateRef Öğesi

Kapsayıcı ortamına sunulacak bir X509 sertifikası hakkındaki bilgileri belirtir. Sertifika, tüm küme düğümlerinin LocalMachine deposuna yüklenmelidir. Uygulama başlatıldığında, çalışma zamanı sertifikayı okur ve bir PFX dosyası ve parolası (Windows'da) veya pem dosyası (Linux'ta) oluşturur. PFX dosyasına ve parolasına kapsayıcıda Certificates_ServicePackageName_CodePackageName_CertName_PFX ve Certificates_ServicePackageName_CodePackageName_CertName_Password ortam değişkenleri kullanılarak erişilebilir. PEM dosyasına kapsayıcıda Certificates_ServicePackageName_CodePackageName_CertName_PEM ve Certificates_ServicePackageName_CodePackageName_CertName_PrivateKey ortam değişkenleri kullanılarak erişilebilir. Daha fazla bilgi için bkz . CertificateRef Öğesi

DefaultServices Öğesi

Bu uygulama türüne göre bir uygulama örneği her başlatıldığında otomatik olarak oluşturulan hizmet örneklerini bildirir. Daha fazla bilgi için bkz . DefaultServices Öğesi

Service Öğesi

Uygulama örneği oluşturulurken otomatik olarak oluşturulacak bir hizmet bildirir. Daha fazla bilgi için bkz . Service Öğesi

StatelessService Öğesi

Durum bilgisi olmayan bir hizmet tanımlar. Daha fazla bilgi için bkz . StatelessService Öğesi

FrontEndService hizmet bildirim öğeleri

ServiceManifest Öğesi

Hizmet türünü ve sürümünü bildirimli olarak açıklar. Bir veya daha fazla hizmet türünü desteklemek için bir hizmet paketi oluşturan bağımsız olarak yükseltilebilir kodu, yapılandırmayı ve veri paketlerini listeler. Kaynaklar, tanılama ayarları ve hizmet türü, sistem durumu özellikleri ve yük dengeleme ölçümleri gibi hizmet meta verileri de belirtilir. Daha fazla bilgi için bkz . ServiceManifest Öğesi

ServiceTypes Öğesi

Bu bildirimde CodePackage tarafından desteklenen hizmet türlerini tanımlar. Bir hizmet bu hizmet türlerinden birinde örneklendiğinde, bu bildirimde bildirilen tüm kod paketleri kendi giriş noktaları çalıştırılarak etkinleştirilir. Hizmet türleri, kod paketi düzeyinde değil bildirim düzeyinde bildirilir. Daha fazla bilgi için bkz. ServiceTypes Öğesi

StatelessServiceType Öğesi

Durum bilgisi olmayan bir hizmet türünü açıklar. Daha fazla bilgi için bkz . StatelessServiceType Öğesi

CodePackage Öğesi

Tanımlı bir hizmet türünü destekleyen bir kod paketini açıklar. Bir hizmet bu hizmet türlerinden birinde örneklendiğinde, bu bildirimde bildirilen tüm kod paketleri kendi giriş noktaları çalıştırılarak etkinleştirilir. Sonuçta elde edilen işlemlerin çalışma zamanında desteklenen hizmet türlerini kaydetmesi beklenir. Birden çok kod paketi olduğunda, sistem bildirilen hizmet türlerinden birini her ararken bunların tümü etkinleştirilir. Daha fazla bilgi için bkz. CodePackage Öğesi

EntryPoint Öğesi

EntryPoint tarafından belirtilen yürütülebilir dosya genellikle uzun süre çalışan hizmet konağıdır. Ayrı bir kurulum giriş noktasının varlığı, hizmet ana bilgisayarını uzun süreler boyunca yüksek ayrıcalıklarla çalıştırmak zorunda kalmaktan kaçınıyor. EntryPoint tarafından belirtilen yürütülebilir dosya, SetupEntryPoint başarıyla çıktıktan sonra çalıştırılır. Sonuçta elde edilen işlem, sonlandırılırsa veya kilitlenirse izlenir ve yeniden başlatılır (SetupEntryPoint ile yeniden başlatılır). Daha fazla bilgi için bkz . EntryPoint Öğesi

ContainerHost Öğesi

Daha fazla bilgi için bkz. ContainerHost Öğesi

ImageName Öğesi

Depo ve görüntü veya https://hub.docker.com Azure Container Registry. Daha fazla bilgi için bkz . ImageName Öğesi

EnvironmentVariables Öğesi

Ortam değişkenlerini kapsayıcınıza veya exe'nize geçirin. Daha fazla bilgi için bkz . EnvironmentVariables Öğesi

EnvironmentVariable Öğesi

Ortam değişkeni. Daha fazla bilgi için bkz . EnvironmentVariable Öğesi

ConfigPackage Öğesi

Name özniteliği tarafından adlandırılan ve Settings.xml dosyası içeren bir klasör bildirir. Bu dosya, işlemin çalışma zamanında geri okuyabileceği kullanıcı tanımlı anahtar-değer çifti ayarlarının bölümlerini içerir. Yükseltme sırasında yalnızca ConfigPackage sürümü değiştiyse, çalışan işlem yeniden başlatılmaz. Bunun yerine, geri arama yapılandırma ayarlarının dinamik olarak yeniden yüklenebilmesi için değiştirildiğini işleme bildirir. Daha fazla bilgi için bkz . ConfigPackage Öğesi

DataPackage Öğesi

Statik veri dosyalarını içeren Name özniteliği tarafından adlandırılan bir klasör bildirir. Service Fabric, hizmet bildiriminde listelenen veri paketlerinden herhangi biri yükseltildiğinde konakta ve destek paketlerinde belirtilen tüm EXE'leri ve DLLHOST'leri geri dönüştürecektir. Daha fazla bilgi için bkz . DataPackage Öğesi

Resources Öğesi

Bu hizmet tarafından kullanılan ve derlenmiş kod değiştirilmeden bildirilebilen ve hizmet dağıtıldığında değiştirilebilen kaynakları açıklar. Bu kaynaklara erişim, uygulama bildiriminin Sorumlular ve İlkeler bölümleri aracılığıyla denetlenmektedir. Daha fazla bilgi için bkz . Resources Öğesi

Endpoints Öğesi

Hizmet için uç noktaları tanımlar. Daha fazla bilgi için bkz . Endpoints Öğesi

Endpoint Öğesi

Daha fazla bilgi için bkz . Endpoint Öğesi

BackEndService hizmet bildirim öğeleri

ServiceManifest Öğesi

Hizmet türünü ve sürümünü bildirimli olarak açıklar. Bir veya daha fazla hizmet türünü desteklemek için bir hizmet paketi oluşturan bağımsız olarak yükseltilebilir kodu, yapılandırmayı ve veri paketlerini listeler. Kaynaklar, tanılama ayarları ve hizmet türü, sistem durumu özellikleri ve yük dengeleme ölçümleri gibi hizmet meta verileri de belirtilir. Daha fazla bilgi için bkz . ServiceManifest Öğesi

ServiceTypes Öğesi

Bu bildirimde CodePackage tarafından desteklenen hizmet türlerini tanımlar. Bir hizmet bu hizmet türlerinden birinde örneklendiğinde, bu bildirimde bildirilen tüm kod paketleri kendi giriş noktaları çalıştırılarak etkinleştirilir. Hizmet türleri, kod paketi düzeyinde değil bildirim düzeyinde bildirilir. Daha fazla bilgi için bkz. ServiceTypes Öğesi

StatelessServiceType Öğesi

Durum bilgisi olmayan bir hizmet türünü açıklar. Daha fazla bilgi için bkz . StatelessServiceType Öğesi

CodePackage Öğesi

Tanımlı bir hizmet türünü destekleyen bir kod paketini açıklar. Bir hizmet bu hizmet türlerinden birinde örneklendiğinde, bu bildirimde bildirilen tüm kod paketleri kendi giriş noktaları çalıştırılarak etkinleştirilir. Sonuçta elde edilen işlemlerin çalışma zamanında desteklenen hizmet türlerini kaydetmesi beklenir. Birden çok kod paketi olduğunda, sistem bildirilen hizmet türlerinden birini her ararken bunların tümü etkinleştirilir. Daha fazla bilgi için bkz. CodePackage Öğesi

EntryPoint Öğesi

EntryPoint tarafından belirtilen yürütülebilir dosya genellikle uzun süre çalışan hizmet konağıdır. Ayrı bir kurulum giriş noktasının varlığı, hizmet ana bilgisayarını uzun süreler boyunca yüksek ayrıcalıklarla çalıştırmak zorunda kalmaktan kaçınıyor. EntryPoint tarafından belirtilen yürütülebilir dosya, SetupEntryPoint başarıyla çıktıktan sonra çalıştırılır. Sonuçta elde edilen işlem, sonlandırılırsa veya kilitlenirse izlenir ve yeniden başlatılır (SetupEntryPoint ile yeniden başlatılır). Daha fazla bilgi için bkz . EntryPoint Öğesi

ContainerHost Öğesi

Daha fazla bilgi için bkz. ContainerHost Öğesi

ImageName Öğesi

Depo ve görüntü veya https://hub.docker.com Azure Container Registry. Daha fazla bilgi için bkz . ImageName Öğesi

Commands Öğesi

Kapsayıcıya virgülle ayrılmış komut listesi geçirin. Daha fazla bilgi için bkz . Commands Öğesi

EnvironmentVariables Öğesi

Ortam değişkenlerini kapsayıcınıza veya exe'nize geçirin. Daha fazla bilgi için bkz . EnvironmentVariables Öğesi

EnvironmentVariable Öğesi

Ortam değişkeni. Daha fazla bilgi için bkz . EnvironmentVariable Öğesi

ConfigPackage Öğesi

Name özniteliği tarafından adlandırılan ve Settings.xml dosyası içeren bir klasör bildirir. Bu dosya, işlemin çalışma zamanında geri okuyabileceği kullanıcı tanımlı anahtar-değer çifti ayarlarının bölümlerini içerir. Yükseltme sırasında yalnızca ConfigPackage sürümü değiştiyse, çalışan işlem yeniden başlatılmaz. Bunun yerine, geri arama yapılandırma ayarlarının dinamik olarak yeniden yüklenebilmesi için değiştirildiğini işleme bildirir. Daha fazla bilgi için bkz . ConfigPackage Öğesi

Resources Öğesi

Derlenmiş kod değiştirilmeden bildirilebilen ve hizmet dağıtıldığında değiştirilebilen bu hizmet tarafından kullanılan kaynakları açıklar. Bu kaynaklara erişim, uygulama bildiriminin Sorumlular ve İlkeler bölümleri aracılığıyla denetlenmektedir. Daha fazla bilgi için bkz . Resources Öğesi

Endpoints Öğesi

Hizmet için uç noktaları tanımlar. Daha fazla bilgi için bkz . Endpoints Öğesi

Endpoint Öğesi

Daha fazla bilgi için bkz . Endpoint Öğesi