Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dockerize FBX2glTF #184

Merged
merged 7 commits into from
May 8, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
.dockerignore
Dockerfile

28 changes: 28 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
FROM ubuntu:16.04

RUN apt-get update && \
apt-get install -y software-properties-common && \
add-apt-repository ppa:jonathonf/python-3.6 && \
add-apt-repository ppa:git-core/ppa && \
apt-get update && \
apt-get install -y python3.6 curl build-essential cmake libxml2-dev zlib1g-dev git && \
curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py && python3 get-pip.py && \
pip install conan && \
conan remote add bincrafters https://api.bintray.com/conan/bincrafters/public-conan

COPY . /fbx2gltf
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could this COPY be easily made to skip "./sdk/" by any chance? That's a lot of pointless data, if you're sure GIT LFS is not reliable everywhere.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I should be able to add that to .dockerignore. The large copy wouldn't be an issue for docker hub builds because git lfs files haven't been pulled, but I can see this as useful for local builds.


WORKDIR /fbx2gltf

# Install FBX SDK
RUN curl -L https://www.autodesk.com/content/dam/autodesk/www/adn/fbx/20192/fbx20192_fbxsdk_linux.tar.gz -o fbx20192_fbxsdk_linux.tar.gz && \
tar -xvf fbx20192_fbxsdk_linux.tar.gz && \
echo "yes\nn" | ./fbx20192_fbxsdk_linux /fbx2gltf/sdk/Linux/2019.2 && \
rm -rf /fbxsdktemp

# Build and install
RUN conan install . -i docker-build -s build_type=Release -s compiler=gcc -s compiler.version=5 -s compiler.libcxx=libstdc++11 && \
conan build -bf docker-build . && \
cp docker-build/FBX2glTF /usr/bin && \
cd / && \
rm -rf /fbx2gltf /root/.conan
5 changes: 5 additions & 0 deletions docker-compose.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
version: '3.7'
services:
fbx2gltf:
build:
context: .