Skip to content

Need to change the root of src in index.html #3220

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

Closed
GRRedWings opened this issue Nov 21, 2016 · 3 comments
Closed

Need to change the root of src in index.html #3220

GRRedWings opened this issue Nov 21, 2016 · 3 comments

Comments

@GRRedWings
Copy link

GRRedWings commented Nov 21, 2016

I don't know where else to create this, I didn't see a message board.

I'm trying to deploy my application, but in order to run in my container I need to change all the src tags in the script node of index.html to have a prefix my/path/root/

In looking at the documentation I have tried to specify the base href and that didn't work, and I have not found any information about environments that might be able to effect index.html.

Thanks for any input.

OS?

Windows 7, 8 or 10. Linux (which distribution). Mac OSX (Yosemite? El Capitan?)
Windows 10

Versions.

Please run ng --version. If there's nothing outputted, please run in a Terminal: node --version and paste the result here:
angular-cli: 1.0.0-beta.19-3
node: 4.6.1
os: win32 x64

Repro steps.

Was this an app that wasn't created using the CLI? What change did you do on your code? etc.

The log given by the failure.

Normally this include a stack trace and some more information.

Mention any other details that might be useful.


Thanks! We'll be in touch soon.

@rolyatsats
Copy link
Contributor

rolyatsats commented Dec 3, 2016

By deploy do you mean ng github-pages:deploy or are you running ng build -prod and then uploading everything in /dist to a server?

If github-pages, try ng github-pages:deploy -bh /your/custom/path/

Else if you're uploading custom, edit index.html base href:

<base href="/your/custom/path/">

Or generate it via ng build -prod -bh /your/custom/path/

@filipesilva
Copy link
Contributor

Dupe of #2276. Work ongoing in #3285

@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Sep 6, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants