If you want to make sure that the server isn't able to decrypt the file, you must not reveal the password to the server. Therefore
- the encryption password must not be used for server-side authentication;
- the data must be encrypted on the client side.
You can build complex architectures, but fundamentally, if you don't trust the server, don't give it your password.
Alternatively, if you want to perform the encryption server-side, you need to assure yourself that the server is secure enough for your needs. That means you need to trust (or have some third party (that you trust) verify through an audit) that:
- The server does not store or leak passwords.
- The server code behaves as advertised; in particular, it only stores encrypted data and promptly erases any temporary copies of plaintext.
- The data in transit is properly protected.
- The server is physically secure, so that no intruder can access your data or your password while it is in use.
- People with legitimate access to the server (e.g. system administrators) are trustworthy.
- This state of things will remain true as long as you use the service.