Skip to content

Instantly share code, notes, and snippets.

@plmi
Last active October 2, 2025 17:58
Show Gist options
  • Select an option

  • Save plmi/40818dad6580d23a93c813b5c0e1acc7 to your computer and use it in GitHub Desktop.

Select an option

Save plmi/40818dad6580d23a93c813b5c0e1acc7 to your computer and use it in GitHub Desktop.
A Dockerfile to run ikeforce in a working python2 environment.

Uses alpine image because old Debian Buster repositories have been moved to the archive.

Checkout ikeforce

git clone https://github.com/SpiderLabs/ikeforce.git

Make sure the directory structure looks like this

.
├── Dockerfile
└── ikeforce/

Build:

docker build -t ikeforce-py2 .

Run:

docker run --rm -it ikeforce-py2

docker run --rm -it ikeforce-py2 python2 /ikeforce/ikeforce.py --help
FROM python:2.7-alpine
# Install build tools and dependencies
RUN apk add --no-cache \
build-base \
libffi-dev \
openssl-dev \
python2-dev \
vim
# Install required Python packages
RUN pip install --no-cache-dir pyip pycrypto 'pyopenssl==17.2.0'
# Copy ikeforce into the container
COPY ikeforce /ikeforce
WORKDIR /ikeforce
CMD ["/bin/sh"]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment