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

Could not copy "C:\Program Files\Inno Setup 6\SETUP.E32" #11

Open
armankarapetyandc opened this issue Dec 13, 2022 · 3 comments
Open

Could not copy "C:\Program Files\Inno Setup 6\SETUP.E32" #11

armankarapetyandc opened this issue Dec 13, 2022 · 3 comments

Comments

@armankarapetyandc
Copy link

The issue with running the docker image.
See below.

Status: Downloaded newer image for amake/innosetup:latest
Inno Setup 6 Command-Line Compiler
Copyright (C) 1997-2022 Jordan Russell. All rights reserved.
Portions Copyright (C) 2000-2022 Martijn Laan. All rights reserved.
Portions Copyright (C) 2001-2004 Alex Yackimoff. All rights reserved.
https://www.innosetup.com/

Compiler engine version: Inno Setup 6.2.1

Preprocessing
   Reading file: C:\Program Files\Inno Setup 6\ISPPBuiltins.iss
Parsing [Setup] section, line 16
Parsing [Setup] section, line 17
Parsing [Setup] section, line 18
Parsing [Setup] section, line 20
Parsing [Setup] section, line 21
Parsing [Setup] section, line 22
Parsing [Setup] section, line 23
Parsing [Setup] section, line 24
Parsing [Setup] section, line 26
Parsing [Setup] section, line 27
Parsing [Setup] section, line 30
Parsing [Setup] section, line 31
Parsing [Setup] section, line 32
Parsing [Setup] section, line 33
Parsing [Setup] section, line 34
Parsing [Setup] section, line 35
Reading file (WizardImageFile)
Reading file (WizardSmallImageFile)
Preparing Setup program executable
Error in Z:\work\wizard.iss: Could not copy "C:\Program Files\Inno Setup 6\SETUP.E32" to "Z:\work\Output\LauncherSetup.e32.tmp".

Error 5: Access denied.
Compile aborted.

This is my YAML file for GitHub Actions

name: Windows Install

on: 
  workflow_dispatch: {}

jobs:
    makeWindowsInstaller:
        name: "Make Install"
        runs-on: ubuntu-latest
        steps:
          - name: "Working"
            run: |
              mkdir working
              chmod 777 working
              cd working
              curl https://MYSERVER/files.zip -L -o files.zip
              curl https://MYSERVER/wizard.iss -L -o wizard.iss
              unzip files.zip
              mkdir Output
              docker run --rm -i -v "$PWD:/work" amake/innosetup wizard.iss  

Who can deal with this problem, and how can I solve it?

@amake amake changed the title Issue with running docker image - Could not copy "C:\Program Files\Inno Setup 6\SETUP.E32" Could not copy "C:\Program Files\Inno Setup 6\SETUP.E32" Dec 13, 2022
@miurahr
Copy link

miurahr commented Jun 8, 2023

There is a workaround #7 (comment)

@miurahr
Copy link

miurahr commented Jun 8, 2023

My workaround is "mkdir -p build && chmod -R a+w build" and "umask a+w " before the job.

@miurahr
Copy link

miurahr commented Feb 1, 2025

I find one of causes of the issue.
When I run the container as "rootless" mode, container users and host users are mapped using subuid.

username uid/gid in guest uid/gid on host
root 0.0 1000.1000
xclient 1001.1000 100999.100999

When you call the "Output" folder as ordinary permissions not to allow other users, it failed to write a file.
The workaround is "chmod 777 Output".
It will run successfully but the next time you want to clean the "Output" folder, you will got permission error, because the target file is owned by user who has 100999.100999 user.

@amake

Could you update the image to run the following script as the entry point ?

#!/bin/bash
set -e
TARGET=$(dirname -- "${!#}")
env HOME=/home/xclient WINEPREFIX=/home/xclient/.wine WINEARCH=win32 iscc $@
# Find and chmod files generated by iscc
find /work/${TARGET}/ -type f -user "$(whoami)" -exec chmod 777 {} \;

It assumes the last parameter is a relpath of the target ISS and a parent directory has a permission "0777".

miurahr added a commit to omegat-org/omegat that referenced this issue Feb 1, 2025
- Fix the permission error when running container as rootless mode on development environment.
- Generated Windows installer exe under build/innosetup/winNoJRE/ become owned by user with uid:gid = 100999.100999. It is a limitation of rootless mode container execution.
- The detailed discussion is at
amake/innosetup-docker#11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants