
442 So.2d 836 (1983)
Joe SIMMONS
v.
BOARD OF COMMISSIONERS FOR the PORT OF NEW ORLEANS.
No. CA 0917.
Court of Appeal of Louisiana, Fourth Circuit.
December 9, 1983.
*837 J. Paul Demarest, T.A., New Orleans, for plaintiff-appellant.
Paul B. Deal, Jerald L. Album, New Orleans, for defendant-appellee.
Before REDMANN, C.J., and CIACCIO and WILLIAMS, JJ.
CIACCIO, Judge.
The trial court rendered summary judgment in favor of defendant. Plaintiff has appealed. We affirm.
Plaintiff-appellant, Joe Simmons, alleged that he sustained injuries when a gate collapsed and fell on him while he was working at the Desire Street wharf as a longshoreman for Atlantic & Gulf Stevedores, Inc. Plaintiff sued the Board of Commissioners of the Port of New Orleans alleging that the Dock Board owned the gate. Relying on the provisions of La.C.C. Arts. 2315, 2317 and 2322, plaintiff's petition base liability on the alleged negligence of the Dock Board as owners of the gate.
The Dock Board answered plaintiff's petition by denying ownership of the gate. The Dock Board further answered by alleging that the gate was built, owned and operated by plaintiff's employer, Atlantic & Gulf Stevedores.
During discovery proceedings, depositions were taken from Al Hansen, Superintendent of Gear and Equipment for A & G, and Leonard Spalluto, chief of the Maintenance Division for the Dock Board. These two depositions along with some other documentary evidence, affidavits, and some photographs were placed in the record in connection with the hearing on the Dock Board's motion for summary judgment. After considering the evidence, the trial judge granted defendant's motion.
Plaintiff argues on appeal that the trial judge erred in granting summary judgment because there is a genuine issue as to material fact which should be resolved by a trial on the merits. Plaintiff-appellant contends that the facts concerning ownership, custody and control of the gate remain in dispute. The trial judge apparently found no genuine factual issue concerning the gate, and, neither do we.
La.C.C.P. Art. 966 provides that summary judgment shall be granted if the pleadings, depositions, answers to interrogatories, and admissions on file, together with the affidavits, if any, show there is no genuine issue as to material fact, and that mover is entitled to judgment as a matter of law.
The evidence introduced in connection with the motion for summary judgment established that Atlantic and Gulf used the Desire Street wharf pursuant to a "Grant of First Call on Berth Privilege" issued by the Dock Board. The Grant incorporated by reference the provisions of the Dock Department Tariff. The Tariff provides that:
No installations on, or changes or constructions in, the assigned area of a First Call on Berth Privilege shall be made without first submitting the plans and specifications therefor to, and securing the written approval in advance, of Board; provided, that at the termination of the First Call on Berth Privilege by expiration, cancellation, or in any other manner, such installations, structures, or materials so placed in or on the said assigned area shall be promptly removed by Grantee at its own cost, risk and expense.
In late 1975, after experiencing some vandalism and some equipment damage, A & G requested approval from the Board of plans for construction, on the wharf, of a fence to provide space for storage and maintenance of equipment and gear. The Board approved the plans and A & G constructed the fence. The gate which allegedly collapsed on plaintiff was part of this fence.
In his deposition, Mr. Spalluto stated that Dock Board inspectors periodically inspect *838 the wharf areas. Mr. Spalluto explained that the inspections focus upon property belonging to the Dock Board and that the inspectors are not concerned with the condition, maintenance or repair of property and equipment belonging to tenants. According to Mr. Spalluto, inspectors are concerned with damage to the wharf facility and not with any additional property brought onto the wharf by tenants. Fences installed by tenants are considered to be the tenant's responsibility and are not inspected by the Dock Board inspectors. If A & G had wanted to remove the fence, it could have done so at any time.
Mr. Hansen testified in his deposition that A & G had the fence constructed, owned it and maintained it. That on occasions when the gate was knocked down A & G would have it replaced. And further, that when A & G would leave that wharf area, i.e. no longer be assigned there, it would remove the gate and fence as its own property.
Mr. Hansen also indicated that the fenced enclosure on the Desire Street wharf was used for storing equipment used by A & G for operations being conducted on the Congress Street wharf. He stated that the gates were locked and that only A & G personnel had access to the area; Dock Board Personnel did not use or go into the area.
The fence established two sides of the enclosed area. The other two sides were the walls of the wharf warehouse. The fence posts were bolted to the cement warehouse floor. At the two locations where the fence contacted the warehouse walls, the fence was welded to the wall.
Sometime after plaintiff's accident and prior to the hearing on the motion for summary judgment, A & G stopped using the Desire Street wharf and the fence was removed.
Contrary to plaintiff's contention, we do not find any remaining issue as to material fact. The facts have been established. Whether the Dock Board was in a position of ownership, custody or control of the gate, so as to establish any Dock Board liability which might arise from the collapse of the gate, is a question of law. This question of law, nevertheless, must be answered before we can determine whether summary judgment was properly granted. That is, we must determine if the Dock Board is entitled to judgment as a matter of law.
Under the law applicable to this situation the Dock Board can be found to be liable for damage caused by the collapse of the gate (1) if the gate is considered a "building" and the Dock Board owned it at the time of its collapse (La.C.C. Art. 2322), (2) if the gate was in the Dock Board's "custody" at the time of its collapse (La.C.C. Art. 2317), or (3) if the damage caused can be found to have happened by the Dock Board's "fault" (La.C.C. Art. 2315) or to have been occasioned by the Dock Board's "negligence", "imprudence", or "want of skill" (La.C.C. Art. 2316).
Plaintiff correctly argues that structures not necessarily intended for habitation, as well as necessary appurtenances to structures and moveables made immovable by attachment, which have fallen into ruin or are defective, have been held by the courts to be within the scope of La.C.C. Art. 2322. Olsen v. Shell Oil Company, 365 So.2d 1285 (La.1978); Cothern v. Larocca, 255 La. 673, 232 So.2d 473 (La.1970); Boudoin v. Schwegmann Bros. Giant Supermarket, 371 So.2d 370 (La.App. 4th Cir.1979). Plaintiff fails, however, in at least two respects, concerning his argument that the Dock Board, as owner-lessor of the wharf, automatically became the owner of the gate when the gate was installed by the lessee, A & G.
Plaintiff argues that the fence and gate were permanently attached to the wharf and, therefore, were owned by the Dock Board. Whether the fence and gate were permanently attached can be decided by looking to La.C.C. Art. 466, which provides:
Art. 466. Component parts of buildings or other constructions.

