k8s.io/test-infra@v0.0.0-20240520184403-27c6b4c223d8/jobs/e2e_node/crio/templates/crio_cgroupsv1_hugepages.yaml (about)

     1  ---
     2  variant: fcos
     3  version: 1.4.0
     4  kernel_arguments:
     5    should_not_exist:
     6      - mitigations=auto,nosmt
     7    should_exist:
     8      - systemd.unified_cgroup_hierarchy=0
     9  storage:
    10    files:
    11      - path: /etc/zincati/config.d/90-disable-auto-updates.toml
    12        contents:
    13          local: 90-disable-auto-updates.toml
    14        mode: 0644
    15      - path: /root/kubelet-e2e.te
    16        contents:
    17          local: kubelet-e2e.te
    18        mode: 0644
    19      - path: /etc/crio/crio.conf.d/crio.conf
    20        contents:
    21          local: crio.conf
    22        mode: 0644
    23      - path: /etc/sysctl.d/99-e2e-sysctl.conf
    24        contents:
    25          local: 99-e2e-sysctl.conf
    26        mode: 0644
    27      - path: /etc/ssh-key-secret/ssh-public
    28        contents:
    29          # base64 encoded "GCE_SSH_PUBLIC_KEY_FILE_CONTENT"
    30          source: data:text/plain;base64,R0NFX1NTSF9QVUJMSUNfS0VZX0ZJTEVfQ09OVEVOVA==
    31        mode: 0644
    32  systemd:
    33    units:
    34      - name: configure-sysctl.service
    35        enabled: true
    36        contents: |
    37          [Unit]
    38          Description=Configure required sysctls.
    39  
    40          [Service]
    41          Type=oneshot
    42          ExecStart=/usr/lib/systemd/systemd-sysctl
    43  
    44          [Install]
    45          WantedBy=multi-user.target
    46      - name: tools-install.service
    47        enabled: true
    48        contents: |
    49          [Unit]
    50          Description=Download and install required tools.
    51          Before=crio-install.service
    52          After=NetworkManager-wait-online.service
    53  
    54          [Service]
    55          Type=oneshot
    56          ExecStart=rpm-ostree install \
    57            -y \
    58            --apply-live \
    59            --allow-inactive \
    60            dbus-tools \
    61            checkpolicy
    62  
    63          [Install]
    64          WantedBy=multi-user.target
    65      - name: selinux-install.service
    66        enabled: true
    67        contents: |
    68          [Unit]
    69          Description=Setup SELinux policy
    70          After=tools-install.service
    71  
    72          [Service]
    73          Type=oneshot
    74          ExecStartPre=setenforce 1
    75          ExecStartPre=checkmodule -M -m -o /root/kubelet-e2e.mod /root/kubelet-e2e.te
    76          ExecStartPre=semodule_package -o /root/kubelet-e2e.pp -m /root/kubelet-e2e.mod
    77          ExecStartPre=semodule -i /root/kubelet-e2e.pp
    78          ExecStartPre=mkdir -p /var/lib/kubelet
    79          ExecStart=chcon -R -u system_u -r object_r -t var_lib_t /var/lib/kubelet
    80  
    81          [Install]
    82          WantedBy=multi-user.target
    83      - name: crio-install.service
    84        enabled: true
    85        contents: |
    86          [Unit]
    87          Description=Download and install crio binaries and configurations.
    88          After=selinux-install.service
    89  
    90          [Service]
    91          Type=oneshot
    92          Environment="SCRIPT_COMMIT=3e02ed6de9f516af9d8884c06ee3d709b2fa413d"
    93          Environment="CRIO_COMMIT=v1.30.0"
    94  
    95          ExecStartPre=mount /tmp /tmp -o remount,exec,suid
    96          ExecStartPre=mount -o remount,rw /dev/sda4 /usr
    97          ExecStartPre=bash -c '\
    98            curl --fail --retry 5 --retry-delay 3 --silent --show-error \
    99              https://raw.githubusercontent.com/cri-o/packaging/$SCRIPT_COMMIT/get |\
   100                bash -s -- -t $CRIO_COMMIT'
   101          ExecStartPre=rm -f /etc/cni/net.d/87-podman-bridge.conflist
   102          ExecStartPre=rm -f /etc/crio/crio.conf.d/10-crio.conf
   103          ExecStart=systemctl enable --now crio.service
   104  
   105          [Install]
   106          WantedBy=multi-user.target
   107      - name: authorized-key.service
   108        enabled: true
   109        contents: |
   110          [Unit]
   111          Description=Copy authorized keys
   112          Before=crio-install.service
   113          After=NetworkManager-wait-online.service
   114  
   115          [Service]
   116          Type=oneshot
   117          ExecStart=/bin/sh -c '\
   118            /usr/bin/mkdir -m 0700 -p /home/core/.ssh && \
   119            /usr/bin/cat /etc/ssh-key-secret/ssh-public \
   120              >> /home/core/.ssh/authorized_keys && \
   121            /usr/bin/chown -R core:core /home/core/.ssh && \
   122            /usr/bin/chmod 0600 /home/core/.ssh/authorized_keys'
   123  
   124          [Install]
   125          WantedBy=multi-user.target
   126      - name: allocate-1G-hugepages.service
   127        enabled: true
   128        contents: |
   129          [Unit]
   130          Description=Allocate 1G hugepages.
   131          After=network-online.target
   132  
   133          [Service]
   134          Type=oneshot
   135          ExecStart=/bin/sh -c '/usr/bin/echo 1 > \
   136            /sys/kernel/mm/hugepages/hugepages-1048576kB/nr_hugepages'
   137  
   138          [Install]
   139          WantedBy=multi-user.target