-
Notifications
You must be signed in to change notification settings - Fork 15
Fixing Broken Images in Docker
The following instructions are no longer applicable. If you are experiencing such issues you may want to try a newer version of Archetype.
If you are running DigiPal through Docker and your URL is not localhost:8080 but something like 192.168.90.100:8080, then you will probably also find that none of your manuscript images appear. This is because the version of Docker that you are using is based on VirtualBox and this does not use the normal localhost IP address. To fix this, the following steps are required. This only needs to be done once, and we will ensure that this step will not be necessary in future versions of the framework.
In summary, there is one line in a settings file which needs to be changed. Because of the way the setup works, you cannot easily use a conventional text editor to make the change. Instead you need to use a very old and not user-friendly (but very reliable) editor called vi.
-
Start the DigiPal server in Kitematic, if necesary.
-
Copy or make a note of the URL. Do not include the 'http://', and do not the colon or any numbers after it (e.g. ':8080'). The part that you copy should be an IP address, that is, it should consist of four numbers separated by '.' (e.g. '192.168.90.100')
-
Click on 'Exec' in Kitematic. This will open a new terminal window.
-
Type exactly the following into the window. Do not type any other key, even 'Return', unless specified. Be careful not to mis-type the commands, either: in some systems the backspace and delete keys do not work, and even small errors can have dramatic effects. However, the text in [square brackets and italics] are descriptions to help you so you should not type these.
cd digipal<Return>
vi local_settings.py<Return>
[This command should open the local_settings.py file in your window, so you should now see the contents of the file.]
/IMAGE_SERVER_HOST<Return>
[Your cursor should now be at the start of a line which reads IMAGE_SERVER_HOST = 'localhost:8081'. We will now change that line.]
wwwdwi
[Do NOT press at this point!][Each time you press 'w' you should see the cursor jump forward until it is at the start of the word 'localhost'. Pressing 'dw' should then delete the word 'localhost'. When you press 'i', nothing should appear to happen except that the word 'INSERT' will (probably) appear at the bottom of your window. This means that we are now in 'Insert' mode and you can type in new text.]
<Type or paste in the IP address from Step 2 above, then press ESC>
[You should now see a line of text something like
IMAGE_SERVER_HOST = '192.168.90.100:8081'
, where the number before the colon is your address from Step 2 above. After you press , the word 'INSERT' should no longer be visible.]:wq<Return>
[This should now save your changes and bring you back to the command line]
<Ctrl-D>
[This should now exit the terminal (your window will probably still be visible but you will probably see a different cursor, or perhaps cannot type anything at all).]
-
Now Quit the Terminal application
-
In Kitematic, restart the container
You should now be able to see the images in your DigiPal instance.
Archetype is maintained by the King's Digital Lab at King's College London. It has received funding from the European Union Seventh Framework Programme (FP7) under Grant Agreement no. 263751 (DigiPal), the Arts and Humanities Research Council (AHRC) under Grant Reference n° AH/L008041/1 (Models of Authority) and AH/L013975/1 (Exon Domesday), and the Faculty of Arts and Humanities at King's College London.
Credits
Getting Started
Using Archetype
The Data Model
Editorial interface
- The Admin Interface
- Adding Items (Manuscripts)
- Adding Images
- Adding Hands and Scribes
- Adding Symbols (Letters)
- Content Permissions
- The Annotation Process
- Linking image regions with text regions
- Rebuilding the Indices
Customising the framework
Archetype for developers
- Installing Archetype on a Web Server
- Bulk Image Upload
- The Javascript API Library
- The Web API Syntax
- Upgrading Archetype
- Contributing to the code (third party development)
- Restoring an Archetype backup
Troubleshooting