Server IP : 209.38.156.173 / Your IP : 216.73.216.122 [ Web Server : Apache/2.4.52 (Ubuntu) System : Linux lakekumayuhotel 5.15.0-136-generic #147-Ubuntu SMP Sat Mar 15 15:53:30 UTC 2025 x86_64 User : root ( 0) PHP Version : 8.1.2-1ubuntu2.22 Disable Function : NONE Domains : 2 Domains MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /lib/python3/dist-packages/cloudinit/net/__pycache__/ |
Upload File : |
o x[h� � @ sZ d dl Z d dlZd dlZd dlmZmZmZ e �e�Z G dd� dejj j�Zddd�Z dS )� N)�net�subp�utilc @ s( e Zd Zd dd�Zd dd�Zdd� ZdS )�RendererNc C s� | j �� D ]U\}}d�|�}t�| j|�}|| �� v rd}n6t|t�rTz dj|d |d d�}W n t y? t �d|� Y nw |�d�}|rM|d | 7 }|d | j 7 }t�||� qd S )Nzetc/hostname.{}zdhcp zinet {address} {netmask}�address�netmask)r r z#Invalid static configuration for %s�mtuz mtu %d� )�interface_configurations�items�formatr �target_path�target�dhcp_interfaces� isinstance�dict�KeyError�LOG�error�get�interface_routesr � write_file)�selfr �device_name�v�if_file�fn�contentr � r �7/usr/lib/python3/dist-packages/cloudinit/net/openbsd.py�write_config s* ��� �zRenderer.write_configFc C s� t tt�� �d�d �dk�}| jst�d� d S |r8tjddgdd� | � � D ] }tjd d d|gdd� q(d S t jj� � tjg d�ddd gd� tjg d�ddd gd� tjddgdd� d S )N�.r � z!openbsd generate postcmd disabled�shz /etc/netstartT)�capture�dhcpleasectlz-w�30)�route�del�default� )r$ �rcs)r'