Dockerfile and docker-compose.yml are broken: copies a missing config.toml, wrong binary/subcommand, stale OpenSSL dep, wrong source path and port #40
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
Neither the
Dockerfilenordocker-compose.ymlworks against the current workspace.docker compose buildfails at the firstCOPYand, even if it didn't, the resulting image would crash on start.Problems
Dockerfile:Specifically:
COPY myfs /src— the repo is a workspace (myfs-core,myfs-lib,myfs-hub,myfs-tool,myfs-test-utils); there is nomyfs/directory, so the build aborts here.COPY config.toml .—config.tomlis listed in.gitignoreand is not committed, so thisCOPYfails even after fixing (1).apt-get install ... libssl-dev ...—docs/adr/008-remove-openssl-dependency.mdsays OpenSSL was intentionally removed (rustls everywhere). The Dockerfile drags it back in.ENTRYPOINT ["./myfs", "server", ...]— the server lives in themyfs-hubbinary and the subcommand isserve(myfs-hub serve --config-path ...). Themyfsbinary only hasmount/pack/unpack/upload/download/..., so the container would exit immediately with a clap error.docker-compose.yml:3000doesn't match anything documented;README.mduses8080(store_url/host/portcome from the TOML config, default 8080). The port mapping should match whatever the committed example config uses.Suggested fix
COPY . .from repo root, or copy the crate dirs explicitly) andcargo build --release --workspace(or-p myfs-hub).config.toml(e.g.config.example.toml, un-gitignored) andCOPYthat, or generate it at runtime.libssl-devfrom the apt install line (rustls only).myfs-hub serve --config-path /app/config.tomlandCOPYthemyfs-hubbinary, notmyfs.host/port.If containerization isn't a supported deployment path right now, consider just deleting
Dockerfile+docker-compose.ymluntil it is.