Skip to content

Commit e389707

Browse files
Refine some files.
1 parent 5e46915 commit e389707

File tree

2 files changed

+15
-17
lines changed

2 files changed

+15
-17
lines changed

README.md

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,15 @@ Make sure you have Docker installed on your system.
3737
docker build -t arch-iso-builder .
3838
```
3939

40-
3. **Retrieve the ISO**:
40+
3. **Build the ISO in the container**
41+
42+
Build the ISO with this command:
43+
44+
'''bash
45+
docker run --rm --privileged -v $(pwd):/workdir arch-iso-builder bash -c "mkarchiso -v -w workdir/ -o out/ ."
46+
'''
47+
48+
4. **Retrieve the ISO**:
4149

4250
Once the process completes, the ISO will be available in the `out/` directory within your local folder as `Arch.iso`.
4351

dockerfile

Lines changed: 6 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,15 @@
1-
# Use the official Arch Linux image as the base
21
FROM archlinux:latest
32

4-
# Update system and install necessary packages
3+
# Install necessary packages
54
RUN pacman -Syu --noconfirm && \
65
pacman -S --noconfirm git archiso grub
76

8-
# Create a directory for the workspace
7+
# Set the working directory
98
WORKDIR /workdir
109

11-
# Copy the entire repository into the container
10+
# Copy files into the container
1211
COPY . .
1312

14-
# Build the Arch ISO
15-
RUN mkarchiso -v -w workdir/ -o out/ .
16-
17-
# Rename the generated ISO to Arch.iso (if only one ISO is generated)
18-
RUN iso_file=$(ls out/*.iso | head -n 1) && \
19-
mv $iso_file out/Arch.iso
20-
21-
# Set the output directory as a volume so you can retrieve the ISO later
22-
VOLUME /workdir/out
23-
24-
# The default command just keeps the container running
25-
CMD [ "sleep", "infinity" ]
13+
# Instead of running mkarchiso here, we leave it for later execution
14+
# Create an entrypoint or leave it to manual execution
15+
CMD ["/bin/bash"]

0 commit comments

Comments
 (0)