*839 Things permanently attached to a building or other construction, such as plumbing, heating, cooling, electrical or other installations, are its component parts.
Things are considered permanently attached if they cannot be removed without substantial damage to themselves or to the immovable to which they are attached.
The evidence at the hearing established that the fence had been removed. The fence posts had been bolted to the floor of the warehouse and were apparently unbolted and removed. Where the fence contacted the warehouse walls, it had been welded in place. Photographs provided by plaintiff served to demonstrate that the fence had been removed without substantial damage. We find that the fence had not been permanently attached to the wharf and did not become a component part of the wharf.
The argument that the Dock Board owned the fence also falls when we consider La.C.C. Art. 495, which provides:
Art. 495. Things incorporated in, or attached to, an immovable with the consent of the owner of the immovable.
One who incorporates in, or attaches to, the immovable of another, with his Consent, things that become component parts of the immovable under Articles 465 and 466, may, in the absence of other provisions of law or juridical acts, remove them subject to his obligation of restoring the property to its former condition.
If he does not remove them after demand, the owner of the immovable may have them removed at the expense of the person who made them or elect to keep them and pay, at his option, the current value of the materials and of the workmanship or the enhanced value of the immovable.
This article, as well as the agreement between A & G and the Dock Board, refer to A & G's obligation to restore the wharf to its former condition upon termination of the Grant of First Call on Berth Privilege. Art. 495 indicates that, even if the fence were considered a component part of the wharf under Art. 466, A & G had the right to remove it. Approval of the Dock Board was required before A & G could install the fence. Approval was not required, however, to remove the fence; A & G could remove the fence at any time. A & G's exclusive authority over the fence indicates that the fence was owned by A & G and not by the Dock Board. See: La.C.C. Art. 477.
Because the Dock Board did not acquire ownership of the fence, it cannot be held liable under La.C.C. Art. 2322 for any damage caused by the collapse of the gate.
Plaintiff also argues that the Dock Board had custody of the fence and is liable under La.C.C. Art. 2317 for damages caused by the collapse of the gate. The Dock Board did not own the fence; it neither constructed, nor participated in the construction of the fence; it did not inspect the fence, nor repair, nor participate in repairs of the fence. All responsibilities for the care and maintenance of the fence rested with A & G. All privileges of use of the fence rested with A & G. The Dock Board demonstrated no custodial interest in the fence. We find that the Dock Board did not have custody of the gate so as to be subject to liability under La.C.C. Art. 2317.
Plaintiff's argument that the Dock Board's fault or negligence caused the gate to collapse is premised on the Dock Board being either the owner or custodian of the gate. Because we have found the Dock Board to be neither the owner nor the custodian of the gate, this segment of plaintiff's argument is not persuasive.
Having examined the possibilities for liability, we find no basis upon which the Dock Board could be held liable for any damages resulting from the collapse of the gate. The Dock Board, therefore, is entitled to judgment as a matter of law.
Because we have found no genuine issue as to material fact and have found the Dock Board entitled to judgment as a matter of law, we find that the trial court properly granted summary judgment. We, *840 therefore, will not discuss the issue of whether La.R.S. 9:3221 allows the Dock Board to contract out of any liability for injuries resulting from any defect in the wharf facilities.
Accordingly, the judgment of the trial court is affirmed. All costs are to be paid by plaintiff-appellant.
AFFIRMED.
