Defaults to false. When false, files are subject to validations based on the file type: Remote: A checksum must be specified. Cloud Storage: An object generation number must be specified.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-09-04 UTC."],[],[],null,["# Google Cloud OsConfig V1 Client - Class File (2.1.0)\n\nVersion latestkeyboard_arrow_down\n\n- [2.1.0 (latest)](/php/docs/reference/cloud-osconfig/latest/V1.OSPolicy.Resource.File)\n- [2.0.5](/php/docs/reference/cloud-osconfig/2.0.5/V1.OSPolicy.Resource.File)\n- [1.3.5](/php/docs/reference/cloud-osconfig/1.3.5/V1.OSPolicy.Resource.File)\n- [1.2.2](/php/docs/reference/cloud-osconfig/1.2.2/V1.OSPolicy.Resource.File)\n- [1.1.1](/php/docs/reference/cloud-osconfig/1.1.1/V1.OSPolicy.Resource.File)\n- [1.0.5](/php/docs/reference/cloud-osconfig/1.0.5/V1.OSPolicy.Resource.File) \nReference documentation and code samples for the Google Cloud OsConfig V1 Client class File.\n\nA remote or local file.\n\nGenerated from protobuf message `google.cloud.osconfig.v1.OSPolicy.Resource.File`\n\nNamespace\n---------\n\nGoogle \\\\ Cloud \\\\ OsConfig \\\\ V1 \\\\ OSPolicy \\\\ Resource\n\nMethods\n-------\n\n### __construct\n\nConstructor.\n\n### getRemote\n\nA generic remote file.\n\n### hasRemote\n\n### setRemote\n\nA generic remote file.\n\n### getGcs\n\nA Cloud Storage object.\n\n### hasGcs\n\n### setGcs\n\nA Cloud Storage object.\n\n### getLocalPath\n\nA local path within the VM to use.\n\n### hasLocalPath\n\n### setLocalPath\n\nA local path within the VM to use.\n\n### getAllowInsecure\n\nDefaults to false. When false, files are subject to validations\nbased on the file type:\nRemote: A checksum must be specified.\n\nCloud Storage: An object generation number must be specified.\n\n### setAllowInsecure\n\nDefaults to false. When false, files are subject to validations\nbased on the file type:\nRemote: A checksum must be specified.\n\nCloud Storage: An object generation number must be specified.\n\n### getType"]]